Skip to content

Conversation

jmdavis
Copy link
Member

@jmdavis jmdavis commented Jun 4, 2012

This clarifies the definition of pure, since so many people seem to have
a hard time understanding that all that pure means is that the
function cannot access global or static, mutable state or call impure
functions. Everything else with regards to pure is a matter of
implementation-specific optimizations - which does in some cases relate
to full, functional purity, but pure itself does not indicate anything
of the sort.

This clarifies the definition of pure, since so many people seem to have
a hard time understanding that _all_ that pure means is that the
function cannot access global or static, mutable state or call impure
functions. Everything else with regards to pure is a matter of
implementation-specific optimizations - which does in some cases relate
to full, functional purity, but pure itself does not indicate anything
of the sort.
@denis-sh
Copy link
Contributor

denis-sh commented Jun 4, 2012

Thanks!

@alexrp
Copy link
Contributor

alexrp commented Jun 10, 2012

Looks good.

WalterBright added a commit that referenced this pull request Jul 2, 2012
@WalterBright WalterBright merged commit 8cc3ba6 into dlang:master Jul 2, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants