[Issue 6235] Regression(DMD 2.053) ICE on typeof(Range.init[0..$]) inside a templated struct/class

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Jul 3 13:46:51 PDT 2011


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



--- Comment #3 from Don <clugdbug at yahoo.com.au> 2011-07-03 13:41:49 PDT ---
(In reply to comment #2)
> Using $ seems to be adding the declaration to the struct as a field.
> Is there any reason $ is always a variable, not just re-written as
> exp[... $ ... ] => exp[... exp.length ...] ?

I think it's because exp may have side effects, so it should only be evaluated
once.

-- 
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