With the externs classes A, B and C, used as A.createB().createC().hello
I get Cannot access static field createC from a class instance
If I use real classes RealA, RealB and RealC, used as RealA.createRealB().createRealC().hello
I get the same error as before. But if I remove the return type from each createReal
method, the code compiles and works as expected.
In the titanium desktop externs, quite afew methods use the layout shown above. API.getApplication().getArgument()
causes the same error above.
I think I'm doing something stupid, and I'm not seeing it.
:|
You're mistaking the "type" RealC which means "an instance of the class Realc" with the "value-class" RealC which is an object which contain both static methods and properties.