Commit 4f0aa9ec authored by Johannes Mey's avatar Johannes Mey
Browse files

Merge branch '24-qualified-generic-token-types' into 'master'

Resolve "Qualified generic token types"

Closes #24

See merge request !11
parents b039bd79 85c97e42
Pipeline #5156 passed with stage
in 2 minutes and 18 seconds
......@@ -40,13 +40,11 @@ ArrayList inner_type_use
;
TypeUse type_use =
// s_type_use.u {: return u; :}
// |
parameterized_type_use.p {: return p; :}
| inner_type_use.p {: return new SimpleTypeUse((String)p.stream().map( x -> ((Symbol)x).value.toString()).collect(java.util.stream.Collectors.joining("."))); :}
;
ParameterizedTypeUse parameterized_type_use =
ID LT type_use_list.l GT {: return new ParameterizedTypeUse(ID, l); :}
inner_type_use.i LT type_use_list.l GT {: return new ParameterizedTypeUse((String)i.stream().map( x -> ((Symbol)x).value.toString()).collect(java.util.stream.Collectors.joining(".")), l); :}
;
List type_use_list =
type_use.u {: return new List().add(u); :}
......
......@@ -50,6 +50,7 @@ D ::= SingleA:A ListOfA:A* [OptionalA:A] /NTAA:A/ ;
// production with tokens, nonterminal-tokens, multi-line
E ::= <T1> <T2:String> <T3:boolean> <T4:int> <T5:float> <T6:double> <T7:long>
<T8:java.lang.Object> <T9:ArrayList<String>> <T10:java.util.ArrayList<java.lang.String>>
/<NT2:String>/ /<NT3:boolean>/ /<NT4:int>/ /<NT5:float>/ /<NT6:double>/ /<NT7:long>/ ;
rel E.NT1 -> A ;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment