MantisBT - Ecere SDK
View Issue Details
0000644Ecere SDKcompilerpublic2011-09-25 01:552014-08-08 18:17
jerome 
jerome 
immediatemajorhave not tried
closedfixed 
0.44.09 
0.44.10 640.44.10 64 
0000644: Iterating an enum value with ints converts to an unrelated property
The following code converts the 'PlayerColor c' to a BlokusColor while it shouldn't:

public enum BlokusColor : byte { none, blue, yellow, red, green };

public enum PlayerColor : byte
{
   blue, yellow, red, green;
   property BlokusColor
   {
      // TODO: Fix this!!
      get { return (BlokusColor)*(int *)&this+1; }
   }
};


PlayerColor c;
int p;
for(c = 0; c < 4; c++)
{

}
No tags attached.
Issue History
2011-09-25 01:55jeromeNew Issue
2012-03-08 15:43redjTarget Versionold 0.44.pre2 => 0.45 Ginkakuji
2012-03-29 07:50redjCategory => eC Compiling Tools
2012-03-29 07:50redjProject@2@ => Ecere SDK
2013-04-26 18:28jeromeTarget Version0.45 Ginkakuji => 0.44.8 Silver
2014-05-19 20:09jeromeAssigned To => jerome
2014-05-19 20:09jeromeStatusnew => assigned
2014-05-19 20:09jeromeProduct Version => 0.44.09
2014-05-19 20:09jeromeTarget Version0.44.80 Silver => 0.44.10 64
2014-05-27 01:31jeromeStatusassigned => resolved
2014-05-27 01:31jeromeFixed in Version => 0.44.10 64
2014-05-27 01:31jeromeResolutionopen => fixed
2014-05-27 01:31jeromeNote Added: 0001319
2014-08-08 18:17jeromeStatusresolved => closed

Notes
(0001319)
jerome   
2014-05-27 01:31   
Fixed by:
https://github.com/ecere/ecere-sdk/commit/981767e16256c835738562f4280e06140dcc0067 [^]