You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Justin Erenkrantz <je...@apache.org> on 2002/11/06 06:24:38 UTC

Re: svn commit: rev 3665 - trunk trunk/ac-helpers

--On Tuesday, November 5, 2002 11:58 PM -0600 sussman@tigris.org 
wrote:

> Modified: trunk/ac-helpers/svn-apache.m4
> ===================================================================
> =========== --- trunk/ac-helpers/svn-apache.m4	(original)
> +++ trunk/ac-helpers/svn-apache.m4	Tue Nov  5 23:58:27 2002
> @@ -10,6 +10,8 @@
>
>  AC_DEFUN(SVN_FIND_APACHE,[
>
> +HTTPD_WANTED_MMN="$1"
> +

I *think* this should be

HTTPD_WANTED_MMN=$1

because we don't want to place any quotes around this value.  It's a 
numeric, not a string.

If it works right now, well, we might not want to change.  -- justin

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn commit: rev 3665 - trunk trunk/ac-helpers

Posted by Blair Zajac <bl...@orcaware.com>.
Ben Collins-Sussman wrote:
> 
> Justin Erenkrantz <je...@apache.org> writes:
> 
> > --On Tuesday, November 5, 2002 11:58 PM -0600 sussman@tigris.org wrote:
> >
> > > Modified: trunk/ac-helpers/svn-apache.m4
> > > ===================================================================
> > > =========== --- trunk/ac-helpers/svn-apache.m4      (original)
> > > +++ trunk/ac-helpers/svn-apache.m4  Tue Nov  5 23:58:27 2002
> > > @@ -10,6 +10,8 @@
> > >
> > >  AC_DEFUN(SVN_FIND_APACHE,[
> > >
> > > +HTTPD_WANTED_MMN="$1"
> > > +
> >
> > I *think* this should be
> >
> > HTTPD_WANTED_MMN=$1
> >
> > because we don't want to place any quotes around this value.  It's a
> > numeric, not a string.
> >
> > If it works right now, well, we might not want to change.  -- justin
> 
> It works for me right now.  So do the "$1"'s I committed in r3663.
> 
> Can someone more knowledgable comment?

It doesn't hurt here because it's in the shell portion of the script and
isn't modified by m4.

The times we don't want ""'s are when you pass them to a m4 macro and
you want the $1 to white space separate the value, say with a

AC_DEFUN(AAA,[
for f in $1; do
  echo $f
done
])

Here calling AAA("a b") set f to "a b" and not to "a" and then "b".

Best,
Blair

-- 
Blair Zajac <bl...@orcaware.com>
Web and OS performance plots - http://www.orcaware.com/orca/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn commit: rev 3665 - trunk trunk/ac-helpers

Posted by Scott Lamb <sl...@slamb.org>.
Ben Collins-Sussman wrote:
> Justin Erenkrantz <je...@apache.org> writes:
>>--On Tuesday, November 5, 2002 11:58 PM -0600 sussman@tigris.org wrote:
>>>Modified: trunk/ac-helpers/svn-apache.m4
>>>===================================================================
>>>=========== --- trunk/ac-helpers/svn-apache.m4	(original)
>>>+++ trunk/ac-helpers/svn-apache.m4	Tue Nov  5 23:58:27 2002
>>>@@ -10,6 +10,8 @@
>>>
>>> AC_DEFUN(SVN_FIND_APACHE,[
>>>
>>>+HTTPD_WANTED_MMN="$1"
>>>+
>>
>>I *think* this should be
>>
>>HTTPD_WANTED_MMN=$1
>>
>>because we don't want to place any quotes around this value.  It's a
>>numeric, not a string.
>>
>>If it works right now, well, we might not want to change.  -- justin
> 
> It works for me right now.  So do the "$1"'s I committed in r3663.
> 
> Can someone more knowledgable comment?

Short version: it doesn't matter.

Long version: this line should be passed through M4 unchanged and 
interpreted by the shell. With the quotes, it says "set HTTPD_WANTED_MMN 
to the contents of $1, without expansion". Without the quotes, it does 
expand (file globs, spaces, I think). The quotes definitely aren't 
actually included in $HTTPD_WANTED_MMN. For a value that is numeric, the 
results will be the same either way.

I prefer programming languages that do things the other way: not trying 
to expand anything unless you explicitly ask for it. This is why there 
are lots of bugs in shell scripts relating to filenames that contain 
'*', '?', or whitespace. The original iTunes eating hard disks with 
spaces in the volume names, for example.

Scott


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn commit: rev 3665 - trunk trunk/ac-helpers

Posted by Ben Collins-Sussman <su...@collab.net>.
Justin Erenkrantz <je...@apache.org> writes:

> --On Tuesday, November 5, 2002 11:58 PM -0600 sussman@tigris.org wrote:
> 
> > Modified: trunk/ac-helpers/svn-apache.m4
> > ===================================================================
> > =========== --- trunk/ac-helpers/svn-apache.m4	(original)
> > +++ trunk/ac-helpers/svn-apache.m4	Tue Nov  5 23:58:27 2002
> > @@ -10,6 +10,8 @@
> >
> >  AC_DEFUN(SVN_FIND_APACHE,[
> >
> > +HTTPD_WANTED_MMN="$1"
> > +
> 
> I *think* this should be
> 
> HTTPD_WANTED_MMN=$1
> 
> because we don't want to place any quotes around this value.  It's a
> numeric, not a string.
> 
> If it works right now, well, we might not want to change.  -- justin

It works for me right now.  So do the "$1"'s I committed in r3663.

Can someone more knowledgable comment?

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org