1
0
mirror of https://github.com/janet-lang/janet synced 2025-11-02 16:43:02 +00:00

Use more inclusive check for the %j formatter for valid symbols.

We did not allow arbitrary utf8 to be printed with %j, even though the parser
allows. Thos changes uses the existing built in utf8 detectiotion to
exclude only unprintable symbols from the docstring.
This commit is contained in:
Calvin Rose
2021-10-29 11:08:53 -05:00
parent 8b2d278840
commit 6e38bf1578
5 changed files with 14 additions and 19 deletions

View File

@@ -202,6 +202,7 @@
#🐙🐙🐙🐙
(defn foo [Θa Θb Θc] 0)
(def 🦊 :fox)
(def 🐮 :cow)
(assert (= (string "🐼" 🦊 🐮) "🐼foxcow") "emojis 🙉 :)")