digitalmars.D.bugs - [Issue 7798] New: Improve nested functions
- d-bugmail puremagic.com (36/36) Mar 29 2012 http://d.puremagic.com/issues/show_bug.cgi?id=7798
- d-bugmail puremagic.com (14/14) Jul 17 2012 http://d.puremagic.com/issues/show_bug.cgi?id=7798
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 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: -------
Mar 29 2012
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 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: -------
Jul 17 2012