Charj : added AST nodes to support pointers and references
[charm.git] / src / langs / charj / src / charj / translator / Charj.g
index 6d28af2177c985075cc2795a15e9a70c7f074878..742243984cec660f0cc4b375015392bd85f2005a 100644 (file)
@@ -172,6 +172,10 @@ tokens {
     SUPER_CONSTRUCTOR_CALL;
     THIS_CONSTRUCTOR_CALL;
     TYPE;
+    SIMPLE_TYPE;
+    OBJECT_TYPE;
+    REFERENCE_TYPE;
+    POINTER_TYPE;
     PRIMITIVE_VAR_DECLARATION;
     OBJECT_VAR_DECLARATION;
     VAR_DECLARATOR;
@@ -402,12 +406,12 @@ type
 
 simpleType
     :   primitiveType arrayDeclaratorList?
-        ->  ^(TYPE primitiveType arrayDeclaratorList?)  
+        ->  ^(SIMPLE_TYPE primitiveType arrayDeclaratorList?)  
     ;
 
 objectType
     :   qualifiedTypeIdent arrayDeclaratorList?
-        ->  ^(TYPE qualifiedTypeIdent arrayDeclaratorList?)
+        ->  ^(OBJECT_TYPE qualifiedTypeIdent arrayDeclaratorList?)
     ;
 
 qualifiedTypeIdent