[Libreoffice] [PUSHED] Re: [PATCH] Include header file
Caolán McNamara
caolanm at redhat.com
Sat Oct 30 14:14:23 PDT 2010
On Sat, 2010-10-30 at 21:04 +0300, Jani Monoses wrote:
> Just like the other .cxx files in starmath, make this one include
> unomodel.hxx and get the definition of the A2OU macro from there
> instead of redefining it.
Doesn't hurt, so pushed, thanks.
Looking at the A2OU define I see that it's just
rtl::OUString::createFromAscii, so anyplace where A2OU is being used
with a string literal is also replaceable with the slightly faster
version, e.g.
foo = A2OU("string literal);
->
foo = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("string literal));
rtl::OUString aThing(A2OU("foo"));
->
rtl::OUString aThing(RTL_CONSTASCII_USTRINGPARAM("foo"));
with the same logic that foo = A2OU(pFoo); is not guaranteed replaceable
with the RTL_CONSTASCII_USTRINGPARAM macro.
C.
More information about the LibreOffice
mailing list