Skip to content

Commit aacc5a6

Browse files
author
Rodolfo Totaro
committed
eclipse-archived#190 POC: Fixed insertion on directors
1 parent 259e330 commit aacc5a6

File tree

19 files changed

+2160
-1965
lines changed

19 files changed

+2160
-1965
lines changed

org.eclipse.triquetrum.commands.xtext.ide/src/main/java-gen/org/eclipse/triquetrum/commands/ide/contentassist/antlr/TqclParser.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ protected String getRuleName(AbstractElement element) {
3636
private static final long serialVersionUID = 1L;
3737
{
3838
put(grammarAccess.getCommandAccess().getAlternatives_0(), "rule__Command__Alternatives_0");
39+
put(grammarAccess.getNamedObjAccess().getNameAlternatives_0(), "rule__NamedObj__NameAlternatives_0");
3940
put(grammarAccess.getJvmTypeReferenceAccess().getAlternatives(), "rule__JvmTypeReference__Alternatives");
4041
put(grammarAccess.getJvmArgumentTypeReferenceAccess().getAlternatives(), "rule__JvmArgumentTypeReference__Alternatives");
4142
put(grammarAccess.getJvmWildcardTypeReferenceAccess().getAlternatives_2(), "rule__JvmWildcardTypeReference__Alternatives_2");
@@ -81,7 +82,7 @@ protected String getRuleName(AbstractElement element) {
8182
put(grammarAccess.getQualifiedNameInStaticImportAccess().getGroup(), "rule__QualifiedNameInStaticImport__Group__0");
8283
put(grammarAccess.getTriquetrumScriptAccess().getCommandsAssignment(), "rule__TriquetrumScript__CommandsAssignment");
8384
put(grammarAccess.getInsertAccess().getObjAssignment_1(), "rule__Insert__ObjAssignment_1");
84-
put(grammarAccess.getInsertAccess().getAliasAssignment_2_1(), "rule__Insert__AliasAssignment_2_1");
85+
put(grammarAccess.getInsertAccess().getNameAssignment_2_1(), "rule__Insert__NameAssignment_2_1");
8586
put(grammarAccess.getInsertAccess().getParametersAssignment_3_1(), "rule__Insert__ParametersAssignment_3_1");
8687
put(grammarAccess.getInsertAccess().getParametersAssignment_3_2_1(), "rule__Insert__ParametersAssignment_3_2_1");
8788
put(grammarAccess.getParameterAccess().getValueAssignment_2(), "rule__Parameter__ValueAssignment_2");

org.eclipse.triquetrum.commands.xtext.ide/src/main/java-gen/org/eclipse/triquetrum/commands/ide/contentassist/antlr/internal/InternalTqcl.g

Lines changed: 30 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -603,6 +603,27 @@ finally {
603603
restoreStackSize(stackSize);
604604
}
605605

606+
rule__NamedObj__NameAlternatives_0
607+
@init {
608+
int stackSize = keepStackSize();
609+
}
610+
:
611+
(
612+
{ before(grammarAccess.getNamedObjAccess().getNameQualifiedNameParserRuleCall_0_0()); }
613+
ruleQualifiedName
614+
{ after(grammarAccess.getNamedObjAccess().getNameQualifiedNameParserRuleCall_0_0()); }
615+
)
616+
|
617+
(
618+
{ before(grammarAccess.getNamedObjAccess().getNameSTRINGTerminalRuleCall_0_1()); }
619+
RULE_STRING
620+
{ after(grammarAccess.getNamedObjAccess().getNameSTRINGTerminalRuleCall_0_1()); }
621+
)
622+
;
623+
finally {
624+
restoreStackSize(stackSize);
625+
}
626+
606627
rule__JvmTypeReference__Alternatives
607628
@init {
608629
int stackSize = keepStackSize();
@@ -920,9 +941,9 @@ rule__Insert__Group_2__1__Impl
920941
}
921942
:
922943
(
923-
{ before(grammarAccess.getInsertAccess().getAliasAssignment_2_1()); }
924-
(rule__Insert__AliasAssignment_2_1)
925-
{ after(grammarAccess.getInsertAccess().getAliasAssignment_2_1()); }
944+
{ before(grammarAccess.getInsertAccess().getNameAssignment_2_1()); }
945+
(rule__Insert__NameAssignment_2_1)
946+
{ after(grammarAccess.getInsertAccess().getNameAssignment_2_1()); }
926947
)
927948
;
928949
finally {
@@ -3147,15 +3168,15 @@ finally {
31473168
restoreStackSize(stackSize);
31483169
}
31493170

3150-
rule__Insert__AliasAssignment_2_1
3171+
rule__Insert__NameAssignment_2_1
31513172
@init {
31523173
int stackSize = keepStackSize();
31533174
}
31543175
:
31553176
(
3156-
{ before(grammarAccess.getInsertAccess().getAliasNamedObjParserRuleCall_2_1_0()); }
3177+
{ before(grammarAccess.getInsertAccess().getNameNamedObjParserRuleCall_2_1_0()); }
31573178
ruleNamedObj
3158-
{ after(grammarAccess.getInsertAccess().getAliasNamedObjParserRuleCall_2_1_0()); }
3179+
{ after(grammarAccess.getInsertAccess().getNameNamedObjParserRuleCall_2_1_0()); }
31593180
)
31603181
;
31613182
finally {
@@ -3213,9 +3234,9 @@ rule__NamedObj__NameAssignment
32133234
}
32143235
:
32153236
(
3216-
{ before(grammarAccess.getNamedObjAccess().getNameQualifiedNameParserRuleCall_0()); }
3217-
ruleQualifiedName
3218-
{ after(grammarAccess.getNamedObjAccess().getNameQualifiedNameParserRuleCall_0()); }
3237+
{ before(grammarAccess.getNamedObjAccess().getNameAlternatives_0()); }
3238+
(rule__NamedObj__NameAlternatives_0)
3239+
{ after(grammarAccess.getNamedObjAccess().getNameAlternatives_0()); }
32193240
)
32203241
;
32213242
finally {

org.eclipse.triquetrum.commands.xtext.ide/src/main/java-gen/org/eclipse/triquetrum/commands/ide/contentassist/antlr/internal/InternalTqclLexer.java

Lines changed: 37 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -553,10 +553,10 @@ public final void mRULE_ID() throws RecognitionException {
553553
try {
554554
int _type = RULE_ID;
555555
int _channel = DEFAULT_TOKEN_CHANNEL;
556-
// InternalTqcl.g:3643:9: ( ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '$' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '$' | '_' | '0' .. '9' )* )
557-
// InternalTqcl.g:3643:11: ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '$' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '$' | '_' | '0' .. '9' )*
556+
// InternalTqcl.g:3664:9: ( ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '$' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '$' | '_' | '0' .. '9' )* )
557+
// InternalTqcl.g:3664:11: ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '$' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '$' | '_' | '0' .. '9' )*
558558
{
559-
// InternalTqcl.g:3643:11: ( '^' )?
559+
// InternalTqcl.g:3664:11: ( '^' )?
560560
int alt1=2;
561561
int LA1_0 = input.LA(1);
562562

@@ -565,7 +565,7 @@ public final void mRULE_ID() throws RecognitionException {
565565
}
566566
switch (alt1) {
567567
case 1 :
568-
// InternalTqcl.g:3643:11: '^'
568+
// InternalTqcl.g:3664:11: '^'
569569
{
570570
match('^');
571571

@@ -583,7 +583,7 @@ public final void mRULE_ID() throws RecognitionException {
583583
recover(mse);
584584
throw mse;}
585585

586-
// InternalTqcl.g:3643:44: ( 'a' .. 'z' | 'A' .. 'Z' | '$' | '_' | '0' .. '9' )*
586+
// InternalTqcl.g:3664:44: ( 'a' .. 'z' | 'A' .. 'Z' | '$' | '_' | '0' .. '9' )*
587587
loop2:
588588
do {
589589
int alt2=2;
@@ -632,10 +632,10 @@ public final void mRULE_STRING() throws RecognitionException {
632632
try {
633633
int _type = RULE_STRING;
634634
int _channel = DEFAULT_TOKEN_CHANNEL;
635-
// InternalTqcl.g:3645:13: ( ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* ( '\"' )? | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* ( '\\'' )? ) )
636-
// InternalTqcl.g:3645:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* ( '\"' )? | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* ( '\\'' )? )
635+
// InternalTqcl.g:3666:13: ( ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* ( '\"' )? | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* ( '\\'' )? ) )
636+
// InternalTqcl.g:3666:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* ( '\"' )? | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* ( '\\'' )? )
637637
{
638-
// InternalTqcl.g:3645:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* ( '\"' )? | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* ( '\\'' )? )
638+
// InternalTqcl.g:3666:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* ( '\"' )? | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* ( '\\'' )? )
639639
int alt7=2;
640640
int LA7_0 = input.LA(1);
641641

@@ -653,10 +653,10 @@ else if ( (LA7_0=='\'') ) {
653653
}
654654
switch (alt7) {
655655
case 1 :
656-
// InternalTqcl.g:3645:16: '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* ( '\"' )?
656+
// InternalTqcl.g:3666:16: '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* ( '\"' )?
657657
{
658658
match('\"');
659-
// InternalTqcl.g:3645:20: ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )*
659+
// InternalTqcl.g:3666:20: ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )*
660660
loop3:
661661
do {
662662
int alt3=3;
@@ -672,15 +672,15 @@ else if ( ((LA3_0>='\u0000' && LA3_0<='!')||(LA3_0>='#' && LA3_0<='[')||(LA3_0>=
672672

673673
switch (alt3) {
674674
case 1 :
675-
// InternalTqcl.g:3645:21: '\\\\' .
675+
// InternalTqcl.g:3666:21: '\\\\' .
676676
{
677677
match('\\');
678678
matchAny();
679679

680680
}
681681
break;
682682
case 2 :
683-
// InternalTqcl.g:3645:28: ~ ( ( '\\\\' | '\"' ) )
683+
// InternalTqcl.g:3666:28: ~ ( ( '\\\\' | '\"' ) )
684684
{
685685
if ( (input.LA(1)>='\u0000' && input.LA(1)<='!')||(input.LA(1)>='#' && input.LA(1)<='[')||(input.LA(1)>=']' && input.LA(1)<='\uFFFF') ) {
686686
input.consume();
@@ -700,7 +700,7 @@ else if ( ((LA3_0>='\u0000' && LA3_0<='!')||(LA3_0>='#' && LA3_0<='[')||(LA3_0>=
700700
}
701701
} while (true);
702702

703-
// InternalTqcl.g:3645:44: ( '\"' )?
703+
// InternalTqcl.g:3666:44: ( '\"' )?
704704
int alt4=2;
705705
int LA4_0 = input.LA(1);
706706

@@ -709,7 +709,7 @@ else if ( ((LA3_0>='\u0000' && LA3_0<='!')||(LA3_0>='#' && LA3_0<='[')||(LA3_0>=
709709
}
710710
switch (alt4) {
711711
case 1 :
712-
// InternalTqcl.g:3645:44: '\"'
712+
// InternalTqcl.g:3666:44: '\"'
713713
{
714714
match('\"');
715715

@@ -722,10 +722,10 @@ else if ( ((LA3_0>='\u0000' && LA3_0<='!')||(LA3_0>='#' && LA3_0<='[')||(LA3_0>=
722722
}
723723
break;
724724
case 2 :
725-
// InternalTqcl.g:3645:49: '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* ( '\\'' )?
725+
// InternalTqcl.g:3666:49: '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* ( '\\'' )?
726726
{
727727
match('\'');
728-
// InternalTqcl.g:3645:54: ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )*
728+
// InternalTqcl.g:3666:54: ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )*
729729
loop5:
730730
do {
731731
int alt5=3;
@@ -741,15 +741,15 @@ else if ( ((LA5_0>='\u0000' && LA5_0<='&')||(LA5_0>='(' && LA5_0<='[')||(LA5_0>=
741741

742742
switch (alt5) {
743743
case 1 :
744-
// InternalTqcl.g:3645:55: '\\\\' .
744+
// InternalTqcl.g:3666:55: '\\\\' .
745745
{
746746
match('\\');
747747
matchAny();
748748

749749
}
750750
break;
751751
case 2 :
752-
// InternalTqcl.g:3645:62: ~ ( ( '\\\\' | '\\'' ) )
752+
// InternalTqcl.g:3666:62: ~ ( ( '\\\\' | '\\'' ) )
753753
{
754754
if ( (input.LA(1)>='\u0000' && input.LA(1)<='&')||(input.LA(1)>='(' && input.LA(1)<='[')||(input.LA(1)>=']' && input.LA(1)<='\uFFFF') ) {
755755
input.consume();
@@ -769,7 +769,7 @@ else if ( ((LA5_0>='\u0000' && LA5_0<='&')||(LA5_0>='(' && LA5_0<='[')||(LA5_0>=
769769
}
770770
} while (true);
771771

772-
// InternalTqcl.g:3645:79: ( '\\'' )?
772+
// InternalTqcl.g:3666:79: ( '\\'' )?
773773
int alt6=2;
774774
int LA6_0 = input.LA(1);
775775

@@ -778,7 +778,7 @@ else if ( ((LA5_0>='\u0000' && LA5_0<='&')||(LA5_0>='(' && LA5_0<='[')||(LA5_0>=
778778
}
779779
switch (alt6) {
780780
case 1 :
781-
// InternalTqcl.g:3645:79: '\\''
781+
// InternalTqcl.g:3666:79: '\\''
782782
{
783783
match('\'');
784784

@@ -809,12 +809,12 @@ public final void mRULE_ML_COMMENT() throws RecognitionException {
809809
try {
810810
int _type = RULE_ML_COMMENT;
811811
int _channel = DEFAULT_TOKEN_CHANNEL;
812-
// InternalTqcl.g:3647:17: ( '/*' ( options {greedy=false; } : . )* '*/' )
813-
// InternalTqcl.g:3647:19: '/*' ( options {greedy=false; } : . )* '*/'
812+
// InternalTqcl.g:3668:17: ( '/*' ( options {greedy=false; } : . )* '*/' )
813+
// InternalTqcl.g:3668:19: '/*' ( options {greedy=false; } : . )* '*/'
814814
{
815815
match("/*");
816816

817-
// InternalTqcl.g:3647:24: ( options {greedy=false; } : . )*
817+
// InternalTqcl.g:3668:24: ( options {greedy=false; } : . )*
818818
loop8:
819819
do {
820820
int alt8=2;
@@ -839,7 +839,7 @@ else if ( ((LA8_0>='\u0000' && LA8_0<=')')||(LA8_0>='+' && LA8_0<='\uFFFF')) ) {
839839

840840
switch (alt8) {
841841
case 1 :
842-
// InternalTqcl.g:3647:52: .
842+
// InternalTqcl.g:3668:52: .
843843
{
844844
matchAny();
845845

@@ -869,12 +869,12 @@ public final void mRULE_SL_COMMENT() throws RecognitionException {
869869
try {
870870
int _type = RULE_SL_COMMENT;
871871
int _channel = DEFAULT_TOKEN_CHANNEL;
872-
// InternalTqcl.g:3649:17: ( '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? )
873-
// InternalTqcl.g:3649:19: '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )?
872+
// InternalTqcl.g:3670:17: ( '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? )
873+
// InternalTqcl.g:3670:19: '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )?
874874
{
875875
match("//");
876876

877-
// InternalTqcl.g:3649:24: (~ ( ( '\\n' | '\\r' ) ) )*
877+
// InternalTqcl.g:3670:24: (~ ( ( '\\n' | '\\r' ) ) )*
878878
loop9:
879879
do {
880880
int alt9=2;
@@ -887,7 +887,7 @@ public final void mRULE_SL_COMMENT() throws RecognitionException {
887887

888888
switch (alt9) {
889889
case 1 :
890-
// InternalTqcl.g:3649:24: ~ ( ( '\\n' | '\\r' ) )
890+
// InternalTqcl.g:3670:24: ~ ( ( '\\n' | '\\r' ) )
891891
{
892892
if ( (input.LA(1)>='\u0000' && input.LA(1)<='\t')||(input.LA(1)>='\u000B' && input.LA(1)<='\f')||(input.LA(1)>='\u000E' && input.LA(1)<='\uFFFF') ) {
893893
input.consume();
@@ -907,7 +907,7 @@ public final void mRULE_SL_COMMENT() throws RecognitionException {
907907
}
908908
} while (true);
909909

910-
// InternalTqcl.g:3649:40: ( ( '\\r' )? '\\n' )?
910+
// InternalTqcl.g:3670:40: ( ( '\\r' )? '\\n' )?
911911
int alt11=2;
912912
int LA11_0 = input.LA(1);
913913

@@ -916,9 +916,9 @@ public final void mRULE_SL_COMMENT() throws RecognitionException {
916916
}
917917
switch (alt11) {
918918
case 1 :
919-
// InternalTqcl.g:3649:41: ( '\\r' )? '\\n'
919+
// InternalTqcl.g:3670:41: ( '\\r' )? '\\n'
920920
{
921-
// InternalTqcl.g:3649:41: ( '\\r' )?
921+
// InternalTqcl.g:3670:41: ( '\\r' )?
922922
int alt10=2;
923923
int LA10_0 = input.LA(1);
924924

@@ -927,7 +927,7 @@ public final void mRULE_SL_COMMENT() throws RecognitionException {
927927
}
928928
switch (alt10) {
929929
case 1 :
930-
// InternalTqcl.g:3649:41: '\\r'
930+
// InternalTqcl.g:3670:41: '\\r'
931931
{
932932
match('\r');
933933

@@ -959,10 +959,10 @@ public final void mRULE_WS() throws RecognitionException {
959959
try {
960960
int _type = RULE_WS;
961961
int _channel = DEFAULT_TOKEN_CHANNEL;
962-
// InternalTqcl.g:3651:9: ( ( ' ' | '\\t' | '\\r' | '\\n' )+ )
963-
// InternalTqcl.g:3651:11: ( ' ' | '\\t' | '\\r' | '\\n' )+
962+
// InternalTqcl.g:3672:9: ( ( ' ' | '\\t' | '\\r' | '\\n' )+ )
963+
// InternalTqcl.g:3672:11: ( ' ' | '\\t' | '\\r' | '\\n' )+
964964
{
965-
// InternalTqcl.g:3651:11: ( ' ' | '\\t' | '\\r' | '\\n' )+
965+
// InternalTqcl.g:3672:11: ( ' ' | '\\t' | '\\r' | '\\n' )+
966966
int cnt12=0;
967967
loop12:
968968
do {
@@ -1016,8 +1016,8 @@ public final void mRULE_ANY_OTHER() throws RecognitionException {
10161016
try {
10171017
int _type = RULE_ANY_OTHER;
10181018
int _channel = DEFAULT_TOKEN_CHANNEL;
1019-
// InternalTqcl.g:3653:16: ( . )
1020-
// InternalTqcl.g:3653:18: .
1019+
// InternalTqcl.g:3674:16: ( . )
1020+
// InternalTqcl.g:3674:18: .
10211021
{
10221022
matchAny();
10231023

0 commit comments

Comments
 (0)