On Sunday, 12 April 2015 at 07:12:47 UTC, Walter Bright wrote:
Attribute inference works when the source to a function must exist (i.e. be available to the compiler). Currently, it is done for template functions and function literals.

At one point, I had implemented it for auto return functions, because the source must exist for them, too, but it got a lot of resistance and was dropped.

Is this really an issue that comes up? How often do people in D not have access to the source of the libraries they're working with?

Martin seemed to be advocating heavily for not inferring between packages, and using it to clean up internal functions.

Is there a reason functions marked private and package couldn't infer? Is the main issue with this the extra compilation time it would take?

Reply via email to