Artifacts Associated With Ticket fd2d126f23
Ticket change [271a7aaeaf] (rid 141789) by anonymous on 2015-05-16 00:53:50:
- assignee initialized to: "nobody"
- closer initialized to: "nobody"
- cmimetype initialized to: "text/plain"
- comment initialized to:
This proc proc oneFunction {a {b 1} c} {puts "$a $b $c"} doesn't guive an error. It's accepted by the interpreter. I think all the optional arguments should be at the end. - is_private initialized to: "0"
- login: "anonymous"
- priority initialized to: "5 Medium"
- private_contact initialized to: "1c4b6cdb98c9dfc4d1e74018f3f4efa00ad217e2"
- resolution initialized to: "None"
- severity initialized to: "Minor"
- status initialized to: "Open"
- submitter initialized to: "anonymous"
- subsystem initialized to: "18. Commands M-Z"
- title initialized to: "Wrong proc doesn't guives an error"
- type initialized to: "Bug"
Ticket change [408fa42a3c] (rid 141791) by dkf on 2015-05-16 05:52:37:
- assignee changed to: "msofer"
- login: "dkf"
- mimetype: "text/plain"
- subsystem changed to: "22. [proc] and [uplevel]"
Ticket change [aee10e2ae8] (rid 141806) by ferrieux on 2015-05-16 11:41:33:
- icomment:
The reason it is accepted, is that {b 1} is a valid arg name. I admit it would make sense to forbid whitespace in arg names except for default ones (end of list), but after decades without the rule there's a (small) risk of compat breakage. Maybe for 9.0 ? - login: "ferrieux"
- mimetype: "text/plain"
- icomment:
Ticket change [3ce20b9761] (rid 141811) by dkf on 2015-05-17 11:06:38:
- icomment:
No, each formal argument has always been a list. It's just that <tt>proc</tt> has simply never checked for this failure mode. At some point we might get around to making optionals-in-the-middle work. But for now, it's a (really) low priority, especially as it is a performance-sensitive area.<p>Making this be a declaration-time error would be reasonable. The only concern would be how much of an impact on existing (non-working) scripts this would have.
- login: "dkf"
- mimetype: "text/html"
- username: "dkf"
- icomment: