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

typeset -U and "special-ness"



I love 'typeset -U' for paramaters like PATH, MAILPATH, and
MANPATH. However, I was disappointed to learn that 'typeset -U
LD_LIBRARY_PATH' has no effect.

I understand that 'typeset -U' only works for "special" paramaters,
but why? How did MANPATH get elevated to the status of a "special"
paramater when it isn't used by the shell at all?

Also, 'typeset -U' doesn't remove duplicates from current values of
the paramaters. Any good reason for this?
For example:
	% unset MANPATH
	% typeset +U MANPATH
	% echo $MANPATH

	% MANPATH=foo:foo
	% echo $MANPATH
	foo:foo
	% typeset -U MANPATH		<- Why not effect the value?
	% echo $MANPATH
	foo:foo
	% MANPATH=$MANPATH
	% echo $MANPATH
	foo

What do you think?
-- 
Scott RoLanD
http://www.chat.net/~shr/



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