unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
* scm_i_print_symbol_name() in libguile/print.c ...
@ 2011-04-05 15:27 Wolfgang J Moeller
  2011-04-11 11:50 ` Andy Wingo
  2011-04-11 11:50 ` Andy Wingo
  0 siblings, 2 replies; 7+ messages in thread
From: Wolfgang J Moeller @ 2011-04-05 15:27 UTC (permalink / raw)
  To: bug-guile

scm_i_print_symbol_name() in libguile/print.c ought not insert backslashes
into "weird" symbol names that it prints using #{ ... }#,
because the "extended read syntax" (in agreement with the documentation)
doesn't treat backslashes specially, nor _usually_ needs escaping. (*)

I notice that the bug is already present in GUILE V1.8 .

(*) Apparently, reading a "weird" symbol whose name contains "}#"
    isn't provided for.


Example:

===

scheme@(guile-user)> (string-length (symbol->string '#{a b}#))
$1 = 3
scheme@(guile-user)> (string-length (symbol->string (with-input-from-string
                      (with-output-to-string (lambda () (display '#{a b}#)))
                      (lambda () (read)))))
$2 = 4

===

Best regards,

Wolfgang J. Moeller, Tel. +49 551 47361, wjm<AT>heenes.com
37085 Goettingen, Germany | Disclaimer: No claim intended!
http://www.wjmoeller.de/ -+-------- http://www.heenes.com/



^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2011-04-11 15:16 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-04-05 15:27 scm_i_print_symbol_name() in libguile/print.c Wolfgang J Moeller
2011-04-11 11:50 ` Andy Wingo
2011-04-11 12:23   ` Wolfgang J Moeller
2011-04-11 15:00     ` Andy Wingo
2011-04-11 11:50 ` Andy Wingo
2011-04-11 13:08   ` Wolfgang J Moeller
2011-04-11 15:16     ` Andy Wingo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).