@@ -75,7 +75,6 @@ shared static this()
7575 typeMap[typeid (XorExpression)] = 48 ;
7676 typeMap[typeid (InterpolatedStringExpression)] = 49 ;
7777 typeMap[typeid (InterpolatedStringText)] = 50 ;
78- typeMap[typeid (InterpolatedStringVariable)] = 51 ;
7978}
8079
8180// / Describes which syntax was used in a list of declarations in the containing AST node
@@ -170,7 +169,7 @@ abstract class ASTVisitor
170169 case 46 : visit(cast (TypeofExpression) n); break ;
171170 case 47 : visit(cast (UnaryExpression) n); break ;
172171 case 48 : visit(cast (XorExpression) n); break ;
173- // skip 49, 50, 51 (used for InterpolatedStringPart)
172+ // skip 49, 50 (used for InterpolatedStringPart)
174173 default : assert (false , __MODULE__ ~ " has a bug" );
175174 }
176175 }
@@ -182,7 +181,6 @@ abstract class ASTVisitor
182181 {
183182 case 49 : visit(cast (InterpolatedStringExpression) n); break ;
184183 case 50 : visit(cast (InterpolatedStringText) n); break ;
185- case 51 : visit(cast (InterpolatedStringVariable) n); break ;
186184 default : assert (false , __MODULE__ ~ " has a bug" );
187185 }
188186 }
@@ -308,7 +306,6 @@ abstract class ASTVisitor
308306 /* * */ void visit(const InterpolatedString interpolatedString) { interpolatedString.accept(this ); }
309307 /* * */ void visit(const InterpolatedStringExpression interpolatedStringExpression) { interpolatedStringExpression.accept(this ); }
310308 /* * */ void visit(const InterpolatedStringText interpolatedStringText) { interpolatedStringText.accept(this ); }
311- /* * */ void visit(const InterpolatedStringVariable interpolatedStringVariable) { interpolatedStringVariable.accept(this ); }
312309 /* * */ void visit(const Invariant invariant_) { invariant_.accept(this ); }
313310 /* * */ void visit(const IsExpression isExpression) { isExpression.accept(this ); }
314311 /* * */ void visit(const KeyValuePair keyValuePair) { keyValuePair.accept(this ); }
@@ -2382,12 +2379,12 @@ final class InterpolatedString : BaseNode
23822379 mixin OpEquals! (" startQuote.text" , " postfixType" );
23832380}
23842381
2385- // /
2382+ // / AST nodes within an interpolated string
23862383abstract class InterpolatedStringPart : BaseNode
23872384{
23882385}
23892386
2390- // /
2387+ // / Just plain text inside the interpolated string
23912388final class InterpolatedStringText : InterpolatedStringPart
23922389{
23932390 override void accept (ASTVisitor visitor) const
@@ -2403,29 +2400,7 @@ final class InterpolatedStringText : InterpolatedStringPart
24032400 mixin OpEquals! (" text.text" );
24042401}
24052402
2406- // /
2407- final class InterpolatedStringVariable : InterpolatedStringPart
2408- {
2409- override void accept (ASTVisitor visitor) const
2410- {
2411- }
2412-
2413- // / The dollar token.
2414- inout (Token ) dollar () inout pure nothrow @nogc @safe scope
2415- {
2416- return tokens.length == 2 ? tokens[0 ] : Token .init;
2417- }
2418-
2419- // / The variable name token.
2420- inout (Token ) name () inout pure nothrow @nogc @safe scope
2421- {
2422- return tokens.length == 2 ? tokens[1 ] : Token .init;
2423- }
2424-
2425- mixin OpEquals! (" name.text" );
2426- }
2427-
2428- // /
2403+ // / A $(...) interpolation sequence
24292404final class InterpolatedStringExpression : InterpolatedStringPart
24302405{
24312406 override void accept (ASTVisitor visitor) const
0 commit comments