B
Bob
Hi,
'Shadowed' properties are not polymorphic. (See thread 'Inheritance and late
binding')
They should be.
Problem:
Base class has read only property 'X'.
Derived class must have read / write property 'X'.
Can't override Base class 'X' because of different structure.
So you Shadow the base class 'X' in the derived class.
Pass an instance of the derived class to a function.
Read 'X' in the function. You get the base class read not the derived
class.
Workaround is to relax the interface of the Base class 'X' so that it is
read/write and use Overrides instead of Shadows.
Fixed in next build perhaps?
Bob
'Shadowed' properties are not polymorphic. (See thread 'Inheritance and late
binding')
They should be.
Problem:
Base class has read only property 'X'.
Derived class must have read / write property 'X'.
Can't override Base class 'X' because of different structure.
So you Shadow the base class 'X' in the derived class.
Pass an instance of the derived class to a function.
Read 'X' in the function. You get the base class read not the derived
class.
Workaround is to relax the interface of the Base class 'X' so that it is
read/write and use Overrides instead of Shadows.
Fixed in next build perhaps?
Bob