src/training/unicharset/validate_grapheme.cpp
bool ValidateGrapheme::IsBadlyFormed(char32 prev_ch, char32 ch) {
  // Reject badly formed Indic vowels.
  if (IsBadlyFormedIndicVowel(prev_ch, ch)) {
    if (report_errors_) {
      tprintf("Badly formed Indic vowel sequence:0x%x 0x%x\n", prev_ch, ch);
    }
    return true;
  }
  if (IsBadlyFormedThai(prev_ch, ch)) {
    if (report_errors_) {
      tprintf("Badly formed Thai:0x%x 0x%x\n", prev_ch, ch);
    }
    return true;
  }
  return false;
}
// Helper returns true if the sequence prev_ch,ch is invalid.
Helper returns true if the sequence prev_ch,ch is invalid.
Helper returns true if the sequence prev_ch ch is invalid .
bool ValidateGrapheme::IsBadlyFormed(char32 prev_ch, char32 ch) {
  if (IsBadlyFormedIndicVowel(prev_ch, ch)) {
    if (report_errors_) {
      tprintf("Badly formed Indic vowel sequence:0x%x 0x%x\n", prev_ch, ch);
    }
    return true;
  }
  if (IsBadlyFormedThai(prev_ch, ch)) {
    if (report_errors_) {
      tprintf("Badly formed Thai:0x%x 0x%x\n", prev_ch, ch);
    }
    return true;
  }
  return false;
}
bool ValidateGrapheme :: IsBadlyFormed ( char32 prev_ch , char32 ch ) { if ( IsBadlyFormedIndicVowel ( prev_ch , ch ) ) { if ( report_errors_ ) { tprintf ( " \n " , prev_ch , ch ) ; } return true ; } if ( IsBadlyFormedThai ( prev_ch , ch ) ) { if ( report_errors_ ) { tprintf ( " \n " , prev_ch , ch ) ; } return true ; } return false ; }
Helper returns true if the sequence prev_ch,ch is invalid.
Helper returns true if the sequence prev_ch ch is invalid .
// Reject badly formed Indic vowels.