summaryrefslogtreecommitdiff
path: root/test/files/neg/accesses.scala
blob: 731bf664be652a3cd2658ca3566b98dc3b5be7a3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
package test.p1.p2

abstract class A {
  private[p2] def f2: unit
  protected def f3: unit
  private[p1] def f4: unit
  protected[p1] def f5: unit
}

abstract class OK1 extends A {
  private[p1] def f2: unit
  protected[p2] def f3: unit
  private[test] def f4: unit
  protected[test] def f5: unit
}
abstract class OK2 extends A {
  protected[p1] def f2: unit
  def f3: unit
  protected[p1] def f4: unit
  def f5: unit
}
abstract class Err1 extends A {
  private def f2: unit = ()
  private[p2] def f3: unit = ()
  private[p2] def f4: unit
  protected[p2] def f5: unit
}