1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-23 04:23:08 +00:00

Fix build with clang 6

trainer.cpp:106:18: error: no matching function for call to 'make_pair'
    x_.push_back(std::make_pair<std::string, FeatureNode *>(y, fn));
                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

PR:		224669
Reported by:	pkg-fallout
This commit is contained in:
Antoine Brodin 2018-01-21 10:08:40 +00:00
parent 70d8dc7bc2
commit e3d058fb6b
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=459583

View File

@ -0,0 +1,20 @@
--- trainer.cpp.orig 2010-05-09 05:34:08 UTC
+++ trainer.cpp
@@ -93,7 +93,7 @@ class TrainerImpl: public Trainer {
public:
bool add(const Character &character) {
- const std::string y = character.value();
+ std::string y = character.value();
CHECK_FALSE(!y.empty()) << "input character is empty";
Features features;
CHECK_FALSE(features.read(character)) << "cannot read character: " << y;
@@ -103,7 +103,7 @@ class TrainerImpl: public Trainer {
if (!fn) {
return false;
}
- x_.push_back(std::make_pair<std::string, FeatureNode *>(y, fn));
+ x_.push_back(std::make_pair(y, fn));
return true;
}