SAL_UNUSED_PARAMETER (expanding to __attribute__ ((unused)) for GCC)
is used to annotate legitimately unused parameters, so that static
analysis tools can tell legitimately unused parameters from truly
unnecessary ones. To that end, some patches for external modules
are also added, that are only applied when compiling with GCC and
add necessary __attribute__ ((unused)) in headers.
On gcc-4.4.3, it fixes this error : l10ntools/source/helpex.cxx:82: error: parameter may not have variably modified type 'rtl::OString [(((long unsigned int)(((long int)i) + -0x00000000000000001)) + 1)]'
Hello lo-devs,
this patch series removes a lot of unnecessary includes for the various
tools header. The patches without suffix should be applied to the core
repository, the .binfilter.patch suffix should be applied to the
binfilter repository. I've tested the build with the configuration
--enable-binfilter --enable-dbgutil --enable-debug, is this sufficient
or did I miss another important configuration, that enables some
conditional compiled code? I've only build this on linux-x86_64, but the
patch also touches some of the mac specific code like
fpicker/source/aqua/SalAquaFilePicker.mm so it would be maybe a good
idea to test this patch.
regards Marcel Metz
WriteLine just writes a line of text, WriteByteString writes
a 16bit length of following content. It can't make sense to
suddenly stick a pascal-style string in at the end of a file
that's otherwise plain text.
original git id that introduced the use of WriteByteString here
was ea76474a back in 2002
Perhaps this worked because partial strings never ended up
as trailing content, so only ever had an empty string as
the final partial string, so a 0x0000 got appended, as
opposed to a newline, so it appeared to do the right thing.