Skip to content

feat(core): add LambdaBuilder for build-time lambda validation#753

Draft
benbellick wants to merge 22 commits intomainfrom
benbellick/proposed-lambda-validation-impl
Draft

feat(core): add LambdaBuilder for build-time lambda validation#753
benbellick wants to merge 22 commits intomainfrom
benbellick/proposed-lambda-validation-impl

Conversation

@benbellick
Copy link
Member

WIP: Adds LambdaBuilder, a context-aware builder that validates lambda parameter references at build time. Mirrors the lambdaContext stack pattern from substrait-go. The builder maintains a parameter stack, pushing/popping around body construction so that stepsOut is computed automatically. Nested lambdas use the same lb.lambda() call as root lambdas. Tests still need work.

Built on top of #710.
Ref #688

Moves ProtoExpressionConverter to use LambdaBuilder for lambda parameter
validation, removing the private LambdaParameterStack. Replaces builder-based
roundtrip tests with parameterized JSON fixtures in expressions/lambda/.
Adds arithmetic body test to isthmus LambdaExpressionTest.
@benbellick benbellick force-pushed the benbellick/proposed-lambda-validation-impl branch from e8543d8 to 67c5a8a Compare March 16, 2026 21:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants