guile-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [patch] i18n, l10n, gettext and something more


From: Daniel Skarda
Subject: Re: [patch] i18n, l10n, gettext and something more
Date: 05 Aug 2001 02:22:45 +0000
User-agent: Gnus/5.0806 (Gnus v5.8.6) Emacs/20.6

Neil Jerram <address@hidden> writes:
> Perhaps in future it will be nice to implement source properties using
> `make-object-property', then anything that is distinguishable by `eq?'
> can have source properties.  (This includes all strings, but
> unfortunately excludes multiple occurrences of the same numbers,
> symbols, #t and #f ...)

 Maybe this would be unnecessary overhead. For debugging purposes is source
property for beginning of each parenthesized expression sufficient and it is
hard to think about example when such information would be great improvement.
I think that fancy/extensible reader is more powerful tool.


> This approach would never be able to preserve the difference between
> an implicit and explicit newline in, say,
> 
> "hello\nbig
> world"
>
> but do you need to preserve even this difference?

  Because of .po file format (design inspired by C strings) your example would
  be extracted as:

"hello\nbig\n"
"world"

  But except #\newline any character does not need to be explicitly escaped. So
my idea is that when programmer wrote \t (or " ") he knew what he was doing and
translator should see the same string when translating messages (because usually
(not (eq? translator programmer)) :)
 
> Thanks again for explaining.  Since a comment should, by definition,
> never be returned from `read', perhaps we could make comment text
> available through a `comment-text-hook' in the reader?

  That's almost how it works now (although I choose name read-extend). Before I
start working on other reader extensions (and reinventing the wheel) I am going
to look into Common Lisp books (as suggested by Marius).

0.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]