>     One for example (I think it is a bug, but maybe in the semantics
> you've described it's not):
>     * again if we're using `-e`, and inside a function we write `fn
> dosomething { echo 1 ; false ; echo 2 ; return 0 ; }`
>     * if we run `dosomething` it shall output only `1`, as the false
> breaks the execution;
>     * but if we run `dosomething || echo 3`, we see `1 2` outputed,
> because the false is not exiting the shell as the invocation of the
> function is part of a `||` statement;

not a bug.  x || y is "line" in the rc grammar.  "x;" is als o a line.
-e is only evaluated at the end of lines.

>     But undoubtedly, the following is a bug (I have an array and want
> to display all the elements on a single line, wrapped inside quotes,
> and everything with a prefix and a suffix):
[...]

> ifs='\n' echo '  erl files = ('^`{ echo -n
> '`'^$application__erl_files__short^'`' }^')'
> ifs='\n' echo '  erl files = ('^`{ echo -n
> '`'^$application__erl_files__long^'`' }^')'
> ~~~~
>     it displays:
> ~~~~
>   erl files = (`a.erl` `b.erl` `c.erl`)
>   erl files = (`/home/cipria)   erl files = (/workbe)   erl files =
> (ch/vel/a.erl` `/home/cipria)   erl files = (/workbe)   erl files =
> (ch/vel/b.erl` `/home/cipria)   erl files = (/workbe)   erl files =
> (ch/vel/c.erl`)
> ~~~~

not a bug.  you set the ifs to '\' and 'n'.  since the first
list doesn't have any ns in it, it doesn't get split.
to get a newline in rc you need
ifs='
' cmd

- erik

Reply via email to