File tree Expand file tree Collapse file tree 3 files changed +12
-3
lines changed
compiler/src/dotty/tools/dotc/typer Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -948,6 +948,7 @@ class Namer { typer: Typer =>
948
948
sym.is(ImplicitOrImplied ) == exp.impliedOnly &&
949
949
sym.isAccessibleFrom(path.tpe) &&
950
950
! sym.isConstructor &&
951
+ ! sym.is(ModuleClass ) &&
951
952
! cls.derivesFrom(sym.owner)
952
953
953
954
/** Add a forwarder with name `alias` or its type name equivalent to `mbr`,
@@ -981,7 +982,7 @@ class Namer { typer: Typer =>
981
982
ctx.newSymbol(
982
983
cls, alias,
983
984
Method | Final | mbr.symbol.flags & ImplicitOrImplied ,
984
- mbr.info,
985
+ mbr.info.ensureMethodic ,
985
986
coord = span)
986
987
val forwarderDef =
987
988
if (forwarder.isType) tpd.TypeDef (forwarder.asType)
Original file line number Diff line number Diff line change
1
+ config
2
+ printing
3
+ scanning
4
+ config
Original file line number Diff line number Diff line change 1
1
object Test extends App {
2
2
3
- case class Config ()
3
+ case class Config () {
4
+ println(" config" )
5
+ }
4
6
5
7
class Printer {
6
8
def print () = println(" printing" )
7
- implied config for Config ()
9
+ object cfg extends Config
10
+ implied config for Config
8
11
}
9
12
10
13
class Scanner {
@@ -23,6 +26,7 @@ object Test extends App {
23
26
24
27
Copier .print()
25
28
Copier .scanIt()
29
+ Copier .cfg
26
30
Copier .config
27
31
Copier .config2
28
32
}
You can’t perform that action at this time.
0 commit comments