autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Success (mostly) with the testsuite


From: Akim Demaille
Subject: Re: Success (mostly) with the testsuite
Date: 27 Oct 2000 10:54:49 +0200
User-agent: Gnus/5.0807 (Gnus v5.8.7) XEmacs/21.1 (Channel Islands)

Great!  Thanks Alexandre!

| Direct use
| {One}
| {line}
| {Two
| lines}

OK.

| Indirect Use with Quotes
| {One line}
| {Two
| lines}

Not OK.

| Indirect Use without Quotes
| {One}
| {line}
| {Two
| lines}

OK.

This is the big problem I probably misunderstood (and diagnosed as
`quotes are included in the value').

The two tests right above are:

foo="One line"
bar="Two
lines"

: ${foo1="$foo"}
: ${bar1="$bar"}

and then a `for word in $foo1 echo "{$word}"'

: ${foo2=$foo}
: ${bar2=$bar}

likewise.

So what I don't understand is that there is no longer IFS splitting
after you did a

        : ${list="$default"}

but there is if you

        : ${list=$default}

This is why I removed the quotes months ago.

So I guess the problem is related to the 8th bit, just like in the
case of config.cache.  I guess it means that

----------------------------------------
default="a b c"
: ${list1=$default}
: ${list2="$default"}

echo "$list1" | cat -v
echo "$list2" | cat -v
----------------------------------------

gives two different results?


The solution you propose is definitely the right one.

How do these guy behave?  The present case is somewhat different from
that of config.cache where the rhs is a literal, not another variable.

----------------------------------------
default="a b c"
: list1=${list1-$default}
: list2=${list2-"$default"}

echo "$list1" | cat -v
echo "$list2" | cat -v
----------------------------------------

or do you mean

----------------------------------------
default="a b c"
: list1=${list1=$default}
: list2=${list2="$default"}

echo "$list1" | cat -v
echo "$list2" | cat -v
----------------------------------------

What is the conclusion to draw in fact.  : ${foo=BAR} is used in a lot
of places in Autoconf, but without any damaged but here and in
config.cache.  What's the problem?  Is it that none of the other
variable is ever IFS split?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]