aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorYizhe <yizhe@pku.edu.cn>2021-02-26 08:56:17 +0000
committerPhilip Herron <herron.philip@googlemail.com>2021-03-01 10:42:27 +0000
commit4ebeb3165cfdaa1b95ed39779760b634974a80e5 (patch)
treed01fc3707cd3ee6ce777afc29fe07949a50e6afe /gcc
parent875bda0637f587ded1a4e8bfab1703b54eee2b2e (diff)
downloadgcc-4ebeb3165cfdaa1b95ed39779760b634974a80e5.zip
gcc-4ebeb3165cfdaa1b95ed39779760b634974a80e5.tar.gz
gcc-4ebeb3165cfdaa1b95ed39779760b634974a80e5.tar.bz2
Modify the parser to use the new enums
Diffstat (limited to 'gcc')
-rw-r--r--gcc/rust/parse/rust-parse-impl.h164
1 files changed, 82 insertions, 82 deletions
diff --git a/gcc/rust/parse/rust-parse-impl.h b/gcc/rust/parse/rust-parse-impl.h
index 9ae1a7d..0125649 100644
--- a/gcc/rust/parse/rust-parse-impl.h
+++ b/gcc/rust/parse/rust-parse-impl.h
@@ -12271,7 +12271,7 @@ Parser<ManagedTokenSource>::null_denotation (
/* FIXME: allow outer attributes on these expressions by having an outer
* attrs parameter in function*/
return std::unique_ptr<AST::NegationExpr> (
- new AST::NegationExpr (std::move (expr), AST::NegationExpr::NEGATE,
+ new AST::NegationExpr (std::move (expr), NegationOperator::NEGATE,
std::move (outer_attrs), tok->get_locus ()));
}
case EXCLAM: { // logical or bitwise not
@@ -12294,7 +12294,7 @@ Parser<ManagedTokenSource>::null_denotation (
// FIXME: allow outer attributes on these expressions
return std::unique_ptr<AST::NegationExpr> (
- new AST::NegationExpr (std::move (expr), AST::NegationExpr::NOT,
+ new AST::NegationExpr (std::move (expr), NegationOperator::NOT,
std::move (outer_attrs), tok->get_locus ()));
}
case ASTERISK: {
@@ -12530,77 +12530,77 @@ Parser<ManagedTokenSource>::left_denotation (
std::move (outer_attrs), restrictions);*/
return parse_arithmetic_or_logical_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ArithmeticOrLogicalExpr::ADD, restrictions);
+ ArithmeticOrLogicalOperator::ADD, restrictions);
case MINUS:
// difference expression - binary infix
/*return parse_binary_minus_expr (tok, std::move (left),
std::move (outer_attrs), restrictions);*/
return parse_arithmetic_or_logical_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ArithmeticOrLogicalExpr::SUBTRACT, restrictions);
+ ArithmeticOrLogicalOperator::SUBTRACT, restrictions);
case ASTERISK:
// product expression - binary infix
/*return parse_binary_mult_expr (tok, std::move (left),
std::move (outer_attrs), restrictions);*/
return parse_arithmetic_or_logical_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ArithmeticOrLogicalExpr::MULTIPLY, restrictions);
+ ArithmeticOrLogicalOperator::MULTIPLY, restrictions);
case DIV:
// quotient expression - binary infix
/*return parse_binary_div_expr (tok, std::move (left),
std::move (outer_attrs), restrictions);*/
return parse_arithmetic_or_logical_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ArithmeticOrLogicalExpr::DIVIDE, restrictions);
+ ArithmeticOrLogicalOperator::DIVIDE, restrictions);
case PERCENT:
// modulo expression - binary infix
/*return parse_binary_mod_expr (tok, std::move (left),
std::move (outer_attrs), restrictions);*/
return parse_arithmetic_or_logical_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ArithmeticOrLogicalExpr::MODULUS, restrictions);
+ ArithmeticOrLogicalOperator::MODULUS, restrictions);
case AMP:
// logical or bitwise and expression - binary infix
/*return parse_bitwise_and_expr (tok, std::move (left),
std::move (outer_attrs), restrictions);*/
return parse_arithmetic_or_logical_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ArithmeticOrLogicalExpr::BITWISE_AND, restrictions);
+ ArithmeticOrLogicalOperator::BITWISE_AND, restrictions);
case PIPE:
// logical or bitwise or expression - binary infix
/*return parse_bitwise_or_expr (tok, std::move (left),
std::move (outer_attrs), restrictions);*/
return parse_arithmetic_or_logical_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ArithmeticOrLogicalExpr::BITWISE_OR, restrictions);
+ ArithmeticOrLogicalOperator::BITWISE_OR, restrictions);
case CARET:
// logical or bitwise xor expression - binary infix
/*return parse_bitwise_xor_expr (tok, std::move (left),
std::move (outer_attrs), restrictions);*/
return parse_arithmetic_or_logical_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ArithmeticOrLogicalExpr::BITWISE_XOR, restrictions);
+ ArithmeticOrLogicalOperator::BITWISE_XOR, restrictions);
case LEFT_SHIFT:
// left shift expression - binary infix
/*return parse_left_shift_expr (tok, std::move (left),
std::move (outer_attrs), restrictions);*/
return parse_arithmetic_or_logical_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ArithmeticOrLogicalExpr::LEFT_SHIFT, restrictions);
+ ArithmeticOrLogicalOperator::LEFT_SHIFT, restrictions);
case RIGHT_SHIFT:
// right shift expression - binary infix
/*return parse_right_shift_expr (tok, std::move (left),
std::move (outer_attrs), restrictions);*/
return parse_arithmetic_or_logical_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ArithmeticOrLogicalExpr::RIGHT_SHIFT, restrictions);
+ ArithmeticOrLogicalOperator::RIGHT_SHIFT, restrictions);
case EQUAL_EQUAL:
// equal to expression - binary infix (no associativity)
/*return parse_binary_equal_expr (tok, std::move (left),
std::move (outer_attrs), restrictions);*/
return parse_comparison_expr (tok, std::move (left),
std::move (outer_attrs),
- AST::ComparisonExpr::ExprType::EQUAL,
+ ComparisonOperator::EQUAL,
restrictions);
case NOT_EQUAL:
// not equal to expression - binary infix (no associativity)
@@ -12609,7 +12609,7 @@ Parser<ManagedTokenSource>::left_denotation (
restrictions);*/
return parse_comparison_expr (tok, std::move (left),
std::move (outer_attrs),
- AST::ComparisonExpr::ExprType::NOT_EQUAL,
+ ComparisonOperator::NOT_EQUAL,
restrictions);
case RIGHT_ANGLE:
// greater than expression - binary infix (no associativity)
@@ -12618,7 +12618,7 @@ Parser<ManagedTokenSource>::left_denotation (
restrictions);*/
return parse_comparison_expr (tok, std::move (left),
std::move (outer_attrs),
- AST::ComparisonExpr::ExprType::GREATER_THAN,
+ ComparisonOperator::GREATER_THAN,
restrictions);
case LEFT_ANGLE:
// less than expression - binary infix (no associativity)
@@ -12627,7 +12627,7 @@ Parser<ManagedTokenSource>::left_denotation (
restrictions);*/
return parse_comparison_expr (tok, std::move (left),
std::move (outer_attrs),
- AST::ComparisonExpr::ExprType::LESS_THAN,
+ ComparisonOperator::LESS_THAN,
restrictions);
case GREATER_OR_EQUAL:
// greater than or equal to expression - binary infix (no associativity)
@@ -12636,7 +12636,7 @@ Parser<ManagedTokenSource>::left_denotation (
restrictions);*/
return parse_comparison_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ComparisonExpr::ExprType::GREATER_OR_EQUAL, restrictions);
+ ComparisonOperator::GREATER_OR_EQUAL, restrictions);
case LESS_OR_EQUAL:
// less than or equal to expression - binary infix (no associativity)
/*return parse_binary_less_equal_expr (tok, std::move (left),
@@ -12644,7 +12644,7 @@ Parser<ManagedTokenSource>::left_denotation (
restrictions);*/
return parse_comparison_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::ComparisonExpr::ExprType::LESS_OR_EQUAL, restrictions);
+ ComparisonOperator::LESS_OR_EQUAL, restrictions);
case OR:
// lazy logical or expression - binary infix
return parse_lazy_or_expr (tok, std::move (left), std::move (outer_attrs),
@@ -12669,7 +12669,7 @@ Parser<ManagedTokenSource>::left_denotation (
std::move (outer_attrs), restrictions);*/
return parse_compound_assignment_expr (tok, std::move (left),
std::move (outer_attrs),
- AST::CompoundAssignmentExpr::ADD,
+ CompoundAssignmentOperator::ADD,
restrictions);
case MINUS_EQ:
/* minus-assignment expression - binary infix (note right-to-left
@@ -12678,7 +12678,7 @@ Parser<ManagedTokenSource>::left_denotation (
std::move (outer_attrs), restrictions);*/
return parse_compound_assignment_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::CompoundAssignmentExpr::SUBTRACT, restrictions);
+ CompoundAssignmentOperator::SUBTRACT, restrictions);
case ASTERISK_EQ:
/* multiply-assignment expression - binary infix (note right-to-left
* associativity) */
@@ -12686,7 +12686,7 @@ Parser<ManagedTokenSource>::left_denotation (
std::move (outer_attrs), restrictions);*/
return parse_compound_assignment_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::CompoundAssignmentExpr::MULTIPLY, restrictions);
+ CompoundAssignmentOperator::MULTIPLY, restrictions);
case DIV_EQ:
/* division-assignment expression - binary infix (note right-to-left
* associativity) */
@@ -12694,7 +12694,7 @@ Parser<ManagedTokenSource>::left_denotation (
std::move (outer_attrs), restrictions);*/
return parse_compound_assignment_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::CompoundAssignmentExpr::DIVIDE, restrictions);
+ CompoundAssignmentOperator::DIVIDE, restrictions);
case PERCENT_EQ:
/* modulo-assignment expression - binary infix (note right-to-left
* associativity) */
@@ -12702,7 +12702,7 @@ Parser<ManagedTokenSource>::left_denotation (
std::move (outer_attrs), restrictions);*/
return parse_compound_assignment_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::CompoundAssignmentExpr::MODULUS, restrictions);
+ CompoundAssignmentOperator::MODULUS, restrictions);
case AMP_EQ:
/* bitwise and-assignment expression - binary infix (note right-to-left
* associativity) */
@@ -12710,7 +12710,7 @@ Parser<ManagedTokenSource>::left_denotation (
std::move (outer_attrs), restrictions);*/
return parse_compound_assignment_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::CompoundAssignmentExpr::BITWISE_AND, restrictions);
+ CompoundAssignmentOperator::BITWISE_AND, restrictions);
case PIPE_EQ:
/* bitwise or-assignment expression - binary infix (note right-to-left
* associativity) */
@@ -12718,7 +12718,7 @@ Parser<ManagedTokenSource>::left_denotation (
std::move (outer_attrs), restrictions);*/
return parse_compound_assignment_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::CompoundAssignmentExpr::BITWISE_OR, restrictions);
+ CompoundAssignmentOperator::BITWISE_OR, restrictions);
case CARET_EQ:
/* bitwise xor-assignment expression - binary infix (note right-to-left
* associativity) */
@@ -12726,7 +12726,7 @@ Parser<ManagedTokenSource>::left_denotation (
std::move (outer_attrs), restrictions);*/
return parse_compound_assignment_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::CompoundAssignmentExpr::BITWISE_XOR, restrictions);
+ CompoundAssignmentOperator::BITWISE_XOR, restrictions);
case LEFT_SHIFT_EQ:
/* left shift-assignment expression - binary infix (note right-to-left
* associativity) */
@@ -12735,7 +12735,7 @@ Parser<ManagedTokenSource>::left_denotation (
restrictions);*/
return parse_compound_assignment_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::CompoundAssignmentExpr::LEFT_SHIFT, restrictions);
+ CompoundAssignmentOperator::LEFT_SHIFT, restrictions);
case RIGHT_SHIFT_EQ:
/* right shift-assignment expression - binary infix (note right-to-left
* associativity) */
@@ -12744,7 +12744,7 @@ Parser<ManagedTokenSource>::left_denotation (
restrictions);*/
return parse_compound_assignment_expr (
tok, std::move (left), std::move (outer_attrs),
- AST::CompoundAssignmentExpr::RIGHT_SHIFT, restrictions);
+ CompoundAssignmentOperator::RIGHT_SHIFT, restrictions);
case DOT_DOT:
/* range exclusive expression - binary infix (no associativity)
* either "range" or "range from" */
@@ -12830,25 +12830,25 @@ get_lbp_for_arithmetic_or_logical_expr (
{
switch (expr_type)
{
- case AST::ArithmeticOrLogicalExpr::ADD:
+ case ArithmeticOrLogicalOperator::ADD:
return LBP_PLUS;
- case AST::ArithmeticOrLogicalExpr::SUBTRACT:
+ case ArithmeticOrLogicalOperator::SUBTRACT:
return LBP_MINUS;
- case AST::ArithmeticOrLogicalExpr::MULTIPLY:
+ case ArithmeticOrLogicalOperator::MULTIPLY:
return LBP_MUL;
- case AST::ArithmeticOrLogicalExpr::DIVIDE:
+ case ArithmeticOrLogicalOperator::DIVIDE:
return LBP_DIV;
- case AST::ArithmeticOrLogicalExpr::MODULUS:
+ case ArithmeticOrLogicalOperator::MODULUS:
return LBP_MOD;
- case AST::ArithmeticOrLogicalExpr::BITWISE_AND:
+ case ArithmeticOrLogicalOperator::BITWISE_AND:
return LBP_AMP;
- case AST::ArithmeticOrLogicalExpr::BITWISE_OR:
+ case ArithmeticOrLogicalOperator::BITWISE_OR:
return LBP_PIPE;
- case AST::ArithmeticOrLogicalExpr::BITWISE_XOR:
+ case ArithmeticOrLogicalOperator::BITWISE_XOR:
return LBP_CARET;
- case AST::ArithmeticOrLogicalExpr::LEFT_SHIFT:
+ case ArithmeticOrLogicalOperator::LEFT_SHIFT:
return LBP_L_SHIFT;
- case AST::ArithmeticOrLogicalExpr::RIGHT_SHIFT:
+ case ArithmeticOrLogicalOperator::RIGHT_SHIFT:
return LBP_R_SHIFT;
default:
// WTF? should not happen, this is an error
@@ -12901,7 +12901,7 @@ Parser<ManagedTokenSource>::parse_binary_plus_expr (
return std::unique_ptr<AST::ArithmeticOrLogicalExpr> (
new AST::ArithmeticOrLogicalExpr (std::move (left), std::move (right),
- AST::ArithmeticOrLogicalExpr::ADD,
+ ArithmeticOrLogicalOperator::ADD,
locus));
}
@@ -12924,7 +12924,7 @@ Parser<ManagedTokenSource>::parse_binary_minus_expr (
return std::unique_ptr<AST::ArithmeticOrLogicalExpr> (
new AST::ArithmeticOrLogicalExpr (std::move (left), std::move (right),
- AST::ArithmeticOrLogicalExpr::SUBTRACT,
+ ArithmeticOrLogicalOperator::SUBTRACT,
locus));
}
@@ -12947,7 +12947,7 @@ Parser<ManagedTokenSource>::parse_binary_mult_expr (
return std::unique_ptr<AST::ArithmeticOrLogicalExpr> (
new AST::ArithmeticOrLogicalExpr (std::move (left), std::move (right),
- AST::ArithmeticOrLogicalExpr::MULTIPLY,
+ ArithmeticOrLogicalOperator::MULTIPLY,
locus));
}
@@ -12970,7 +12970,7 @@ Parser<ManagedTokenSource>::parse_binary_div_expr (
return std::unique_ptr<AST::ArithmeticOrLogicalExpr> (
new AST::ArithmeticOrLogicalExpr (std::move (left), std::move (right),
- AST::ArithmeticOrLogicalExpr::DIVIDE,
+ ArithmeticOrLogicalOperator::DIVIDE,
locus));
}
@@ -12993,7 +12993,7 @@ Parser<ManagedTokenSource>::parse_binary_mod_expr (
return std::unique_ptr<AST::ArithmeticOrLogicalExpr> (
new AST::ArithmeticOrLogicalExpr (std::move (left), std::move (right),
- AST::ArithmeticOrLogicalExpr::MODULUS,
+ ArithmeticOrLogicalOperator::MODULUS,
locus));
}
@@ -13017,7 +13017,7 @@ Parser<ManagedTokenSource>::parse_bitwise_and_expr (
return std::unique_ptr<AST::ArithmeticOrLogicalExpr> (
new AST::ArithmeticOrLogicalExpr (std::move (left), std::move (right),
- AST::ArithmeticOrLogicalExpr::BITWISE_AND,
+ ArithmeticOrLogicalOperator::BITWISE_AND,
locus));
}
@@ -13041,7 +13041,7 @@ Parser<ManagedTokenSource>::parse_bitwise_or_expr (
return std::unique_ptr<AST::ArithmeticOrLogicalExpr> (
new AST::ArithmeticOrLogicalExpr (std::move (left), std::move (right),
- AST::ArithmeticOrLogicalExpr::BITWISE_OR,
+ ArithmeticOrLogicalOperator::BITWISE_OR,
locus));
}
@@ -13065,7 +13065,7 @@ Parser<ManagedTokenSource>::parse_bitwise_xor_expr (
return std::unique_ptr<AST::ArithmeticOrLogicalExpr> (
new AST::ArithmeticOrLogicalExpr (std::move (left), std::move (right),
- AST::ArithmeticOrLogicalExpr::BITWISE_XOR,
+ ArithmeticOrLogicalOperator::BITWISE_XOR,
locus));
}
@@ -13088,7 +13088,7 @@ Parser<ManagedTokenSource>::parse_left_shift_expr (
return std::unique_ptr<AST::ArithmeticOrLogicalExpr> (
new AST::ArithmeticOrLogicalExpr (std::move (left), std::move (right),
- AST::ArithmeticOrLogicalExpr::LEFT_SHIFT,
+ ArithmeticOrLogicalOperator::LEFT_SHIFT,
locus));
}
@@ -13111,7 +13111,7 @@ Parser<ManagedTokenSource>::parse_right_shift_expr (
return std::unique_ptr<AST::ArithmeticOrLogicalExpr> (
new AST::ArithmeticOrLogicalExpr (std::move (left), std::move (right),
- AST::ArithmeticOrLogicalExpr::RIGHT_SHIFT,
+ ArithmeticOrLogicalOperator::RIGHT_SHIFT,
locus));
}
@@ -13122,17 +13122,17 @@ get_lbp_for_comparison_expr (AST::ComparisonExpr::ExprType expr_type)
{
switch (expr_type)
{
- case AST::ComparisonExpr::EQUAL:
+ case ComparisonOperator::EQUAL:
return LBP_EQUAL;
- case AST::ComparisonExpr::NOT_EQUAL:
+ case ComparisonOperator::NOT_EQUAL:
return LBP_NOT_EQUAL;
- case AST::ComparisonExpr::GREATER_THAN:
+ case ComparisonOperator::GREATER_THAN:
return LBP_GREATER_THAN;
- case AST::ComparisonExpr::LESS_THAN:
+ case ComparisonOperator::LESS_THAN:
return LBP_SMALLER_THAN;
- case AST::ComparisonExpr::GREATER_OR_EQUAL:
+ case ComparisonOperator::GREATER_OR_EQUAL:
return LBP_GREATER_EQUAL;
- case AST::ComparisonExpr::LESS_OR_EQUAL:
+ case ComparisonOperator::LESS_OR_EQUAL:
return LBP_SMALLER_EQUAL;
default:
// WTF? should not happen, this is an error
@@ -13185,7 +13185,7 @@ Parser<ManagedTokenSource>::parse_binary_equal_expr (
return std::unique_ptr<AST::ComparisonExpr> (
new AST::ComparisonExpr (std::move (left), std::move (right),
- AST::ComparisonExpr::EQUAL, locus));
+ ComparisonOperator::EQUAL, locus));
}
// Parses a binary not equal to expression (with Pratt parsing).
@@ -13207,7 +13207,7 @@ Parser<ManagedTokenSource>::parse_binary_not_equal_expr (
return std::unique_ptr<AST::ComparisonExpr> (
new AST::ComparisonExpr (std::move (left), std::move (right),
- AST::ComparisonExpr::NOT_EQUAL, locus));
+ ComparisonOperator::NOT_EQUAL, locus));
}
// Parses a binary greater than expression (with Pratt parsing).
@@ -13230,7 +13230,7 @@ Parser<ManagedTokenSource>::parse_binary_greater_than_expr (
return std::unique_ptr<AST::ComparisonExpr> (
new AST::ComparisonExpr (std::move (left), std::move (right),
- AST::ComparisonExpr::GREATER_THAN, locus));
+ ComparisonOperator::GREATER_THAN, locus));
}
// Parses a binary less than expression (with Pratt parsing).
@@ -13253,7 +13253,7 @@ Parser<ManagedTokenSource>::parse_binary_less_than_expr (
return std::unique_ptr<AST::ComparisonExpr> (
new AST::ComparisonExpr (std::move (left), std::move (right),
- AST::ComparisonExpr::LESS_THAN, locus));
+ ComparisonOperator::LESS_THAN, locus));
}
// Parses a binary greater than or equal to expression (with Pratt parsing).
@@ -13276,7 +13276,7 @@ Parser<ManagedTokenSource>::parse_binary_greater_equal_expr (
return std::unique_ptr<AST::ComparisonExpr> (
new AST::ComparisonExpr (std::move (left), std::move (right),
- AST::ComparisonExpr::GREATER_OR_EQUAL, locus));
+ ComparisonOperator::GREATER_OR_EQUAL, locus));
}
// Parses a binary less than or equal to expression (with Pratt parsing).
@@ -13299,7 +13299,7 @@ Parser<ManagedTokenSource>::parse_binary_less_equal_expr (
return std::unique_ptr<AST::ComparisonExpr> (
new AST::ComparisonExpr (std::move (left), std::move (right),
- AST::ComparisonExpr::LESS_OR_EQUAL, locus));
+ ComparisonOperator::LESS_OR_EQUAL, locus));
}
// Parses a binary lazy boolean or expression (with Pratt parsing).
@@ -13321,7 +13321,7 @@ Parser<ManagedTokenSource>::parse_lazy_or_expr (
return std::unique_ptr<AST::LazyBooleanExpr> (
new AST::LazyBooleanExpr (std::move (left), std::move (right),
- AST::LazyBooleanExpr::LOGICAL_OR, locus));
+ LazyBooleanOperator::LOGICAL_OR, locus));
}
// Parses a binary lazy boolean and expression (with Pratt parsing).
@@ -13344,7 +13344,7 @@ Parser<ManagedTokenSource>::parse_lazy_and_expr (
return std::unique_ptr<AST::LazyBooleanExpr> (
new AST::LazyBooleanExpr (std::move (left), std::move (right),
- AST::LazyBooleanExpr::LOGICAL_AND, locus));
+ LazyBooleanOperator::LOGICAL_AND, locus));
}
// Parses a pseudo-binary infix type cast expression (with Pratt parsing).
@@ -13398,25 +13398,25 @@ get_lbp_for_compound_assignment_expr (
{
switch (expr_type)
{
- case AST::CompoundAssignmentExpr::ADD:
+ case CompoundAssignmentOperator::ADD:
return LBP_PLUS;
- case AST::CompoundAssignmentExpr::SUBTRACT:
+ case CompoundAssignmentOperator::SUBTRACT:
return LBP_MINUS;
- case AST::CompoundAssignmentExpr::MULTIPLY:
+ case CompoundAssignmentOperator::MULTIPLY:
return LBP_MUL;
- case AST::CompoundAssignmentExpr::DIVIDE:
+ case CompoundAssignmentOperator::DIVIDE:
return LBP_DIV;
- case AST::CompoundAssignmentExpr::MODULUS:
+ case CompoundAssignmentOperator::MODULUS:
return LBP_MOD;
- case AST::CompoundAssignmentExpr::BITWISE_AND:
+ case CompoundAssignmentOperator::BITWISE_AND:
return LBP_AMP;
- case AST::CompoundAssignmentExpr::BITWISE_OR:
+ case CompoundAssignmentOperator::BITWISE_OR:
return LBP_PIPE;
- case AST::CompoundAssignmentExpr::BITWISE_XOR:
+ case CompoundAssignmentOperator::BITWISE_XOR:
return LBP_CARET;
- case AST::CompoundAssignmentExpr::LEFT_SHIFT:
+ case CompoundAssignmentOperator::LEFT_SHIFT:
return LBP_L_SHIFT;
- case AST::CompoundAssignmentExpr::RIGHT_SHIFT:
+ case CompoundAssignmentOperator::RIGHT_SHIFT:
return LBP_R_SHIFT;
default:
// WTF? should not happen, this is an error
@@ -13472,7 +13472,7 @@ Parser<ManagedTokenSource>::parse_plus_assig_expr (
return std::unique_ptr<AST::CompoundAssignmentExpr> (
new AST::CompoundAssignmentExpr (std::move (left), std::move (right),
- AST::CompoundAssignmentExpr::ADD, locus));
+ CompoundAssignmentOperator::ADD, locus));
}
// Parses a binary minus-assignment expression (with Pratt parsing).
@@ -13496,7 +13496,7 @@ Parser<ManagedTokenSource>::parse_minus_assig_expr (
return std::unique_ptr<AST::CompoundAssignmentExpr> (
new AST::CompoundAssignmentExpr (std::move (left), std::move (right),
- AST::CompoundAssignmentExpr::SUBTRACT,
+ CompoundAssignmentOperator::SUBTRACT,
locus));
}
@@ -13521,7 +13521,7 @@ Parser<ManagedTokenSource>::parse_mult_assig_expr (
return std::unique_ptr<AST::CompoundAssignmentExpr> (
new AST::CompoundAssignmentExpr (std::move (left), std::move (right),
- AST::CompoundAssignmentExpr::MULTIPLY,
+ CompoundAssignmentOperator::MULTIPLY,
locus));
}
@@ -13546,7 +13546,7 @@ Parser<ManagedTokenSource>::parse_div_assig_expr (
return std::unique_ptr<AST::CompoundAssignmentExpr> (
new AST::CompoundAssignmentExpr (std::move (left), std::move (right),
- AST::CompoundAssignmentExpr::DIVIDE,
+ CompoundAssignmentOperator::DIVIDE,
locus));
}
@@ -13571,7 +13571,7 @@ Parser<ManagedTokenSource>::parse_mod_assig_expr (
return std::unique_ptr<AST::CompoundAssignmentExpr> (
new AST::CompoundAssignmentExpr (std::move (left), std::move (right),
- AST::CompoundAssignmentExpr::MODULUS,
+ CompoundAssignmentOperator::MODULUS,
locus));
}
@@ -13596,7 +13596,7 @@ Parser<ManagedTokenSource>::parse_and_assig_expr (
return std::unique_ptr<AST::CompoundAssignmentExpr> (
new AST::CompoundAssignmentExpr (std::move (left), std::move (right),
- AST::CompoundAssignmentExpr::BITWISE_AND,
+ CompoundAssignmentOperator::BITWISE_AND,
locus));
}
@@ -13621,7 +13621,7 @@ Parser<ManagedTokenSource>::parse_or_assig_expr (
return std::unique_ptr<AST::CompoundAssignmentExpr> (
new AST::CompoundAssignmentExpr (std::move (left), std::move (right),
- AST::CompoundAssignmentExpr::BITWISE_OR,
+ CompoundAssignmentOperator::BITWISE_OR,
locus));
}
@@ -13646,7 +13646,7 @@ Parser<ManagedTokenSource>::parse_xor_assig_expr (
return std::unique_ptr<AST::CompoundAssignmentExpr> (
new AST::CompoundAssignmentExpr (std::move (left), std::move (right),
- AST::CompoundAssignmentExpr::BITWISE_XOR,
+ CompoundAssignmentOperator::BITWISE_XOR,
locus));
}
@@ -13671,7 +13671,7 @@ Parser<ManagedTokenSource>::parse_left_shift_assig_expr (
return std::unique_ptr<AST::CompoundAssignmentExpr> (
new AST::CompoundAssignmentExpr (std::move (left), std::move (right),
- AST::CompoundAssignmentExpr::LEFT_SHIFT,
+ CompoundAssignmentOperator::LEFT_SHIFT,
locus));
}
@@ -13696,7 +13696,7 @@ Parser<ManagedTokenSource>::parse_right_shift_assig_expr (
return std::unique_ptr<AST::CompoundAssignmentExpr> (
new AST::CompoundAssignmentExpr (std::move (left), std::move (right),
- AST::CompoundAssignmentExpr::RIGHT_SHIFT,
+ CompoundAssignmentOperator::RIGHT_SHIFT,
locus));
}