[Issue 2008] Poor optimization of functions with ref parameters

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Jan 24 16:06:03 PST 2010


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



--- Comment #5 from Eldar Insafutdinov <e.insafutdinov at gmail.com> 2010-01-24 16:06:02 PST ---
(In reply to comment #4)
> (In reply to comment #3)
> > Recent change to dmd forced everybody to use opEquals with ref arguments. That
> > leaves no other option than the poorly optimised one. Isn't it time to fix this
> > bug?
> 
> I think the more important fix is to start allowing opEquals with non-ref
> arguments again.  Only allowing ref arguments is ridiculous because it forces
> the argument to be an lvalue, thus creating a horribly ugly inconsistency with
> builtin types.

That's true. Perhaps functions with signature (const ref T) could accept
rvalues as well, as the semantics is equivalent to (T)?

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


More information about the Digitalmars-d-bugs mailing list