To help LDC/GDC

Iain Buclaw ibuclaw at ubuntu.com
Thu Apr 11 06:53:28 PDT 2013


On 11 April 2013 14:38, Joseph Rushton Wakeling <
joseph.wakeling at webdrake.net> wrote:

> On 04/11/2013 03:29 PM, Jacob Carlborg wrote:
> > What's the point of that. Just have "strong" mean const/immutable
> parameters.
>
> The point is to have a way for me, the programmer, to say to the compiler:
> "I
> mean for this function to be strongly pure, can you confirm whether my
> choice of
> function inputs supports this please?"
>

I think that giving the user choice of purity is about as useful as given
user choice over what functions should be inlined, or what vars should go
in registers.

Such decisions are best left to the compiler devs judgement on doing the
right thing for you.  Even if they sometimes get it wrong. :o)

-- 
Iain Buclaw

*(p < e ? p++ : p) = (c & 0x0f) + '0';
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20130411/19d72c9f/attachment.html>


More information about the Digitalmars-d mailing list