Skip to content

Conversation

@zhiyuuuu
Copy link

Issue #, if available:

Description of changes:
Adding support to while, for, continue, and break

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

zhiyuuuu and others added 30 commits September 14, 2025 14:13
This reverts commit 7ce97fa.
Extend the dialect of for statement in Typescript
Julia/tsbasic: Add While loop for Strata
@zhiyuuuu zhiyuuuu requested review from a team and atomb as code owners September 25, 2025 18:15
def intEqFunc [Coe String Ident] : LFunc Ident :=
binaryPredicate "Int.Eq" .int
(some (binOpCeval Int Bool LExpr.denoteInt (fun x y => x == y) .bool))

Copy link
Contributor

Choose a reason for hiding this comment

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

Lambda has a general-purpose .eq constructor that I would think would make this unnecessary. Is there an issue with using that?

Copy link
Contributor

Choose a reason for hiding this comment

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

+1.

Copy link

Choose a reason for hiding this comment

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

Could you please clarify that we can use the built-in Lambda.LExpr.eq here? See link to code: https://github.com/strata-org/Strata/pull/141/files/9963ca05def0a0856478cb2939fb69cfca7086ac#r2399812517

Copy link

Choose a reason for hiding this comment

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

Hi Aaron and Shilpi, this is to support the "==" operator based on its original definition.
| "==" => Heap.HExpr.app (Heap.HExpr.app (Heap.HExpr.deferredOp "Int.Eq" none) lhs) rhs.

Copy link
Contributor

Choose a reason for hiding this comment

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

We'll focus on === for now.

@andrewmwells-amazon andrewmwells-amazon merged commit ff2f248 into strata-org:typescript-frontend Oct 28, 2025
4 of 5 checks passed
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.

7 participants