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

"(anon)" is not a useful pointer



Another minor issue.

Consider:

[[[
% cat > foo
f() { 
  () {    
     : *(syntaxerror)
  }
}
% source foo
% f
(anon):1: unknown file attribute: y
zsh: exit 1
]]]

To a user, that "(anon)" isn't terribly helpful; it gives no clue as to
the location of the error.  Perhaps the name of the containing named
function could be prefixed to the error message, e.g.,

f: (anon):1: unknown file attribute: y

?

Cheers,

Daniel

P.S. "(anon):1" isn't helpful to the developer of f if f contains more
than one anonymous function (either nested, f() { () { () { : } } }, or
siblings, f() { () {:}; () {:}; }).  Ideas about that welcome. :)



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