Skip to content

Commit 1b3ceb5

Browse files
committed
Add encoding into string representation of ImmutableRubyString
1 parent c1900b4 commit 1b3ceb5

16 files changed

+36
-29
lines changed

spec/truffle/parsing/fixtures/case/with_expression_and_when/with_splat_operator_and_preceding_and_following_elements.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -105,16 +105,16 @@ ast: |
105105
values = [
106106
FrozenStringLiteralNode
107107
attributes:
108-
definition = expression
108+
definition = "expression" (ASCII-8BIT)
109109
flags = 0
110-
frozenString = bar
110+
frozenString = "bar" (UTF-8)
111111
sourceCharIndex = 31
112112
sourceLength = 5
113113
FrozenStringLiteralNode
114114
attributes:
115-
definition = expression
115+
definition = "expression" (ASCII-8BIT)
116116
flags = 0
117-
frozenString = baz
117+
frozenString = "baz" (UTF-8)
118118
sourceCharIndex = 38
119119
sourceLength = 5
120120
]

spec/truffle/parsing/fixtures/case/with_expression_and_when/with_string_literal_in_when_clause.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@ ast: |
2828
leftNode_ =
2929
FrozenStringLiteralNode
3030
attributes:
31-
definition = expression
31+
definition = "expression" (ASCII-8BIT)
3232
flags = 0
33-
frozenString = foo
33+
frozenString = "foo" (UTF-8)
3434
sourceCharIndex = 13
3535
sourceLength = 5
3636
rightNode_ =

spec/truffle/parsing/fixtures/case/without_expression_and_when/with_string_literal_in_when_clause.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ ast: |
1818
condition =
1919
FrozenStringLiteralNode
2020
attributes:
21-
definition = expression
21+
definition = "expression" (ASCII-8BIT)
2222
flags = 0
23-
frozenString = foo
23+
frozenString = "foo" (UTF-8)
2424
sourceCharIndex = 10
2525
sourceLength = 5
2626
elseBody =

spec/truffle/parsing/fixtures/hashes/with_string_key.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ ast: |
1515
keyValues = [
1616
FrozenStringLiteralNode
1717
attributes:
18-
definition = expression
18+
definition = "expression" (ASCII-8BIT)
1919
flags = 0
20-
frozenString = foo
20+
frozenString = "foo" (UTF-8)
2121
sourceCharIndex = 1
2222
sourceLength = 5
2323
IntegerFixnumLiteralNode

spec/truffle/parsing/fixtures/method_calls/special_cases/method_-@_when_string_literal.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ ruby: |
88
ast: |
99
FrozenStringLiteralNode
1010
attributes:
11-
definition = method
11+
definition = "method" (ASCII-8BIT)
1212
flags = 1
13-
frozenString = foobar
13+
frozenString = "foobar" (UTF-8)
1414
sourceCharIndex = 0
1515
sourceLength = 9

spec/truffle/parsing/fixtures/method_calls/special_cases/method_dedup_when_string_literal.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ ruby: |
88
ast: |
99
FrozenStringLiteralNode
1010
attributes:
11-
definition = method
11+
definition = "method" (ASCII-8BIT)
1212
flags = 1
13-
frozenString = foobar
13+
frozenString = "foobar" (UTF-8)
1414
sourceCharIndex = 0
1515
sourceLength = 14

spec/truffle/parsing/fixtures/method_calls/special_cases/method_freeze.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ ruby: |
88
ast: |
99
FrozenStringLiteralNode
1010
attributes:
11-
definition = method
11+
definition = "method" (ASCII-8BIT)
1212
flags = 1
13-
frozenString = foobar
13+
frozenString = "foobar" (UTF-8)
1414
sourceCharIndex = 0
1515
sourceLength = 15

spec/truffle/parsing/fixtures/regexps/with_interpolation_without_expression.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ ast: |
4242
ObjectLiteralNode
4343
attributes:
4444
flags = 0
45-
object = ""
45+
object = "" (UTF-8)
4646
sourceCharIndex = 2
4747
sourceLength = 3
4848
ToSNodeGen

spec/truffle/parsing/fixtures/strings/backtick_literal.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,9 @@ ast: |
2727
arguments = [
2828
FrozenStringLiteralNode
2929
attributes:
30-
definition = expression
30+
definition = "expression" (ASCII-8BIT)
3131
flags = 0
32-
frozenString = echo 1
32+
frozenString = "echo 1" (UTF-8)
3333
sourceCharIndex = 0
3434
sourceLength = 8
3535
]

spec/truffle/parsing/fixtures/strings/backtick_literal_with_interpolation_without_expression.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ ast: |
5353
ObjectLiteralNode
5454
attributes:
5555
flags = 0
56-
object = ""
56+
object = "" (UTF-8)
5757
sourceCharIndex = 8
5858
sourceLength = 4
5959
]

0 commit comments

Comments
 (0)