bug-bison
[Top][All Lists]
Advanced

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

Re: Contexts


From: Bruno Haible
Subject: Re: Contexts
Date: Sun, 19 Apr 2020 16:33:37 +0200
User-agent: KMail/5.1.3 (Linux/4.4.0-177-generic; KDE/5.18.0; x86_64; ; )

Hi Akim,

> >> but I believe contexts would help
> >> (https://www.gnu.org/software/gettext/manual/html_node/Contexts.html).
> > 
> > I don't think contexts can help here. Context are a kind of namespacing
> > system within a translation domain.
> 
> I was addressing the fact that token names might be too short
> and be in conflict with other occurrences of the same word.

Ah yes, for this issue, contexts are a solution.
(Now that you state what problem you want to solve, I agree with you :).)

> In Ruby, I frequently use s_ in such a case.
> 
> You didn't answer that part.  You dislike the idea of s_?

s_("foo|bar") is just a different way of writing pgettext("foo","bar").
Which one you prefer, is mostly a matter of style, I'd say.

Bruno




reply via email to

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