From f8b521a0327c8c902d690f3361f2aeab942a653d Mon Sep 17 00:00:00 2001 From: Nicolas Stucki Date: Mon, 20 Mar 2017 11:18:49 +0100 Subject: Fixed #2086: Add tests for issue that has already been fixed. --- tests/neg/i2086a.scala | 4 ++++ tests/neg/i2086b.scala | 5 +++++ 2 files changed, 9 insertions(+) create mode 100644 tests/neg/i2086a.scala create mode 100644 tests/neg/i2086b.scala (limited to 'tests/neg') diff --git a/tests/neg/i2086a.scala b/tests/neg/i2086a.scala new file mode 100644 index 000000000..b80535c2c --- /dev/null +++ b/tests/neg/i2086a.scala @@ -0,0 +1,4 @@ + +object Test { // error: Test cannot be instantiated since it has a member type Foo with possibly conflicting bounds Any <: ... <: Nothing + type Foo >: Any <: Nothing +} diff --git a/tests/neg/i2086b.scala b/tests/neg/i2086b.scala new file mode 100644 index 000000000..0a5e296fd --- /dev/null +++ b/tests/neg/i2086b.scala @@ -0,0 +1,5 @@ + +object Test { // error: Test cannot be instantiated since it has a member type Bound with possibly conflicting bounds [Left, Right] => Left <: ... <: [Left, Right] => Right + type Bound[Left, Right] >: Left <: Right + type Foo = Bound[Any, Nothing] +} -- cgit v1.2.3