diff options
Diffstat (limited to 'test/files/neg')
-rw-r--r-- | test/files/neg/t3946.check | 5 | ||||
-rw-r--r-- | test/files/neg/t3946/J.java | 4 | ||||
-rw-r--r-- | test/files/neg/t3946/S_1.scala | 4 |
3 files changed, 13 insertions, 0 deletions
diff --git a/test/files/neg/t3946.check b/test/files/neg/t3946.check new file mode 100644 index 0000000000..6379b50dba --- /dev/null +++ b/test/files/neg/t3946.check @@ -0,0 +1,5 @@ +S_1.scala:3: error: overriding method m in class J of type ()Unit; + method m has weaker access privileges; it should be at least protected[p] + override protected def m { } + ^ +one error found diff --git a/test/files/neg/t3946/J.java b/test/files/neg/t3946/J.java new file mode 100644 index 0000000000..189b8e1d23 --- /dev/null +++ b/test/files/neg/t3946/J.java @@ -0,0 +1,4 @@ +package p; +public class J { + protected void m() { return; } +} diff --git a/test/files/neg/t3946/S_1.scala b/test/files/neg/t3946/S_1.scala new file mode 100644 index 0000000000..2c52094701 --- /dev/null +++ b/test/files/neg/t3946/S_1.scala @@ -0,0 +1,4 @@ +package p +class S extends J { + override protected def m { } +} |