summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2018-05-01 20:07:12 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2018-05-01 20:07:12 +0100
commit0cf0999fba82b94d8a68d6446db57ce045c74e14 (patch)
tree1e47e0fe744384ce769101b31e2a3d1e6a3a0fb6
parentRemove unused lexer pattern (diff)
downloadlibjsonpp-0cf0999fba82b94d8a68d6446db57ce045c74e14.tar.bz2
libjsonpp-0cf0999fba82b94d8a68d6446db57ce045c74e14.tar.xz
libjsonpp-0cf0999fba82b94d8a68d6446db57ce045c74e14.zip
Lexical cast is overkill, we're already pattern matched
-rw-r--r--libjsonpp/json.ll3
1 files changed, 1 insertions, 2 deletions
diff --git a/libjsonpp/json.ll b/libjsonpp/json.ll
index d7be30e..8fce090 100644
--- a/libjsonpp/json.ll
+++ b/libjsonpp/json.ll
@@ -9,7 +9,6 @@
%{
#include "jsonFlexLexer.h"
-#include <boost/lexical_cast.hpp>
#pragma GCC diagnostic ignored "-Wsign-compare"
%}
@@ -50,7 +49,7 @@ escape "\\"
}
<ARRAY_ITEM,VALUE>{number} {
- PushNumber(boost::lexical_cast<double>(YYText()));
+ PushNumber(std::strtod(YYText(), NULL));
yy_pop_state();
}