-
Notifications
You must be signed in to change notification settings - Fork 28
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
Modal harmony #148
Merged
Merged
Modal harmony #148
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
✅ Deploy Preview for dada-lang ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
This check happens now more as an artifact of creating a temporary, but it's useful.
The idea is that if you have something typed as `my String`, you cannot necessarily convert it to `our String` in place and remain well typed, but you can consume it and produce an `our String`.
This is the general pattern I want to move towards.
Egregious oversight in the permisions logic!
messier commit than I would like but oh well.
(they seem to be working as I expect)
the output the test isn't, I think, what we want, but before this change the test was failing with a dramatic runtime error
Previously we were using reservations for this, but that created a kind of confusion... does x := p.reserve confirm the reservation or just store it? What about x.f := p.reserve This is precisely why AssignFromPlace and friends were added.
to allow specifiers to work, we need to introduce temporaries
This means that `our leased` is a very general default that works well whenever you are reading things. Basically "our leased" means "something I can read for as long as this place is alive". This helps to align the left-to-right evaluation semantics in tricky situations, as well, since reserving a location that is shared can always just clone it.
`AssignFromPlace` should be used for user-defined variables, since that affords the opportunity to apply the user's specifier
(for better or worse)
nikomatsakis
force-pushed
the
modal-harmony
branch
from
April 19, 2022 09:34
96a96d8
to
44adcbd
Compare
bors r+ I'm going to go ahead and land this -- further progress in this direction is tracked by #159 |
Build succeeded: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This branch implements #143. It's not quite where I want it to be yet, but close enough I figured I'd open it up so that there's a preview + playground etc.
Here is a list of things I have done and have yet to do (will update as I go, this is off the top of my head):
my
,our
, etcour
value to yield anotherour
value, instead ofour leased
(preserves all invariants, more convenient overall)my
etc location meet the requirementsany
toour leased