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

emulate with options other than -c is broken



Regardless of the autoload thing,

  emulate zsh -o extendedglob -c '[[ -o extendedglob ]] ||
  print "extendedglob is NOT set"'

prints

  extendedglob is NOT set

(though zsh emulation did take effect) while

  setopt ignorebraces          
  emulate zsh -o extendedglob
  [[ -o ignorebraces ]] && print "ignorebraces IS still set"

prints

  ignorebraces IS still set

(though extendedglob did get set).

This is because of the position where the emulation takes effect within
the emulate builtin.  Also, I'm not happy that parse errors in the
option parsing are handled properly.

Work for tomorrow.

-- 
Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
Web page now at http://homepage.ntlworld.com/p.w.stephenson/



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