Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cel/folding.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ func MaxConstantFoldIterations(limit int) ConstantFoldingOption {
}
}

// Adds an Activation which provides known values for the folding evaluator
// FoldKnownValues adds an Activation which provides known values for the folding evaluator
//
// Any values the activation provides will be used by the constant folder and turned into
// literals in the AST.
Expand Down
4 changes: 3 additions & 1 deletion cel/folding_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,9 @@ func TestConstantFoldingOptimizer(t *testing.T) {
EnableMacroCallTracking(),
Types(&proto3pb.TestAllTypes{}),
Variable("x", DynType),
Constant("c", IntType, types.Int(proto3pb.ImportedGlobalEnum_IMPORT_BAZ)),
// work around different package convention in piper vs github.
// google.expr.proto3.test.ImportedGlobalEnum.IMPORT_BAZ
Constant("c", IntType, types.Int(2)),
)
if err != nil {
t.Fatalf("NewEnv() failed: %v", err)
Expand Down