http://d.puremagic.com/issues/show_bug.cgi?id=8185



--- Comment #52 from Steven Schveighoffer <schvei...@yahoo.com> 2012-06-04 
11:51:14 PDT ---
(In reply to comment #49)
> It seems that the compiler will only optimize based on "pureness" if a 
> function
> takes an 'immutable T*' argument, even 'immutable(T)*' is enough to turn the
> optimization off.

This is a bug, both should be optimized equally:

void foo(immutable int * _param) pure
{
   immutable(int)* param = _param; // legal
   ... // same code as if you had written void foo(immutable(int)* param)
}

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to