implemented AST and syntax for scope