diff options
Diffstat (limited to 'host/lib/rfnoc/nocscript')
-rw-r--r-- | host/lib/rfnoc/nocscript/expression.cpp | 2 | ||||
-rw-r--r-- | host/lib/rfnoc/nocscript/parser.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/host/lib/rfnoc/nocscript/expression.cpp b/host/lib/rfnoc/nocscript/expression.cpp index 32065bda1..5e03485be 100644 --- a/host/lib/rfnoc/nocscript/expression.cpp +++ b/host/lib/rfnoc/nocscript/expression.cpp @@ -49,7 +49,7 @@ expression_literal::expression_literal( _bool_val = true; } else { // lexical cast to bool is too picky - _bool_val = bool(std::stoi(_val)); + _bool_val = (std::stoi(_val) != 0); } break; diff --git a/host/lib/rfnoc/nocscript/parser.cpp b/host/lib/rfnoc/nocscript/parser.cpp index 51a544e47..8ef1b7f44 100644 --- a/host/lib/rfnoc/nocscript/parser.cpp +++ b/host/lib/rfnoc/nocscript/parser.cpp @@ -163,7 +163,7 @@ private: P.expr_stack.top()->set_combiner_safe( expression_container::COMBINE_OR); } - } catch (const uhd::syntax_error& e) { + } catch (const uhd::syntax_error&) { P.error = str(boost::format("Operator %s is mixing operator " "types within this container.") % val); |