You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Implementation along the lines of
#23463
- [x] Syntax and parsing rules for `only`-capabilities.
- [x] A `Classifier` base trait.
- [x] Enforce restriction that a class cannot inherit two unrelated
classified capability classes.
- [x] A new capability class for `only`-capabilities.
- [x] Implement `captureSetOfInfo` for `only` capabilities.
- [x] The empty capability is `x.only[Nothing]`. It should have empty
`captureSetOfInfo`.
- [x] Well-formedness rules: `only` must refer to a classified
capability class.
- [x] Normalization rules:
- it's `*`, then `.only`, then `.rd`,
- multiple `.only` normalize to the smallest one if the classes are
related,
- multiple `.only` normalize to the empty capability if the classes are
not related.
- [x] define transitive capture set and cache it in a capability. The
_tcs_ does not exist if a capture set in the hierarchy is still an
unsolved capture set variable.
- [x] Add a _classifier_ field to `FreshCap` and `ResultCap`.
- [x] Modify `capToFresh` and `toResultInResults` so that the classifier
field is correctly set.
- [x] Using `tcs`, define when a capability is classified by a
classifier class.
- [x] A FreshCap with a classifier `C` can subsume only capabilities
that are classified as `C`.
- [x] Implement subsumption rules:
- `c.as[C] <: d` if `c <: d` or `c.as[D] <: empty`
- `c.as[C] <: d.as[D]` if `c <: d` and `C` derives from `D`
- `c <: d.as[D]` if `c <: d` and `c` is classified as `D`
- `c.as[D] <: empty` if `tcs(c)` consists of capabilities that all
derive from classifier classes unrelated to `D`.
0 commit comments