summaryrefslogtreecommitdiff
path: root/decoder/hg_intersect.cc
diff options
context:
space:
mode:
authorChris Dyer <cdyer@Chriss-MacBook-Air.local>2013-11-10 00:58:44 -0500
committerChris Dyer <cdyer@Chriss-MacBook-Air.local>2013-11-10 00:58:44 -0500
commitd9cc1a6986188a97e09e4c8cef46c34eee5f9cd2 (patch)
tree662e45620fcf5b27f6a6edb5a5c105a0514e51cd /decoder/hg_intersect.cc
parentdb0dcd780abea416cfdb2b2382152dbe11c35170 (diff)
guard against direct includes of tr1
Diffstat (limited to 'decoder/hg_intersect.cc')
-rw-r--r--decoder/hg_intersect.cc8
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 {