File tree Expand file tree Collapse file tree 1 file changed +3
-8
lines changed
compiler/src/dotty/tools/dotc/core Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Original file line number Diff line number Diff line change @@ -972,20 +972,15 @@ object Denotations {
972972 final def matches (other : SingleDenotation )(implicit ctx : Context ): Boolean =
973973 val d = signature.matchDegree(other.signature)
974974
975- /** Slower check used if the signatures alone do not tell us enough to be sure about matching */
976- def slowCheck = info.matches(other.info)
977-
978975 d match
979976 case FullMatch =>
980- if infoOrCompleter.isInstanceOf [PolyType ] || other.infoOrCompleter.isInstanceOf [PolyType ] then
981- slowCheck
982- else
983- true
977+ true
984978 case MethodNotAMethodMatch =>
985979 // Java allows defining both a field and a zero-parameter method with the same name
986980 ! ctx.erasedTypes && ! (symbol.is(JavaDefined ) && other.symbol.is(JavaDefined ))
987981 case ParamMatch =>
988- ! ctx.erasedTypes && slowCheck
982+ // The signatures do not tell us enough to be sure about matching
983+ ! ctx.erasedTypes && info.matches(other.info)
989984 case noMatch =>
990985 false
991986 end matches
You can’t perform that action at this time.
0 commit comments