ID:2249713
 
(See the best response by Nadrew.)
so I have defined a datum containing only var x=1 and a public var x=2
A              //Datum A
var/x=1
B //Datum B
var/y

var/x=2


mob/verb/printt()
var/B/b=new()
b.y=new/A()

world<<b.y:x

Instead of printing b.y:x it printed public var x, is this intentional??

I mean should compiler search x inside y??
Best response
With the : operator you're making it hard for the compiler to actually figure out which variable you're after, should work fine with the . operator.

However, you generally should avoid naming local variables after global ones and vise versa, it makes code readability a nightmare.