diff --git a/icu4c/source/common/filteredbrk.cpp b/icu4c/source/common/filteredbrk.cpp index 249da43f411..5a8f0b0873e 100644 --- a/icu4c/source/common/filteredbrk.cpp +++ b/icu4c/source/common/filteredbrk.cpp @@ -135,16 +135,19 @@ static const UChar kFULLSTOP = 0x002E; // '.' */ class SimpleFilteredSentenceBreakData : public UMemory { public: + SimpleFilteredSentenceBreakData(UCharsTrie *forwards, UCharsTrie *backwards ) + : fForwardsPartialTrie(forwards), fBackwardsTrie(backwards), refcount(1) { } + SimpleFilteredSentenceBreakData *incr() { refcount++; return this; } + SimpleFilteredSentenceBreakData *decr() { if((--refcount) <= 0) delete this; return 0; } + virtual ~SimpleFilteredSentenceBreakData(); + LocalPointer fForwardsPartialTrie; // Has ".a" for "a.M." LocalPointer fBackwardsTrie; // i.e. ".srM" for Mrs. int32_t refcount; - SimpleFilteredSentenceBreakData(UCharsTrie *forwards, UCharsTrie *backwards ) - : fForwardsPartialTrie(forwards), fBackwardsTrie(backwards), refcount(1) { } - virtual ~SimpleFilteredSentenceBreakData() {} - SimpleFilteredSentenceBreakData *incr() { refcount++; return this; } - SimpleFilteredSentenceBreakData *decr() { if((--refcount) <= 0) delete this; return 0; } }; +SimpleFilteredSentenceBreakData::~SimpleFilteredSentenceBreakData() {} + /** * Concrete implementation */ diff --git a/icu4c/source/i18n/csrsbcs.cpp b/icu4c/source/i18n/csrsbcs.cpp index f969c271c5d..d346af20bb7 100644 --- a/icu4c/source/i18n/csrsbcs.cpp +++ b/icu4c/source/i18n/csrsbcs.cpp @@ -167,6 +167,7 @@ NGramParser_IBM420::NGramParser_IBM420(const int32_t *theNgramList, const uint8_ alef = 0x00; } +NGramParser_IBM420::~NGramParser_IBM420() {} int32_t NGramParser_IBM420::isLamAlef(int32_t b) { diff --git a/icu4c/source/i18n/csrsbcs.h b/icu4c/source/i18n/csrsbcs.h index 935a3e7e289..046da679f52 100644 --- a/icu4c/source/i18n/csrsbcs.h +++ b/icu4c/source/i18n/csrsbcs.h @@ -54,14 +54,15 @@ public: #if !UCONFIG_ONLY_HTML_CONVERSION class NGramParser_IBM420 : public NGramParser { -private: - int32_t alef; - int32_t isLamAlef(int32_t b); - int32_t nextByte(InputText *det); - void parseCharacters(InputText *det); - public: NGramParser_IBM420(const int32_t *theNgramList, const uint8_t *theCharMap); + ~NGramParser_IBM420(); + +private: + int32_t alef; + int32_t isLamAlef(int32_t b); + int32_t nextByte(InputText *det); + void parseCharacters(InputText *det); }; #endif diff --git a/icu4c/source/i18n/valueformatter.cpp b/icu4c/source/i18n/valueformatter.cpp index 71ade13eb8f..d7870d1041d 100644 --- a/icu4c/source/i18n/valueformatter.cpp +++ b/icu4c/source/i18n/valueformatter.cpp @@ -24,6 +24,8 @@ U_NAMESPACE_BEGIN +ValueFormatter::~ValueFormatter() {} + VisibleDigitsWithExponent & ValueFormatter::toVisibleDigitsWithExponent( int64_t value, diff --git a/icu4c/source/i18n/valueformatter.h b/icu4c/source/i18n/valueformatter.h index 4370876730f..e985edd390e 100644 --- a/icu4c/source/i18n/valueformatter.h +++ b/icu4c/source/i18n/valueformatter.h @@ -45,6 +45,8 @@ public: ValueFormatter() : fType(kFormatTypeCount) { } + virtual ~ValueFormatter(); + /** * This function is here only to support the protected round() method * in DecimalFormat. It serves no ther purpose than that.