MantisBT - Ecere SDK
View Issue Details
0001204Ecere SDKecpublic2018-09-17 23:192018-09-17 23:19
CaptainBlackton 
 
normalcrashalways
newopen 
x86:linuxLinux Mint-
0.44.15 
 
0001204: Using *& to reference an inherited class caused compile to fail
In the code included below, using "*&" to explicitly reference the inherited class causes the compile to fail.
import "ecere"

class Form1 : Window
{
   caption = $"Form1";
   background = formColor;
   borderStyle = sizable;
   hasMaximize = true;
   hasMinimize = true;
   hasClose = true;
   clientSize = { 568, 392 };

   Unit unit {};

   Form1()
   {
      int myHp = unit.hp;
      PrintLn(myHp);
   }
}

class GameObject
{
   int hp;
}

class Unit : GameObject
{
   property int hp { get { return *&hp; } set { *&hp = value; } }
}

Form1 form1 {};
No tags attached.
Issue History
2018-09-17 23:19CaptainBlacktonNew Issue

There are no notes attached to this issue.