Skip to content

Commit

Permalink
Remove reference to CheckedExpr proto in DefaultMetadata
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 704808722
  • Loading branch information
l46kok authored and copybara-github committed Dec 10, 2024
1 parent ab239c4 commit 60b7814
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 10 deletions.
2 changes: 0 additions & 2 deletions runtime/src/main/java/dev/cel/runtime/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -61,15 +61,13 @@ java_library(
"//common",
"//common:error_codes",
"//common:options",
"//common:proto_ast",
"//common:runtime_exception",
"//common/annotations",
"//common/internal:comparison_functions",
"//common/internal:default_message_factory",
"//common/internal:dynamic_proto",
"//common/internal:safe_string_formatter",
"//runtime:runtime_helper",
"@cel_spec//proto/cel/expr:expr_java_proto",
"@maven//:com_google_code_findbugs_annotations",
"@maven//:com_google_errorprone_error_prone_annotations",
"@maven//:com_google_guava_guava",
Expand Down
9 changes: 1 addition & 8 deletions runtime/src/main/java/dev/cel/runtime/DefaultMetadata.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,14 @@

package dev.cel.runtime;

import dev.cel.expr.CheckedExpr;
import com.google.common.base.Preconditions;
import com.google.common.collect.ImmutableMap;
import com.google.errorprone.annotations.Immutable;
import dev.cel.common.CelAbstractSyntaxTree;
import dev.cel.common.CelProtoAbstractSyntaxTree;
import dev.cel.common.annotations.Internal;

/**
* Metadata implementation based on {@link CheckedExpr}.
* Metadata implementation based on {@link CelAbstractSyntaxTree}.
*
* <p>CEL Library Internals. Do Not Use.
*/
Expand All @@ -37,11 +35,6 @@ public DefaultMetadata(CelAbstractSyntaxTree ast) {
this.ast = Preconditions.checkNotNull(ast);
}

@Deprecated
public DefaultMetadata(CheckedExpr checkedExpr) {
this(CelProtoAbstractSyntaxTree.fromCheckedExpr(checkedExpr).getAst());
}

@Override
public String getLocation() {
return ast.getSource().getDescription();
Expand Down

0 comments on commit 60b7814

Please sign in to comment.