Skip to content

Commit 296a836

Browse files
committed
Fix compiler warnings [-Wunused-const-variable]
clang warnings: src/classify/trainingsampleset.cpp:39:11: warning: unused variable 'kMinOutlierSamples' [-Wunused-const-variable] src/lstm/lstmrecognizer.cpp:45:11: warning: unused variable 'kMaxChoices' [-Wunused-const-variable] src/training/dawg2wordlist.cpp:28:11: warning: unused variable 'kDictDebugLevel' [-Wunused-const-variable] src/training/stringrenderer.cpp:50:21: warning: unused variable 'kWordJoiner' [-Wunused-const-variable] Signed-off-by: Stefan Weil <[email protected]>
1 parent d27f5b5 commit 296a836

File tree

4 files changed

+0
-7
lines changed

4 files changed

+0
-7
lines changed

src/classify/trainingsampleset.cpp

-2
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,6 @@ const int kSquareLimit = 25;
3535
// Prime numbers for subsampling distances.
3636
const int kPrime1 = 17;
3737
const int kPrime2 = 13;
38-
// Min samples from which to start discarding outliers.
39-
const int kMinOutlierSamples = 5;
4038

4139
TrainingSampleSet::FontClassInfo::FontClassInfo()
4240
: num_raw_samples(0), canonical_sample(-1), canonical_dist(0.0f) {

src/lstm/lstmrecognizer.cpp

-2
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,6 @@
4141

4242
namespace tesseract {
4343

44-
// Max number of blob choices to return in any given position.
45-
const int kMaxChoices = 4;
4644
// Default ratio between dict and non-dict words.
4745
const double kDictRatio = 2.25;
4846
// Default certainty offset to give the dictionary a chance.

src/training/dawg2wordlist.cpp

-2
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@
2525
#include "trie.h"
2626
#include "unicharset.h"
2727

28-
const int kDictDebugLevel = 1;
29-
3028
tesseract::Dawg *LoadSquishedDawg(const UNICHARSET &unicharset,
3129
const char *filename) {
3230
const int kDictDebugLevel = 1;

src/training/stringrenderer.cpp

-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ static const int kDefaultOutputResolution = 300;
4747
// recommendation in http://unicode.org/reports/tr14/ to avoid line-breaks at
4848
// hyphens and other non-alpha characters.
4949
static const char* kWordJoinerUTF8 = "\u2060";
50-
static const char32 kWordJoiner = 0x2060;
5150

5251
static bool IsCombiner(int ch) {
5352
const int char_type = u_charType(ch);

0 commit comments

Comments
 (0)