RefChecks

dotty.tools.dotc.typer.RefChecks$
See theRefChecks companion class
object RefChecks

Attributes

Companion:
class
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Concise view

Type members

Classlikes

class OverridingPairsChecker(clazz: ClassSymbol, self: Type)(using x$3: Context) extends Cursor

A class for checking all overriding pairs of class with a given check function

A class for checking all overriding pairs of class with a given check function

Attributes

Graph
Supertypes
class Cursor
class Object
trait Matchable
class Any

Value members

Concrete methods

Check that we do not "override" anything with a private method or something that becomes a private method. According to the Scala modeling this is non-sensical since private members don't override. But Java and the JVM disagree, if the private member is a method. A test case is neg/i7926b.scala. Note: The compiler could possibly silently rename the offending private instead of flagging it as an error. But that might mean we see some surprising names at runtime. E.g. in neg/i4564a.scala, a private case class apply method would have to be renamed to something else.

Check that we do not "override" anything with a private method or something that becomes a private method. According to the Scala modeling this is non-sensical since private members don't override. But Java and the JVM disagree, if the private member is a method. A test case is neg/i7926b.scala. Note: The compiler could possibly silently rename the offending private instead of flagging it as an error. But that might mean we see some surprising names at runtime. E.g. in neg/i4564a.scala, a private case class apply method would have to be renamed to something else.

Attributes

Check that unary method definition do not receive parameters. They can only receive inferred parameters such as type parameters and implicit parameters.

Check that unary method definition do not receive parameters. They can only receive inferred parameters such as type parameters and implicit parameters.

Attributes

Concrete fields