Matches all string literals.
This pattern only matches nodes of type expression.
Properties
stringLiteral produces a record that contains the following property:
| Name | Type | Description |
|---|---|---|
valueString |
string |
The value of the string literal.
|
Inherits properties from:
Example
The following pattern finds assignments from the string literal "Example":
pattern assignmentsToStringLiterals {
assignmentOperator {
.sourceExpression == stringLiteral { .value == "Example" }
}
};