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

Desugaring stages #673

Open
deemp opened this issue Jan 29, 2025 · 3 comments
Open

Desugaring stages #673

deemp opened this issue Jan 29, 2025 · 3 comments

Comments

@deemp
Copy link
Member

deemp commented Jan 29, 2025

@yegor256, should the void $\rho$-attribute be inserted into formations with a $\Delta$-attribute like in the second picture?

Image

Image

@yegor256
Copy link
Member

@deemp yes, definitely

@deemp
Copy link
Member Author

deemp commented Jan 30, 2025

@yegor256, do rules manipulate desugared expressions?

Currently, in the rules, we use pattern and result. Should they be desugared like other expressions?

E.g., here are a pattern and a result:

pattern: |
!τ1 ↦ !b1.java_util_Stream$map(α0 ↦ !b2) * !t1,
!B1
result: |
!τ2 ↦ !b1,
!τ3 ↦ Φ.opeo.map-for-each(
α0 ↦ ξ.!τ2,
α1 ↦ !b2
),
!τ1 ↦ ξ.!τ3 * !t1,
!B1

This is what the pattern could be desugared to:


  !τ1 ↦ !b1.java_util_Stream$map(α0 ↦ !b2) * !t1,
  !B1,
  ρ ↦ ∅

It's unclear whether ρ ↦ ∅ should be separate from !B1.

Also, should the pattern be desugared to produce two applications instead of a single application with two attributes?

!τ3 ↦ Φ.opeo.map-for-each(
α0 ↦ ξ.!τ2,
α1 ↦ !b2
),

If the rules manipulate desugared expressions and hence needn't be desugared themselves, the expressions (..., ...) and (...)(...) in the result will have different meanings. In fact, (..., ...) should be prohibited as it won't match anything in a desugared $\varphi$-expression.

@yegor256
Copy link
Member

@deemp rules work only with desugared expressions

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

No branches or pull requests

2 participants