RefChecks

object RefChecks
Companion
class
class Object
trait Matchable
class Any

Type members

Classlikes

class LevelInfo(outerLevelAndIndex: LevelAndIndex, stats: List[Tree])(using `x$3`: Context) extends OptLevelInfo

A class to help in forward reference checking

A class to help in forward reference checking

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.

Concrete fields

val name: String