March 29, 2012 [Issue 7798] New: Improve nested functions | ||||
---|---|---|---|---|
| ||||
http://d.puremagic.com/issues/show_bug.cgi?id=7798 Summary: Improve nested functions Product: D Version: D1 & D2 Platform: All OS/Version: All Status: NEW Keywords: spec Severity: enhancement Priority: P2 Component: DMD AssignedTo: nobody@puremagic.com ReportedBy: siegelords_abode@yahoo.com --- Comment #0 from siegelords_abode@yahoo.com 2012-03-29 14:16:04 PDT --- I've run into two issues with nested functions that I think should be fixed. As is, it seems that the nested functions are scarcely more than syntax sugar for delegates. 1. Overloading: void main() { void test() {} void test(int a) {} } No good reason why that shouldn't work. This is described in the spec, but no good reason is given. 2. Reusing same function name in different scopes: void main() { { void test() {} } { void test() {} } } This won't compile either. This limitation isn't even described in the spec as far as I can tell. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
July 17, 2012 [Issue 7798] Improve nested functions | ||||
---|---|---|---|---|
| ||||
Posted in reply to siegelords_abode@yahoo.com | http://d.puremagic.com/issues/show_bug.cgi?id=7798 yebblies <yebblies@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC| |yebblies@gmail.com Resolution| |DUPLICATE --- Comment #1 from yebblies <yebblies@gmail.com> 2012-07-18 03:56:54 EST --- 1. Is issue 3492 2. Is issue 5655 *** This issue has been marked as a duplicate of issue 5655 *** -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
Copyright © 1999-2021 by the D Language Foundation