diff options
author | Paul Phillips <paulp@improving.org> | 2012-12-22 10:12:03 -0800 |
---|---|---|
committer | Paul Phillips <paulp@improving.org> | 2012-12-24 13:04:44 -0800 |
commit | 231d59dcf57af99a9e2a1366afd18680c13cd6ce (patch) | |
tree | 4a06a09da8d151fcb266832cf55073995d452cb8 /test/files/neg/t6788.scala | |
parent | 5666468d1bf907295d724d16f52c413696c6efe2 (diff) | |
download | scala-231d59dcf57af99a9e2a1366afd18680c13cd6ce.tar.gz scala-231d59dcf57af99a9e2a1366afd18680c13cd6ce.tar.bz2 scala-231d59dcf57af99a9e2a1366afd18680c13cd6ce.zip |
SI-6829, SI-6788, NPEs during erroneous compilation.
Have to intercept trees which have a null type due to errors
before they leave the warm confines of 'def typed' because from
that point everything assumes tree.tpe != null.
Diffstat (limited to 'test/files/neg/t6788.scala')
-rw-r--r-- | test/files/neg/t6788.scala | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/files/neg/t6788.scala b/test/files/neg/t6788.scala new file mode 100644 index 0000000000..77949ed621 --- /dev/null +++ b/test/files/neg/t6788.scala @@ -0,0 +1,7 @@ +case class B[T](b: T, a: List[Int]) // need two args, B must be polymorphic + +class A { + var s: B[Int] = _ // has to be a var + + s.copy(b = foo) +} |