Stephane Chazelas <stephane.chaze...@gmail.com> wrote:

> alias for=pour
> alias do=faire
> alias to_french='echo '
>
> for word in for do; do
>   eval "to_french $word"
> done
>
> (which already doesn't work in bash except in posix mode nor in
> zsh in posix mode or not).

>From looking at the error message from bash. it seems that the reason why bash 
fails here is that it parses scripts as a whole and thus does not expand 
aliases inside scripts at all.

If you check the same in an interactive bash 5, you even get error messages 
that lead to an implementation bug.

Jörg

-- 
 EMail:jo...@schily.net                    (home) Jörg Schilling D-13353 Berlin
    joerg.schill...@fokus.fraunhofer.de (work) Blog: http://schily.blogspot.com/
 URL: http://cdrecord.org/private/ http://sf.net/projects/schilytools/files/'

Reply via email to