On 3/21/12, Walter Bright <newshou...@digitalmars.com> wrote: > Andrei discovered an amazing use of auto.
It's funny how the book explicitly stated that this doesn't work (page 263): "Nested struct objects cannot be returned from functions because the caller doesn't have access to their type". I posted about this back in 2011: http://www.digitalmars.com/d/archives/digitalmars/D/Has_the_ban_on_returning_function_nested_structs_been_lifted_132233.html It might have been a relic from earlier TDPL writing when this feature didn't exist. :)