diff options
Diffstat (limited to 'sal/rtl/source/strimp.hxx')
-rw-r--r-- | sal/rtl/source/strimp.hxx | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/sal/rtl/source/strimp.hxx b/sal/rtl/source/strimp.hxx index a9e5a38f6da7..82f7f41fee74 100644 --- a/sal/rtl/source/strimp.hxx +++ b/sal/rtl/source/strimp.hxx @@ -54,6 +54,24 @@ sal_Int16 rtl_ImplGetDigit( sal_Unicode ch, sal_Int16 nRadix ); sal_Bool rtl_ImplIsWhitespace( sal_Unicode c ); +// string lifetime instrumentation / diagnostics +#if 0 +# include <rtl/ustring.hxx> +# define RTL_LOG_STRING_NEW(s) \ + do { \ + fprintf (stderr, "+%s\n", \ + rtl::OUStringToOString(s, RTL_TEXTENCODING_UTF8).getStr()); \ + } while (0) +# define RTL_LOG_STRING_DELETE(s) \ + do { \ + fprintf (stderr, "-%s\n", \ + rtl::OUStringToOString(s, RTL_TEXTENCODING_UTF8).getStr()); \ + } while (0) +#else +# define RTL_LOG_STRING_NEW(s) +# define RTL_LOG_STRING_DELETE(s) +#endif + #endif /* INCLUDED_RTL_SOURCE_STRIMP_HXX */ /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |