Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
RE: strange alias effects
- X-seq: zsh-users 3098
- From: "Andrej Borsenkow" <Andrej.Borsenkow@xxxxxxxxxxxxxx>
- To: "Andy Spiegl" <zsh.Andy@xxxxxxxxx>, "ZSH User List" <zsh-users@xxxxxxxxxxxxxx>
- Subject: RE: strange alias effects
- Date: Mon, 29 May 2000 16:06:57 +0400
- Importance: Normal
- In-reply-to: <000301bfc963$3615d910$21c9ca95@xxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxxxxxx; run by ezmlm
>
> Well, aliases are not expanded in direct function defiition
> (correct me,
> Bart). Weirdly enough, they are expanded (by default) in autoloaded
> functions.
>
Sorry, this is of course wrong. You just seem to have alias definition
*after* function definition. Because aliases are expanded when function
is *defined*, they are not seen when functnio is executed.
Autoloading provides neat workaround - function body is first read in
after everything else (including aliases) was already defined. For the
same reason, second function definition in your example (on command
line) works as expected - aliases are already known.
-andrej
Messages sorted by:
Reverse Date,
Date,
Thread,
Author