Aladdin - Scala Bugtracking
[#72] project: compiler priority: medium category: bug
submitter assigned to status date submitted
Stephane Martin fixed 2003-07-15 16:48:59.0
subject NullPointerException
code
import scala.collection.mutable._;

object Composites {
    def main(args: Array[String]) = {
        // Set has symbol field "null:
        val weekDays : Set[String] = Set("Mon", "Tue", "Wed", "Thu", "Fri");
    }
}
what happened
Exception in thread "main" java.lang.NullPointerException
        at scalac.typechecker.RefCheck.transform(RefCheck.java:907)
        at scalac.ast.Transformer.transform(Transformer.java:190)
        [..]
what expected an appropriate error message is given, like "constructor not found".
[back to overview]
Changes of this bug report
Burak  edited on  2003-07-15 18:11:21.0
There is no constructor Set( A* ) ! not even HashSet( A* ). Stephane's orginal "what expected" field was "does compile !" so the problem is IMHO a missing check in Analyser.transformIdent(...) or something that calls it.
Martin  edited on  2003-07-15 18:55:07.0