Skip to content

Support for type alias in LExprT (temporary fix, if needed)#39

Merged
atomb merged 12 commits into
mainfrom
sam/temporary-fix
Aug 14, 2025
Merged

Support for type alias in LExprT (temporary fix, if needed)#39
atomb merged 12 commits into
mainfrom
sam/temporary-fix

Conversation

@samuelchassot
Copy link
Copy Markdown
Contributor

Description of changes:

This adds supports for Type aliases in type annotations on LExpr. Ideally, we'd like to parametrized LExpr on the type of type annotations, to let users write LExpr with LTy, and have LExpr with only LMonoTy later in the type analysis and partial evaluation.
This PR fixes the bug in case we need a temporary fix.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@samuelchassot samuelchassot marked this pull request as draft August 6, 2025 19:32
Comment thread Strata/DL/Lambda/LExprT.lean Outdated
@samuelchassot samuelchassot marked this pull request as ready for review August 13, 2025 21:25
atomb
atomb previously approved these changes Aug 13, 2025
Copy link
Copy Markdown
Contributor

@atomb atomb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this seems reasonable, though I'm not deeply familiar with the code involved.

Comment thread Strata/DL/Lambda/LExprT.lean Outdated
Comment thread Strata/DL/Lambda/LExprT.lean Outdated
Comment thread Strata/DL/Lambda/LExprT.lean Outdated
Co-authored-by: Andrew Wells <130512013+andrewmwells-amazon@users.noreply.github.com>
samuelchassot and others added 2 commits August 14, 2025 10:47
Co-authored-by: Andrew Wells <130512013+andrewmwells-amazon@users.noreply.github.com>
Co-authored-by: Andrew Wells <130512013+andrewmwells-amazon@users.noreply.github.com>
@joehendrix
Copy link
Copy Markdown
Contributor

There is a disabled test in here that I think was broken because of lack of type alias support in unification.

It's probably worth checking if this fixes that test and if not, updating the comment to reflect it isn't related.

@atomb atomb merged commit 4e30652 into main Aug 14, 2025
7 checks passed
@atomb atomb deleted the sam/temporary-fix branch August 14, 2025 18:02
samuelchassot added a commit that referenced this pull request Aug 15, 2025
*Description of changes:*

This test was commented out because of missing type aliases support, but
with PR #39, it works.

Also, I added a label to the assertion, otherwise the `.smt2` filename
is too long and is rejected by `z3`. I will file an issue.

By submitting this pull request, I confirm that you can use, modify,
copy, and redistribute this contribution, under the terms of your
choice.
keyboardDrummer-bot added a commit that referenced this pull request May 6, 2026
Save prepends before processing arguments so that:
1. Argument side-effects execute first (defining snapshot variables)
2. Outer prepends (from sibling expressions) execute next (defining
   their snapshot variables that the call may reference)
3. The lifted call executes last (after all referenced variables exist)

Also uncomments the addProcCaller test case. The correct assertion
value is 15 (not 14): addProc(1,11)=12, plus (x:=3)=3, total 15.

Closes #39
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.

4 participants