[Issue 5604] Clarify whether this is a bug or a feature

2011-02-17 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=5604


Steven Schveighoffer  changed:

   What|Removed |Added

 CC||schvei...@yahoo.com


--- Comment #2 from Steven Schveighoffer  2011-02-17 
11:28:01 PST ---
I really expected this to be a bug.  Because I would expect this to fail:

struct S
{
   int opApply(int delegate(ref size_t idx, ref int val) dg)
   {
 return 0;
   }
}

void main()
{
   S s;
   foreach(uint idx, int val; s) {}
}

i.e. you cannot possibly duplicate this 'feature' for a custom structure.  But
then of course, you cannot duplicate the 'no ref' aspect of the index either.

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


[Issue 5604] Clarify whether this is a bug or a feature

2011-02-17 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=5604


Walter Bright  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||bugzi...@digitalmars.com
 Resolution||INVALID


--- Comment #1 from Walter Bright  2011-02-17 
10:52:26 PST ---
It's a feature, as you can still use uints to index an array in 64 bit code.

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