diff options
Diffstat (limited to 'test/files/neg')
-rw-r--r-- | test/files/neg/t6162-inheritance.check | 10 | ||||
-rw-r--r-- | test/files/neg/t6162-inheritance/defn.scala (renamed from test/files/neg/t6162-inheritance.scala) | 9 | ||||
-rw-r--r-- | test/files/neg/t6162-inheritance/usage.scala | 10 |
3 files changed, 15 insertions, 14 deletions
diff --git a/test/files/neg/t6162-inheritance.check b/test/files/neg/t6162-inheritance.check index e98fa79eb7..13c78030d9 100644 --- a/test/files/neg/t6162-inheritance.check +++ b/test/files/neg/t6162-inheritance.check @@ -1,16 +1,16 @@ -t6162-inheritance.scala:6: warning: inheritance from class Foo in package t6126 is deprecated: `Foo` will be made final in a future version. +usage.scala:3: warning: inheritance from class Foo in package t6126 is deprecated: `Foo` will be made final in a future version. class SubFoo extends Foo ^ -t6162-inheritance.scala:11: warning: inheritance from trait T in package t6126 is deprecated +usage.scala:5: warning: inheritance from trait T in package t6126 is deprecated object SubT extends T ^ -t6162-inheritance.scala:17: warning: inheritance from trait S in package t6126 is deprecated +usage.scala:8: warning: inheritance from trait S in package t6126 is deprecated new S { ^ -t6162-inheritance.scala:6: warning: inheritance from class Foo in package t6126 is deprecated: `Foo` will be made final in a future version. +usage.scala:3: warning: inheritance from class Foo in package t6126 is deprecated: `Foo` will be made final in a future version. class SubFoo extends Foo ^ -t6162-inheritance.scala:11: warning: inheritance from trait T in package t6126 is deprecated +usage.scala:5: warning: inheritance from trait T in package t6126 is deprecated object SubT extends T ^ error: No warnings can be incurred under -Xfatal-warnings. diff --git a/test/files/neg/t6162-inheritance.scala b/test/files/neg/t6162-inheritance/defn.scala index 7b47b9285a..bb582d27b0 100644 --- a/test/files/neg/t6162-inheritance.scala +++ b/test/files/neg/t6162-inheritance/defn.scala @@ -3,17 +3,8 @@ package scala.t6126 @deprecatedInheritance("`Foo` will be made final in a future version.", "2.10.0") class Foo -class SubFoo extends Foo - @deprecatedInheritance() trait T -object SubT extends T - @deprecatedInheritance() trait S - -object O { - new S { - } -} diff --git a/test/files/neg/t6162-inheritance/usage.scala b/test/files/neg/t6162-inheritance/usage.scala new file mode 100644 index 0000000000..097e4f5903 --- /dev/null +++ b/test/files/neg/t6162-inheritance/usage.scala @@ -0,0 +1,10 @@ +package scala.t6126 + +class SubFoo extends Foo + +object SubT extends T + +object O { + new S { + } +} |