ICU-11917 virtual destructors must be defined explicitly, out-of-line, first virtual method

X-SVN-Rev: 37993
This commit is contained in:
Markus Scherer 2015-09-22 21:51:03 +00:00
parent 79d8e92f14
commit 9d080ee08a
5 changed files with 20 additions and 11 deletions

View file

@ -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<UCharsTrie> fForwardsPartialTrie; // Has ".a" for "a.M."
LocalPointer<UCharsTrie> 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
*/

View file

@ -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)
{

View file

@ -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

View file

@ -24,6 +24,8 @@
U_NAMESPACE_BEGIN
ValueFormatter::~ValueFormatter() {}
VisibleDigitsWithExponent &
ValueFormatter::toVisibleDigitsWithExponent(
int64_t value,

View file

@ -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.