@@ -226,24 +226,61 @@ class StringComponent extends AstNode, TStringComponent {
226226 * ```
227227 */
228228class StringTextComponent extends StringComponent , TStringTextComponentNonRegexp {
229+ final override string getAPrimaryQlClass ( ) { result = "StringTextComponent" }
230+
231+ /** Gets the text of this component as it appears in the source code. */
232+ string getRawText ( ) { none ( ) }
233+ }
234+
235+ private class StringTextComponentStringOrHeredocContent extends StringTextComponent ,
236+ TStringTextComponentNonRegexpStringOrHeredocContent {
229237 private Ruby:: Token g ;
230238
231- StringTextComponent ( ) { this = TStringTextComponentNonRegexp ( g ) }
239+ StringTextComponentStringOrHeredocContent ( ) {
240+ this = TStringTextComponentNonRegexpStringOrHeredocContent ( g )
241+ }
232242
233243 final override string toString ( ) { result = this .getRawText ( ) }
234244
235245 final override ConstantValue:: ConstantStringValue getConstantValue ( ) {
236246 result .isString ( this .getUnescapedText ( ) )
237247 }
238248
239- final override string getAPrimaryQlClass ( ) { result = "StringTextComponent" }
240-
241- /** Gets the text of this component as it appears in the source code. */
242- final string getRawText ( ) { result = g .getValue ( ) }
249+ final override string getRawText ( ) { result = g .getValue ( ) }
243250
244251 final private string getUnescapedText ( ) { result = unescapeTextComponent ( this .getRawText ( ) ) }
245252}
246253
254+ private class StringTextComponentSimpleSymbol extends StringTextComponent ,
255+ TStringTextComponentNonRegexpSimpleSymbol {
256+ private Ruby:: SimpleSymbol g ;
257+
258+ StringTextComponentSimpleSymbol ( ) { this = TStringTextComponentNonRegexpSimpleSymbol ( g ) }
259+
260+ final override string toString ( ) { result = getSimpleSymbolValue ( g ) }
261+
262+ final override ConstantValue:: ConstantStringValue getConstantValue ( ) {
263+ result .isString ( getSimpleSymbolValue ( g ) )
264+ }
265+
266+ final override string getRawText ( ) { result = getSimpleSymbolValue ( g ) }
267+ }
268+
269+ private class StringTextComponentHashKeySymbol extends StringTextComponent ,
270+ TStringTextComponentNonRegexpHashKeySymbol {
271+ private Ruby:: HashKeySymbol g ;
272+
273+ StringTextComponentHashKeySymbol ( ) { this = TStringTextComponentNonRegexpHashKeySymbol ( g ) }
274+
275+ final override string toString ( ) { result = g .getValue ( ) }
276+
277+ final override ConstantValue:: ConstantStringValue getConstantValue ( ) {
278+ result .isString ( g .getValue ( ) )
279+ }
280+
281+ final override string getRawText ( ) { result = g .getValue ( ) }
282+ }
283+
247284/**
248285 * An escape sequence component of a string or string-like literal.
249286 */
@@ -575,18 +612,6 @@ class SymbolLiteral extends StringlikeLiteral, TSymbolLiteral {
575612 }
576613}
577614
578- private class SimpleSymbolLiteral extends SymbolLiteral , TSimpleSymbolLiteral {
579- private Ruby:: SimpleSymbol g ;
580-
581- SimpleSymbolLiteral ( ) { this = TSimpleSymbolLiteral ( g ) }
582-
583- final override ConstantValue:: ConstantSymbolValue getConstantValue ( ) {
584- result .isSymbol ( getSimpleSymbolValue ( g ) )
585- }
586-
587- final override string toString ( ) { result = g .getValue ( ) }
588- }
589-
590615/**
591616 * A subshell literal.
592617 *
0 commit comments