Skip to content

Commit

Permalink
#CodeHealth Migrate Cel1To2Converter to use java/cel/parser/src/main/…
Browse files Browse the repository at this point in the history
…java/dev/cel/parser/CelUnparserVisitor.java which is publicly exposed by CEL team

Make few method of CelUnparser protected, so inheriting class can use them

PiperOrigin-RevId: 717438507
  • Loading branch information
CEL Dev Team authored and copybara-github committed Jan 20, 2025
1 parent 6dd63e0 commit 7ca9bcf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions parser/src/main/java/dev/cel/parser/CelUnparserVisitor.java
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,7 @@ private void visitIndex(CelCall expr, String op) {
stringBuilder.append(RIGHT_BRACKET);
}

private void visitMaybeNested(CelExpr expr, boolean nested) {
protected void visitMaybeNested(CelExpr expr, boolean nested) {
if (nested) {
stringBuilder.append(LEFT_PAREN);
}
Expand All @@ -329,7 +329,7 @@ private void visitMaybeNested(CelExpr expr, boolean nested) {
}
}

private boolean isBinaryOrTernaryOperator(CelExpr expr) {
protected boolean isBinaryOrTernaryOperator(CelExpr expr) {
if (!isComplexOperator(expr)) {
return false;
}
Expand Down

0 comments on commit 7ca9bcf

Please sign in to comment.