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
enumExpr[A] {
caseBoolLit(b: Boolean) extendsExpr[Boolean]
defeval:A= {
defgo[AA](self: this.type&Expr[AA]):A= self match {
caseBoolLit(b) => b
}
go(this)
}
}
Error message:
|Pattern type Expr.BoolLit[A] is neither a subtype nor a supertype of selector type Expr'[A'](Expr'.this) & Expr'[AA]
|
|where: A is a type variable
| A' is a type in class Expr
| Expr is a object
| Expr' is a class
Motivation for why someone would want to do this: it could allow "indirectly" constraining type parameters of enclosing class.
The text was updated successfully, but these errors were encountered:
Error message:
Motivation for why someone would want to do this: it could allow "indirectly" constraining type parameters of enclosing class.
The text was updated successfully, but these errors were encountered: