On Thursday, 19 May 2016 at 22:17:37 UTC, Walter Bright wrote:

Consider using a 'static struct'. A non-static struct will include a hidden member that points to the stack frame of foo(), i.e. "produces smaller code".

Queue me going to the language reference to look up static structs and reading

"A struct can be prevented from being nested by using the static attribute, but then of course it will not be able to access variables from its enclosing scope."

Not a fan of that description...

Reply via email to