From d9cc1a6986188a97e09e4c8cef46c34eee5f9cd2 Mon Sep 17 00:00:00 2001 From: Chris Dyer Date: Sun, 10 Nov 2013 00:58:44 -0500 Subject: guard against direct includes of tr1 --- decoder/ff_wordalign.h | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'decoder/ff_wordalign.h') diff --git a/decoder/ff_wordalign.h b/decoder/ff_wordalign.h index ba3d0b9b..50f0dafa 100644 --- a/decoder/ff_wordalign.h +++ b/decoder/ff_wordalign.h @@ -5,8 +5,16 @@ #include "array2d.h" #include "factored_lexicon_helper.h" +#include +#include #include #include +#ifdef HAVE_CXX11 +# include +#else +# include +namespace std { using std::tr1::unordered_map; } +#endif class RelativeSentencePosition : public FeatureFunction { public: @@ -124,9 +132,6 @@ class LexicalTranslationTrigger : public FeatureFunction { std::vector > triggers_; }; -#include -#include -#include class BlunsomSynchronousParseHack : public FeatureFunction { public: BlunsomSynchronousParseHack(const std::string& param); @@ -196,7 +201,7 @@ class BlunsomSynchronousParseHack : public FeatureFunction { const int fid_; mutable int cur_sent_; - typedef std::tr1::unordered_map, int, boost::hash > > Vec2Int; + typedef std::unordered_map, int, boost::hash > > Vec2Int; mutable Vec2Int cur_map_; const std::vector mutable * cur_ref_; mutable std::vector > refs_; -- cgit v1.2.3