-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
First steps into separation checking
- Require -source future for separation checking being turned on - Add a type Frash.Cap for fresh maximal capabilities - Maintain hidden sets for these types to record what they subsume - Refacture and document CaputureSet - Make SimpleIdentitySets showable - Refactor VarState - Drop Frozen enum - Make VarState subclasses inner classes of companion object - Rename them - Give implicit parameter VarState of subCapture method a default value - Fix printing of capturesets containing cap and some other capability - Revise handing of @uncheckedAnnotation - The previous meaning did not do enough in the presence of fresh. The new meaning is that all universal capture sets under a @uncheckedCaptures become <fluid> capture sets. - Print `Fresh.Cap` as `fresh` in error messages where both `cap` and `Fresh.Cap` are printed. This avoid confustion with `cap`. Similarly, print `A => B` as `A ->{fresh B` in that case. - Print pre-cc annotated capturing types with @retains annotations with `^`. The annotation is already rendered as a set in this case, but the `^` was missing. - Don't recheck `_` right hand sides of uninitialized variables. These were handled in ways that broke freshness checking. The new `uninitialied` scheme does not have this problem. - Convert cap to fresh in type arguments of asInstanceOf - Let cap and Fresh.Cap subsume other refs only if these others refs cannot be added separately to a capture set. - When creating an instance of a capability class, assume fresh.cap, not cap as capability. - Fix: Skip existentials in when accessing result type in augmentConstructorType - Refactor handling of rechecked types - Always store new types on rechecking - Store them in a hashmap which is associated with the rechecker of the current compilation unit - After rechecking is done, the map is forgotten, unless keepTypes is true. Under keepTypes, then map is kept in an attachment of the unit's root tree. - Change in nomenclature: knownType --> nuType rememberType --> setNuType hasRememberedType --> hasNuType # Conflicts: # compiler/src/dotty/tools/dotc/cc/CaptureOps.scala # compiler/src/dotty/tools/dotc/cc/CaptureRef.scala # compiler/src/dotty/tools/dotc/cc/Existential.scala # project/MiMaFilters.scala # tests/neg-custom-args/captures/box-adapt-cases.check # tests/neg-custom-args/captures/box-adapt-cases.scala # tests/neg-custom-args/captures/existential-mapping.check # tests/neg-custom-args/captures/i19330.check # tests/neg-custom-args/captures/outer-var.check # tests/neg-custom-args/captures/vars.check
- Loading branch information
Showing
68 changed files
with
1,207 additions
and
304 deletions.
There are no files selected for viewing
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
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
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
Oops, something went wrong.