Weak Purity Blog Post

sarn via Digitalmars-d-announce digitalmars-d-announce at puremagic.com
Tue Mar 29 23:28:00 PDT 2016


On Monday, 28 March 2016 at 09:59:12 UTC, ag0aep6g wrote:
> On 28.03.2016 03:44, sarn wrote:
>> https://theartofmachinery.com/2016/03/28/dirtying_pure_functions_can_be_useful.html
>
> From there:
>
>> Well, you can get the usual (“strong”) purity guarantee just 
>> by making all pointer or reference type arguments const.
>
> Indirections in the return type also play into this. David 
> Nadlinger explains this in his article on the matter:
>
> http://klickverbot.at/blog/2012/05/purity-in-d/#indirections-in-the-return-type

Thanks.  I updated the post.


More information about the Digitalmars-d-announce mailing list