9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: Charles Forsyth <forsyth@terzarima.net>
To: lucio@proxima.alt.za, 9fans@cse.psu.edu
Subject: Re: [9fans] GNU Make
Date: Thu,  3 Jun 2004 09:49:57 +0100	[thread overview]
Message-ID: <3a96057432a34fc38f4577b0b7b468a9@terzarima.net> (raw)
In-Reply-To: <df41879105515b8c3643ceff29d03796@proxima.alt.za>

>>The former is a continuing "failure of vision" that will eventually be
>>resolved out of necessity.  The latter may be solved with the former

i wonder if a message got lost.  in another commercial product a group
of us years ago handled messages in many natural languages in programs without fuss,
in a serious commercial product that was, and i believe still is,
widely used with many Western European languages.  it did not need the
use of message codes.  strings worked well.
the text of the message in the program was its own `index'.  still seems
straightforward to me.  the strings are anyway the subject
of translation by the translators!  you can't get away from them.
all those strcmps?  hash.  works for messages in files, too,
though there are other searching techniques.  more recently, an even
simpler scheme for messages was successfully used in Limbo applications.
i used a hash table, but as it happens, i accidentally produced
a degenerate one.  i still didn't notice for two years, even with profiling;
it's just not that much of a bottleneck in many cases.

it's the least of your worries as i said before: working out how to arrange
the strings to cope with the differing requirements of various natural languages
for word order, or `dictionary order' (which can vary across dialects of the
same language), and several other things, all require extra mechanisms.
for each string in a program, one needs to decide whether the text is essentially
`program' or whether it's `speech'.
it's helpful to have a conventional form for the text of such messages so
they can be extracted automatically for translation (assuming the compiler can't assist).

in many cases, system diagnostics
should not be translated (or indeed must not be translated) because they are input
to other programs, or internal diagnostics that should remain as-is.
actually, given the extent of program tools when scripting, it's probably
true that most existing messages wouldn't be translated anyway.
one of the nice things about the change to largely GUI-oriented interfaces
is that it's more obvious which bits of text are intended to be understood
by users of an application.  most output of programs such as sed, file, etc.
would not be seen directly (by a `real' end user).

the failure of vision here is to think that just using integers will solve anything.
first, it complicates distributed development (who assigns the integers?
shall we have the usual hack of a `user-defined range'?  what happens when
i federate two systems?), as the varying assignment
within Unix systems shows, and they were dealing with a largely fixed set of
system calls and outcomes (so in principal one could enumerate most of
the possibilities).  even then, quite a few things settle for EIO.
that's a great help.

to get round the problem of differing errno assignments in Unix, one could
use EAGAIN (or is it EWOULDBLOCK?), ENOENT, etc. but hang on: that's
just a string and you'll still need to put it through a map.  EBAHGUM.

more important, with user-level file servers
the set of possible diagnostics is unbounded, because the range of application
is not limited as it was (at least until recently) in Unix.

there is a smaller `failure of vision' though: Lucio is right that a little
more discipline in forming the text of the strings might help.
file servers that really do serve up real files could use the same text
for the same errors.  it's a rather tedious job to go round the source to do it,
but it's no more tedious than collecting messages for translation in any case.


  reply	other threads:[~2004-06-03  8:49 UTC|newest]

Thread overview: 96+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-06-01 11:09 lucio
2004-06-01 16:37 ` boyd, rounin
2004-06-01 21:03   ` ron minnich
2004-06-01 21:09     ` boyd, rounin
2004-06-01 21:43     ` Russ Cox
2004-06-01 21:49       ` ron minnich
2004-06-01 22:03         ` Russ Cox
2004-06-01 22:08           ` boyd, rounin
2004-06-02  5:34     ` lucio
2004-06-02  7:36       ` Charles Forsyth
2004-06-02  9:07         ` John Murdie
2004-06-02  9:39           ` Charles Forsyth
2004-06-02 16:12         ` ron minnich
2004-06-02 16:24           ` lucio
2004-06-02 16:54             ` ron minnich
2004-06-02 16:56               ` boyd, rounin
2004-06-03  6:41                 ` lucio
2004-06-03  8:49                   ` Charles Forsyth [this message]
2004-06-03  9:16                     ` boyd, rounin
2004-06-03  9:50                       ` Error reporting (Was: [9fans] GNU Make) lucio
2004-06-03 14:01                         ` rog
2004-06-03 13:54                           ` Charles Forsyth
2004-06-03 14:19                             ` rog
2004-06-03 14:18                               ` boyd, rounin
2004-06-03 14:31                                 ` lucio
2004-06-03 14:33                                 ` rog
2004-06-03 14:58                               ` Charles Forsyth
2004-06-03 15:13                                 ` lucio
2004-06-03 15:17                                 ` rog
2004-06-03 16:12                                   ` C H Forsyth
2004-06-03 16:18                                     ` rog
2004-06-03 16:18                                       ` Charles Forsyth
2004-06-03 16:38                                         ` rog
2004-06-03 16:56                                           ` C H Forsyth
2004-06-03 17:03                                             ` rog
2004-06-03 17:15                                               ` C H Forsyth
2004-06-03 17:25                                                 ` rog
2004-06-03 19:10                                               ` boyd, rounin
2004-06-03 19:08                                           ` boyd, rounin
2004-06-03 19:35                                             ` rog
2004-06-03 19:46                                               ` boyd, rounin
2004-06-03 20:06                                                 ` rog
2004-06-03 22:09                                                   ` Charles Forsyth
2004-06-04  1:05                                                     ` Bruce Ellis
2004-06-04  1:56                                                       ` Scott Schwartz
2004-06-04  2:10                                                         ` Bruce Ellis
2004-06-04  2:46                                                           ` Russ Cox
2004-06-04  8:08                                                           ` Charles Forsyth
     [not found]                                                       ` <013301c449d2$95929d30$637f7d50@SOMA>
2004-06-04 12:16                                                         ` Bruce Ellis
2004-06-08 15:17                                                       ` rog
2004-06-03 14:06                           ` boyd, rounin
2004-06-03 14:21                             ` rog
2004-06-03 10:31                       ` [9fans] GNU Make lucio
2004-06-03 14:53                         ` Rob Pike
2004-06-03 15:01                           ` boyd, rounin
2004-06-03 15:04                           ` lucio
2004-06-03 15:16                             ` Rob Pike
2004-06-03 15:33                               ` rog
2004-06-03 15:40                                 ` boyd, rounin
2004-06-03 15:58                                   ` lucio
2004-06-03 15:40                               ` lucio
2004-06-03 15:20                             ` [9fans] internationalised error messages boyd, rounin
2004-06-02 21:30         ` [9fans] GNU Make boyd, rounin
2004-06-02  8:54       ` Richard Miller
2004-06-02  9:17         ` lucio
2004-06-02  9:54           ` Charles Forsyth
2004-06-02 16:15           ` ron minnich
2004-06-02 17:00           ` Steve Simon
2004-06-03  5:14             ` lucio
2004-06-02 14:00       ` ron minnich
2004-06-02 14:36         ` C H Forsyth
2004-06-02 14:33           ` Charles Forsyth
2004-06-02 15:24         ` Charles Forsyth
2004-06-02 15:56           ` lucio
2004-06-02 16:11           ` lucio
2004-06-02 19:28             ` Joel Salomon
2004-06-03  4:43               ` [9fans] troff and 4.4BSD man pages Lyndon Nerenberg
2004-06-03  5:54                 ` Taj Khattra
2004-06-03  8:26                 ` boyd, rounin
2004-06-07  8:55                   ` Douglas A. Gwyn
2004-06-07 13:19                     ` Jon Snader
     [not found]                       ` <z4udnTOQMJVTdlndRVn-jg@comcast.com>
2004-06-10 10:58                         ` Aharon Robbins
2004-06-10 12:40                           ` rog
2004-06-10 13:24                             ` Douglas A. Gwyn
2004-06-03 10:13                 ` Bruce Ellis
2004-06-03 10:17                   ` boyd, rounin
2004-06-03 10:27                     ` lucio
2004-06-03 10:29                     ` Bruce Ellis
2004-06-03 10:26                       ` boyd, rounin
2004-06-03 11:18                         ` Bruce Ellis
2004-06-03  1:57             ` [9fans] GNU Make a
2004-06-03  3:31               ` Kenji Okamoto
2004-06-02 11:13 lucio
2004-06-02 16:24 Trickey, Howard W (Howard)
2004-06-02 16:31 ` lucio
2004-06-02 23:53 ` Dan Cross

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3a96057432a34fc38f4577b0b7b468a9@terzarima.net \
    --to=forsyth@terzarima.net \
    --cc=9fans@cse.psu.edu \
    --cc=lucio@proxima.alt.za \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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 NNTP newsgroup(s).