zinnia-fixes-gcc6-compile.patch 753 B

1234567891011121314151617181920212223
  1. Index: zinnia-0.06/trainer.cpp
  2. ===================================================================
  3. --- zinnia-0.06.orig/trainer.cpp
  4. +++ zinnia-0.06/trainer.cpp
  5. @@ -93,7 +93,7 @@ class TrainerImpl: public Trainer {
  6. public:
  7. bool add(const Character &character) {
  8. - const std::string y = character.value();
  9. + std::string y = character.value();
  10. CHECK_FALSE(!y.empty()) << "input character is empty";
  11. Features features;
  12. CHECK_FALSE(features.read(character)) << "cannot read character: " << y;
  13. @@ -103,7 +103,7 @@ class TrainerImpl: public Trainer {
  14. if (!fn) {
  15. return false;
  16. }
  17. - x_.push_back(std::make_pair<std::string, FeatureNode *>(y, fn));
  18. + x_.push_back(std::make_pair(y, fn));
  19. return true;
  20. }