include/sal/types.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
New commits: commit 499141ecf2c3a0ece03e0c4ad01f4575c92869c8 Author: Stephan Bergmann <[email protected]> AuthorDate: Wed Jul 17 16:26:31 2024 +0200 Commit: Stephan Bergmann <[email protected]> CommitDate: Wed Jul 17 21:39:22 2024 +0200 Restrict SAL_RET_MAYBENULL to LIBO_INTERNAL_ONLY ...at least for now, as long as it is not needed in any published UNO include files Change-Id: I25a1697e1b9ffa5afce0e29cc64be66bf2ebbc57 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170637 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <[email protected]> diff --git a/include/sal/types.h b/include/sal/types.h index 78f5f4639592..b02b26f3361d 100644 --- a/include/sal/types.h +++ b/include/sal/types.h @@ -288,6 +288,7 @@ typedef void * sal_Handle; # define SAL_WARN_UNUSED_RESULT #endif +#if defined LIBO_INTERNAL_ONLY /** Use this as markup for functions and methods whose return value may be null and should not be dereferenced unconditionally. @@ -299,7 +300,7 @@ typedef void * sal_Handle; #else # define SAL_RET_MAYBENULL #endif - +#endif /** Use this for pure virtual classes, e.g. class SAL_NO_VTABLE Foo { ... This hinders the compiler from setting a generic vtable stating that
