Skip to content

Commit 322159c

Browse files
authored
Add test for call with thai atom (#13952)
1 parent cc68ad9 commit 322159c

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

lib/elixir/test/elixir/kernel/string_tokenizer_test.exs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,15 @@ defmodule Kernel.StringTokenizerTest do
7070
assert {:error, _} = Code.string_to_quoted("Ola!")
7171
end
7272

73+
test "tokenizes remote calls" do
74+
# We chose the atom below because Erlang represents it using nested lists
75+
assert {{:., _, [:foo, :บูมเมอแรง]}, _, []} =
76+
Code.string_to_quoted!(":foo.บูมเมอแรง()")
77+
78+
assert {{:., _, [:foo, :บูมเมอแรง]}, _, []} =
79+
Code.string_to_quoted!(":foo.\"บูมเมอแรง\"()")
80+
end
81+
7382
describe "script mixing" do
7483
test "prevents Restricted codepoints in identifiers" do
7584
exception = assert_raise SyntaxError, fn -> Code.string_to_quoted!("_shibㅤ = 1") end

0 commit comments

Comments
 (0)