diff options
author | Chris Dyer <cdyer@Chriss-MacBook-Air.local> | 2013-11-10 00:58:44 -0500 |
---|---|---|
committer | Chris Dyer <cdyer@Chriss-MacBook-Air.local> | 2013-11-10 00:58:44 -0500 |
commit | 2d3948b98bb9e8c7bad60f1acd99ff0b42b3ae30 (patch) | |
tree | 22cd235bd6c94ee25c1ab9b2cf2a2d1d9aaec5c5 /decoder/hg_intersect.cc | |
parent | 074fa88375967adababc632ea763e9dea389831e (diff) |
guard against direct includes of tr1
Diffstat (limited to 'decoder/hg_intersect.cc')
-rw-r--r-- | decoder/hg_intersect.cc | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/decoder/hg_intersect.cc b/decoder/hg_intersect.cc index ad5b701a..c5f1cc91 100644 --- a/decoder/hg_intersect.cc +++ b/decoder/hg_intersect.cc @@ -1,7 +1,12 @@ #include "hg_intersect.h" #include <vector> -#include <tr1/unordered_map> +#ifdef HAVE_CXX11 +# include <unordered_map> +#else +# include <tr1/unordered_map> +namespace std { using std::tr1::unordered_map; } +#endif #include "fast_lexical_cast.hpp" #include <boost/functional/hash.hpp> @@ -13,7 +18,6 @@ #include "bottom_up_parser.h" using boost::lexical_cast; -using namespace std::tr1; using namespace std; struct RuleFilter { |