File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
compiler/src/dotty/tools/dotc/core Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -2515,9 +2515,12 @@ object SymDenotations {
2515
2515
multi.filterWithPredicate(_.symbol.associatedFile == chosen)
2516
2516
end dropStale
2517
2517
2518
- if symbol eq defn.ScalaPackageClass then
2518
+ if name == nme.CONSTRUCTOR then
2519
+ NoDenotation // packages don't have constructors, even if package objects do.
2520
+ else if symbol eq defn.ScalaPackageClass then
2521
+ // revert order: search package first, then nested package objects
2519
2522
val denots = super .computeMembersNamed(name)
2520
- if denots.exists || name == nme. CONSTRUCTOR then denots
2523
+ if denots.exists then denots
2521
2524
else recur(packageObjs, NoDenotation )
2522
2525
else recur(packageObjs, NoDenotation )
2523
2526
end computeMembersNamed
You can’t perform that action at this time.
0 commit comments