I complained about this a while ago, and I was sure I read somewhere where Mark or Skid said that it had been or would be changed. Not on my thread, I don't think, but somewhere.
But no, it's still possible :
or even
This is a debugging nightmare. It's so easy to make a mistake because the compiler won't alert you to it.
Now I don't mind if it happens in non-strict, I don't mind if it happens in Strict. I don't even mind if it's possible in SuperStrict as long as it's done with an explicit type cast. But to have TAnything cast to a Byte Ptr automatically is just asking for problems.
I fully accept that this problem only arises if you're a bit stupid ( I am! ) and you're prone to making a lot of stupid mistakes ( That's me! ) but that's what Strict and SuperStrict are for, isn't it? To stop stupid people making stupid mistakes?
But no, it's still possible :
SuperStrict Function AFunc(B:Byte Ptr) End Function Type TAnything Field Something:Int Field SomethingElse:Float Field SomethingDifferent:String End Type Global AThing:TAnything=New TAnything AFunc(AThing)
or even
Type TAnything Field Something:Int Field SomethingElse:Float Field SomethingDifferent:String End Type Global AThing:TAnything=New TAnything Global B:Byte Ptr=AThing
This is a debugging nightmare. It's so easy to make a mistake because the compiler won't alert you to it.
Now I don't mind if it happens in non-strict, I don't mind if it happens in Strict. I don't even mind if it's possible in SuperStrict as long as it's done with an explicit type cast. But to have TAnything cast to a Byte Ptr automatically is just asking for problems.
I fully accept that this problem only arises if you're a bit stupid ( I am! ) and you're prone to making a lot of stupid mistakes ( That's me! ) but that's what Strict and SuperStrict are for, isn't it? To stop stupid people making stupid mistakes?