[pyicu-dev] [PATCH] Add correct namespace declarations everywhere
Fredrik Roubert
roubert at google.com
Tue Sep 11 11:15:13 PDT 2007
On 9/11/07, Steven R. Loomis <srl at icu-project.org> wrote:
> You should automatically get 'using namespace icu;' in C++, it's in
> uversion.h under U_NAMESPACE_USE
>
> I'm not sure why it is necessary to say icu::Locale explicitly.
If you try compiling PyICU, without my patch, against icu4c-3_8_d02
with the flag -DU_USING_ICU_NAMESPACE=0, then you'll get compile
errors like these:
common.h:138: error: 'UnicodeString' was not declared in this scope
> Can you explain what you mean by 'additional namespace declarations' ?
I was referring to U_NAMESPACE_QUALIFIER being added in front of
UnicodeString in unistr.h in ICU 3.8, but thanks to your question I
took a closer look at it and realized that that wasn't the real source
of my problem, but instead that I was using the
-DU_USING_ICU_NAMESPACE=0 flag (which probably is a rarely tested use
case).
--
Fredrik Roubert
roubert at google.com
More information about the pyicu-dev
mailing list