Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

WARN_CREATE_GLOBAL and parameters used by the shell



I think that when WARN_CREATE_GLOBAL is set, one should get no warnings
for parameters used by the shell, as their intent is to be global.

For instance:

cventin% setopt WARN_CREATE_GLOBAL
cventin% foo() { RPS1="<" }
cventin% foo
foo: scalar parameter RPS1 created globally in function

There is no such problem with PS1, PS2, PS3 and PS4, probably because
they are already set by zsh.

-- 
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)



Messages sorted by: Reverse Date, Date, Thread, Author