-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Open
Description
Compiler version
3.8
Minimized example
#23609 triggered an assertion error in TyperState. The relevant explanation seems to be in ProtoTypes.scala:
// To respect the pre-condition of `mergeConstraintWith` and keep
// `protoTyperState` committable we must ensure that it does not
// contain any type variable which don't already exist in the passed
// TyperState. This is achieved by instantiating any such type
// variable. NOTE: this does not suffice to discard type variables
// in ancestors of `protoTyperState`, if this situation ever
// comes up, an assertion in TyperState will trigger and this code
// will need to be generalized.The error was avoided by turning it into a handled exception in #23665. But that's really only a workaround. We should get to the bottom of this and prevent the exception being thrown.