diff --git a/test/aggr_tuple_assignment.cpp b/test/aggr_tuple_assignment.cpp index 4a01ff90..4209a0cf 100644 --- a/test/aggr_tuple_assignment.cpp +++ b/test/aggr_tuple_assignment.cpp @@ -50,8 +50,8 @@ struct string_int_double_priv std::string s; private: - int i; - double d; + [[maybe_unused]] int i; + [[maybe_unused]] double d; }; struct string_int_double_no_copy_move @@ -62,8 +62,8 @@ struct string_int_double_no_copy_move private: std::string s; - int i; - double d; + [[maybe_unused]] int i; + [[maybe_unused]] double d; }; struct employee diff --git a/test/github_issues.cpp b/test/github_issues.cpp index 917a8621..e8f7ea30 100644 --- a/test/github_issues.cpp +++ b/test/github_issues.cpp @@ -182,7 +182,7 @@ void github_issue_78() namespace issue_90 { namespace parser { const auto string = - '"' >> boost::parser::lexeme[*(boost::parser::char_ - '"')] > '"'; + ('"' >> boost::parser::lexeme[*(boost::parser::char_ - '"')]) > '"'; const auto specifier = string > ':' > string; }} diff --git a/test/parser.cpp b/test/parser.cpp index 6450e7d4..4d8616fe 100644 --- a/test/parser.cpp +++ b/test/parser.cpp @@ -2842,10 +2842,10 @@ int main() }; namespace bp = boost::parser; - std::variant kv_or_d; key_value kv; bp::parse("42 13.0", bp::int_ >> bp::double_, kv); // Ok. #if 0 + std::variant kv_or_d; bp::parse("42 13.0", bp::int_ >> bp::double_, kv_or_d); // Error: ill-formed! #endif } diff --git a/test/parser_rule.cpp b/test/parser_rule.cpp index e9c15fab..974be19b 100644 --- a/test/parser_rule.cpp +++ b/test/parser_rule.cpp @@ -124,7 +124,7 @@ namespace more_about_rules_3 { bp::rule parens = "matched parentheses"; - auto const parens_def = ('(' >> parens > ')') | bp::eps; + auto const parens_def = (('(' >> parens) > ')') | bp::eps; BOOST_PARSER_DEFINE_RULES(parens); } @@ -134,7 +134,7 @@ namespace more_about_rules_4 { bp::rule parens = "matched parentheses"; - auto const parens_def = ('(' >> parens > ')') | bp::eps; + auto const parens_def = (('(' >> parens) > ')') | bp::eps; BOOST_PARSER_DEFINE_RULES(parens);