File tree 2 files changed +21
-0
lines changed
2 files changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -200,6 +200,7 @@ public string Generate()
200
200
201
201
return s
202
202
. Replace ( "{Body}" , Properties . Resources . AddTokenTemplate )
203
+ . Replace ( "{AllBody}" , Properties . Resources . AddTokenTemplate )
203
204
. Replace ( "PreviousChar();" , "charIndex--;" ) ;
204
205
}
205
206
}
Original file line number Diff line number Diff line change @@ -112,6 +112,26 @@ bool NextChar()
112
112
113
113
return tokens ;
114
114
}
115
+
116
+ public List < { Token } > GetAllTokens ( )
117
+ {
118
+ charIndex = - 1 ;
119
+
120
+ { TokenType } tokenType;
121
+
122
+ int lastIndex = - 1 ;
123
+
124
+ var tokens = new List < { Token } > ( ) ;
125
+
126
+ while ( ( tokenType = GetToken ( ) ) != { TokenType } . EndOfFile )
127
+ {
128
+ { AllBody }
129
+
130
+ lastIndex = charIndex ;
131
+ }
132
+
133
+ return tokens ;
134
+ }
115
135
}
116
136
}
117
137
#pragma warning restore 0162
You can’t perform that action at this time.
0 commit comments