add getType to primitiveType in AST