diff options
author | Martin Odersky <odersky@gmail.com> | 2014-05-09 18:14:20 +0200 |
---|---|---|
committer | Samuel Gruetter <samuel.gruetter@epfl.ch> | 2014-05-20 13:38:49 +0200 |
commit | b2c545173ab4869eb1b193d44f822efb83df104c (patch) | |
tree | 9f081bbaebbe03e5824d8acc2332f48b47483e26 /tests/pos/typeinferNull.scala | |
parent | 27081ae59ba5b00b6ae05bb3cdd9c3ff7db0a28e (diff) | |
download | dotty-b2c545173ab4869eb1b193d44f822efb83df104c.tar.gz dotty-b2c545173ab4869eb1b193d44f822efb83df104c.tar.bz2 dotty-b2c545173ab4869eb1b193d44f822efb83df104c.zip |
Nothing is not a superclass of Null.
Fix so it isn't.
This caused an error in ErrorReporting because we do not propagate
bounds into a type like ValOrDefDef[_]. Error in `ErrorReporting` is now fixed but the problem is
reflected in test case `boundspropagation`.
Diffstat (limited to 'tests/pos/typeinferNull.scala')
-rw-r--r-- | tests/pos/typeinferNull.scala | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/pos/typeinferNull.scala b/tests/pos/typeinferNull.scala new file mode 100644 index 000000000..ba25ae181 --- /dev/null +++ b/tests/pos/typeinferNull.scala @@ -0,0 +1,9 @@ +object typeinferNull { + + val x1 = null :: Nil + val x2 = List(null) + + var y1: List[Null] = x1 + y1 = x2 + +} |