Skip to content

Conversation

@max-sixty
Copy link
Member

Summary

  • Replace internal compiler error with user-facing error message when a bare lambda like x -> y is used at the top level
  • Now produces clear error: "expected a table, but found a function"

Test plan

  • Updated snapshot test in bad_error_messages.rs
  • All 630 tests pass
  • Lints pass

Fixes #4280

🤖 Generated with Claude Code

Replace internal compiler error with user-facing error message when a
bare lambda like `x -> y` is used at the top level. Now produces:
"expected a table, but found a function"

Fixes PRQL#4280

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
@max-sixty max-sixty merged commit 1d3538a into PRQL:main Dec 21, 2025
34 of 35 checks passed
@max-sixty max-sixty deleted the bug-fixes branch December 21, 2025 02:07
max-sixty added a commit to max-sixty/prql that referenced this pull request Dec 21, 2025
The error message for bare lambda expressions (e.g., `x -> y`) was fixed
in PR PRQL#5634. Move the test from bad_error_messages.rs to error_messages.rs
since the error is now clear and helpful.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
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.

Panic on query x -> y

1 participant