class Test def main is shared pass def foo x as int = .bar # forward reference assert x==1 get bar as int return 1