News for hackers. Stuff that matters.
Re:Pascal at Apple by WalterBright on Sunday July 23, 2017 @12:58AM (#14830974)
Yes, you can do it that way. But then you'll need a "context pointer" to pass references to the locals it'll need, and the function will need to be located "someplace else", meaning it is not encapsulated.

I've done that for years with C and C++. Nested functions are so much nicer and clearer.

Re:Pascal at Apple by vram22 on Sunday July 23, 2017 @07:59AM (#14831854)
Got it now, thanks. I've used nested functions in Python and they have some good uses. Will check them out in D.