-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Rename caps.cap to caps.any #24923
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
base: main
Are you sure you want to change the base?
Rename caps.cap to caps.any #24923
Conversation
a78d005 to
1c34c9f
Compare
|
(fyi @nrinaudo, who iirc might have suggested the name change?) |
|
|
|
Yes, I think |
|
Oh thank god, I had no recollection of suggesting this and was wondering if my mind was finally starting to go. |
This might not be the place for this question, feel free to let me know if it's not, but: how is that going to interact with there being multiple root capabilities? Are we going to have error messages like |
I'm the guilty one :) BTW: many thanks for your efforts in providing pedagogical and down-to-earth explanations of the practical usage of capabilities and capture checking! @nrinaudo |
Yeah well now I have to go and fix all of them to use You're quite welcome - it's mostly how I learn, by explaining things to others and exposing holes in my understanding that I need to fix. |
I guess, esp. for improving error messages etc there needs to be a way to talk about different subsets of |
ceb4e2d to
a48b37b
Compare
What we do now:
|
e932ad8 to
9203008
Compare
Also, LocalCaps are no longer described as "fresh" in error messages.
- Introduce `fresh`
- New global definition: `caps.fresh`.
- `fresh` is for ResultCaps in function types.
- Disallow `fresh` outside result types of function types.
- Fix isTrackableRef: previously, a static term ref was trackable if its prefix was the ThisType
of a package, but was not trackable if the prefix was a TermRef to the same package.
Now both versions are trackable.
- Don't go to basetypes when comparing dependent functions at cc
- Improve printing of capabilities:
- Don't elide a universal capture set in a TypeMismatch message if one of its capabilities is mentioned
in an error note.
- Don't elide capture sets containing fresh when printing
- Don't use the verbose output for fresh if there are no open existentials
- Systematically backquote all entities shown as capabilities
Internally rename FreshCap to LocalCap
Introduce
freshcaps.fresh.freshis for ResultCaps in function types.freshoutside result types of function types.Fix isTrackableRef: previously, a static term ref was trackable if its prefix was the ThisType
of a package, but was not trackable if the prefix was a TermRef to the same package.
Now both versions are trackable.
Don't go to basetypes when comparing dependent functions at cc
Improve printing of capabilities:
in an error note.