From 8575c0dacef68253329608650b25412e6db7ca78 Mon Sep 17 00:00:00 2001 From: Peter Edberg Date: Wed, 16 Mar 2022 01:41:48 -0700 Subject: [PATCH] ICU-21900 check non-stable API macros, move class boilerplate out of conditionals --- icu4c/source/i18n/unicode/numberformatter.h | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/icu4c/source/i18n/unicode/numberformatter.h b/icu4c/source/i18n/unicode/numberformatter.h index a345a00d4ee..711064ece8d 100644 --- a/icu4c/source/i18n/unicode/numberformatter.h +++ b/icu4c/source/i18n/unicode/numberformatter.h @@ -1202,31 +1202,32 @@ class U_I18N_API Scale : public UMemory { namespace impl { -// Do not enclose entire StringProp with #ifndef U_HIDE_INTERNAL_API, needed for a protected field +// Do not enclose entire StringProp with #ifndef U_HIDE_INTERNAL_API, needed for a protected field. +// And do not enclose its class boilerplate within #ifndef U_HIDE_INTERNAL_API. /** * Manages NumberFormatterSettings::usage()'s char* instance on the heap. * @internal */ class U_I18N_API StringProp : public UMemory { -#ifndef U_HIDE_INTERNAL_API - public: + /** @internal */ + ~StringProp(); + /** @internal */ StringProp(const StringProp &other); /** @internal */ StringProp &operator=(const StringProp &other); +#ifndef U_HIDE_INTERNAL_API + /** @internal */ StringProp(StringProp &&src) U_NOEXCEPT; /** @internal */ StringProp &operator=(StringProp &&src) U_NOEXCEPT; - /** @internal */ - ~StringProp(); - /** @internal */ int16_t length() const { return fLength;