We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 775eb8a commit c04683bCopy full SHA for c04683b
src/dotty/tools/dotc/core/MemberInfo.scala renamed to src/dotty/tools/dotc/core/MemberBinding.scala
src/dotty/tools/dotc/core/Types.scala
@@ -3108,7 +3108,10 @@ object Types {
3108
3109
object BindingKind {
3110
def fromVariance(v: Int): BindingKind = new BindingKind((v + NonvariantBinding.n).toByte)
3111
- def toVariance(bk: BindingKind): Int = bk.n
+ def toVariance(bk: BindingKind): Int = {
3112
+ assert(bk.n != 0)
3113
+ bk.n - NonvariantBinding.n
3114
+ }
3115
}
3116
3117
// ----- Annotated and Import types -----------------------------------------------
0 commit comments