@@ -147,7 +147,7 @@ def test_print_meta(lcompile: CompileFn, s: str, code: str):
147
147
148
148
149
149
def test_print_readably (lcompile : CompileFn ):
150
- assert ' "Hello\n world!"' == lcompile (
150
+ assert "Hello\n world!" == lcompile (
151
151
'(binding [*print-readably* false] (pr-str "Hello\\ nworld!"))'
152
152
)
153
153
@@ -169,6 +169,7 @@ def test_print_readably(lcompile: CompileFn):
169
169
("##-Inf" , "(pr-str ##-Inf)" ),
170
170
('"hi"' , '(pr-str "hi")' ),
171
171
('"Hello\\ nworld!"' , '(pr-str "Hello\n world!")' ),
172
+ (r'"\"Hello world!\""' , r'(pr-str "\"Hello world!\"")' ),
172
173
(
173
174
'#uuid "81f35603-0408-4b3d-bbc0-462e3702747f"' ,
174
175
'(pr-str #uuid "81f35603-0408-4b3d-bbc0-462e3702747f")' ,
@@ -214,6 +215,7 @@ def test_lrepr(lcompile: CompileFn, repr: str, code: str):
214
215
(- float ("inf" ), "(read-string (pr-str ##-Inf))" ),
215
216
("hi" , '(read-string (pr-str "hi"))' ),
216
217
("Hello\n world!" , '(read-string (pr-str "Hello\n world!"))' ),
218
+ ('"Hello world!"' , r'(read-string (pr-str "\"Hello world!\""))' ),
217
219
(b"" , '(read-string (pr-str #b ""))' ),
218
220
(
219
221
b"\x7f ELF\x01 \x01 \x01 \x00 " ,
@@ -267,6 +269,7 @@ def test_lrepr_round_trip_special_cases(lcompile: CompileFn):
267
269
("##-Inf" , "(print-str ##-Inf)" ),
268
270
("hi" , '(print-str "hi")' ),
269
271
("Hello\n world!" , '(print-str "Hello\n world!")' ),
272
+ ('"Hello world!"' , r'(print-str "\"Hello world!\"")' ),
270
273
('#b ""' , '(print-str #b "")' ),
271
274
(
272
275
r'#b "\x7fELF\x01\x01\x01\x00"' ,
@@ -319,6 +322,7 @@ def test_lstr(lcompile: CompileFn, s: str, code: str):
319
322
("##-Inf" , "(str ##-Inf)" ),
320
323
("hi" , '(str "hi")' ),
321
324
("Hello\n world!" , '(str "Hello\n world!")' ),
325
+ ('"Hello world!"' , r'(str "\"Hello world!\"")' ),
322
326
('#b ""' , '(str #b "")' ),
323
327
(
324
328
r'#b "\x7fELF\x01\x01\x01\x00"' ,
0 commit comments