Casting to interface not allowed in @safe code?

Jim jimwoo21680 at hotmail.com
Tue May 21 07:59:13 UTC 2019


On Tuesday, 21 May 2019 at 07:33:17 UTC, rumbu wrote:
> On Tuesday, 21 May 2019 at 07:16:49 UTC, Jim wrote:
>> On Tuesday, 21 May 2019 at 07:04:27 UTC, rumbu wrote:
>>> On Tuesday, 21 May 2019 at 05:51:30 UTC, Jim wrote:
>>>
>>> That's because foo is of type Base, not implementing FeatureX.
>>
>> Right, Base isn't implementing FeatureX, but foo is really a 
>> Foo
>
> That's your knowledge, for the compiler foo is really a Base, 
> as written in your own code.
>

Yes, thinking about it again it makes sense.


More information about the Digitalmars-d-learn mailing list