Why is ⎕THIS in a shared method not deterministic
Posted: Sun Oct 25, 2020 11:55 am
When i call a public shared method from outside, ⎕THIS is a reference to the class.
If I call this shared method from an instance method of the same class, ⎕THIS is a reference to the instance.
As a workaround I use in my static method (↑⊃⊃⎕CLASS ⎕THIS) instead simply ⎕THIS.
If I call this shared method from an instance method of the same class, ⎕THIS is a reference to the instance.
As a workaround I use in my static method (↑⊃⊃⎕CLASS ⎕THIS) instead simply ⎕THIS.