Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KCL: Refactor pipe bodies #1954

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

adamchalmers
Copy link
Collaborator

PipeExpressions should always have at least two child expressions. The first expression (the head) is a little different from the following subexpressions, because the head can be any value. But the remaining expressions (tail) must be function calls.

This refactors the AST node for PipeExpression so that information is encoded in the type system, not just checked at runtime. Instead of a Vec, it should have a separate head Value and tail Vec.

Copy link

vercel bot commented Mar 28, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
modeling-app ✅ Ready (Inspect) Visit Preview Apr 3, 2024 3:54pm

PipeExpressions should always have at least two child expressions. The
first expression (the head) is a little different from the following
subexpressions, because the head can be any value. But the remaining
expressions (tail) must be function calls.

This refactors the AST node for PipeExpression so that information is
encoded in the type system, not just checked at runtime. Instead of a
Vec<Value>, it should have a separate head Value and tail Vec<Value>.
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.

None yet

1 participant