...which has the necessary features to support it.
Change a lot of classes to either contain a protected non-virtual dtor
(which is backwards compatible, so even works for cppumaker-generated
UNO headers) or a public virtual one.
cppuhelper/propertysetmixin.hxx still needs to disable the warning, as
the relevant class has a non-virtual dtor but friends, which would still
cause GCC to warn.
Includes a patch for libcmis, intended to be upstreamed.
Since OString already has a ctor accepting const char*, I cannot
find out a way to distinguish string literals other than using
a template, otherwise const char* somehow takes precedence
(all of gcc, clang, msvc). But the template requires
the Substitution Is Not A Failure Idiom to actually create
only wanted instances. And the compiler can try evaluate
the OString ctor as a possibility when comparing an int to
an anonymous enum, and anonymous enum as a type without linkage
cannot be a template argument before C++11. SFINAE should still
work, but not with gcc older than 4.0.2 (which we right now
use only on macs). So for that case disable the string literal
ctors, which means macs will have one extra strlen call,
and also that embedded \0's in string literals will be
inconsistent. The tiny performance problem shouldn't matter that
much and will eventually go away, the \0 problem should not
matter, since before string literal ctors were introduced
\0's had not been included anyway unless RTL_CONSTASCII_STRINGPARAM
was used. So we should be safe and when removing the CONSTASCII
macros \0 cases should be handled by explicitly mentioning
the length.
On Linux, public templates should not be hidden at the linker level.
But on Windows, dllimport causes trouble. So create a new macro
to be used specifically with templates that does the right thing
on both platforms.
(http://lists.freedesktop.org/archives/libreoffice/2012-March/028041.html
and followups)
match() has matchIgnoreAsciiCase(), so it makes sense that endsWith()
also has the IgnoreAsciiCase variant, especially given there already is
endsWithIgnoreAsciiCaseAsciiL()
This is to prevent things like by mistake doing match( RTL_CONSTASCII_STRINGPARAM("foo")),
which will call match(const char(&)[N], int=0), where the second argument is the fromIndex
argument.
Drop the recently introduced rtl_uString_newFromAscii_WithLength()
and replace it with this one. The name fits better and it'll be also
a distinct function that specifically includes embedded \0's
(because that's what OUString supports and if a string literal
explicitly includes it, it makes sense to copy it as such).
...instead of arbitrarily returning certain values when the requested
information is not available.
This reveals a problem in strmunx.cxx that is apparently a regression introduced
with 4a086fca7b "fix SvStream to not require a
custom open or lstat method."
...as the Thread may already have been destroyed by that time.
Also, no need to programmatically check fro programming errors when they
have already been addressed by assert.
For iOS cppunit plugins aren't really "plugins" (shared libraries),
but just static archives. In the real main program of a cppunit app
(such are not yet written), which calls the lo_main() (the
SAL_IMPLEMENT_MAIN() in cppunittester.cxx) we specifically will call
the initialize methods of the CppUnitTestPlugIns that we statically
link to the app executable. Hopefully that will work out as expected.
Let's do the iOS specific stuff in separate main() source
file(s). Don't attempt to build complete iOS programs using normal
LibreOffice mechanisms, it will work for only the very lowest level
unit tests anyway, because of static linking and the circularish
UNO/URE/bootstrap/whatnot (run-time) dependencies between different
parts of the code.
We thus can't build the various iOS-specific *_cppunittester_all unit
test executables any more. Corresponding unit tests (and more complex
ones) for iOS will have to be done in a different way.