aboutsummaryrefslogtreecommitdiffstats
path: root/lib/parsetools/src
diff options
context:
space:
mode:
authorHans Bolinder <[email protected]>2017-05-31 08:38:18 +0200
committerHans Bolinder <[email protected]>2017-06-09 09:11:14 +0200
commit3e7e60b8de877de014467eec488038b89fe41a9d (patch)
tree0dd1dabbfe275f91d81615b52a18bbf63872f1e6 /lib/parsetools/src
parent32d1fbc35eda854bab579bdb46edfb3eccf522c2 (diff)
downloadotp-3e7e60b8de877de014467eec488038b89fe41a9d.tar.gz
otp-3e7e60b8de877de014467eec488038b89fe41a9d.tar.bz2
otp-3e7e60b8de877de014467eec488038b89fe41a9d.zip
parsetools: Improve handling of Unicode atoms
Diffstat (limited to 'lib/parsetools/src')
-rw-r--r--lib/parsetools/src/yecc.erl6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/parsetools/src/yecc.erl b/lib/parsetools/src/yecc.erl
index 48559ec402..36e33b52a4 100644
--- a/lib/parsetools/src/yecc.erl
+++ b/lib/parsetools/src/yecc.erl
@@ -2597,18 +2597,18 @@ format_symbol(Symbol) ->
String = concat([Symbol]),
case erl_scan:string(String) of
{ok, [{atom, _, _}], _} ->
- io_lib:fwrite(<<"~w">>, [Symbol]);
+ io_lib:fwrite(<<"~tw">>, [Symbol]);
{ok, [{Word, _}], _} when Word =/= ':', Word =/= '->' ->
case erl_scan:reserved_word(Word) of
true ->
String;
false ->
- io_lib:fwrite(<<"~w">>, [Symbol])
+ io_lib:fwrite(<<"~tw">>, [Symbol])
end;
{ok, [{var, _, _}], _} ->
String;
_ ->
- io_lib:fwrite(<<"~w">>, [Symbol])
+ io_lib:fwrite(<<"~tw">>, [Symbol])
end.
inverse(L) ->