We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 51c331e commit d7a1caeCopy full SHA for d7a1cae
trustfall_core/src/interpreter/filtering.rs
@@ -391,6 +391,12 @@ fn apply_filter_op<
391
left: &FieldValue,
392
right: &RightValue,
393
) -> Option<DataContext<Vertex>> {
394
+ // TODO: This is a missed optimization opportunity:
395
+ // It's possible that computing the arguments for the filter function was expensive,
396
+ // and we might have been able to skip it if `ctx.within_nonexistent_optional()` is true.
397
+ // With the current impl, we fail to do so.
398
+ // For example: we may have created a Regex value from a tag, or used a `@transform` on
399
+ // a property to perform some computation on either the left or right value (#617).
400
(ctx.within_nonexistent_optional() || filter_op(left, right)).then_some(ctx)
401
}
402
0 commit comments