diff options
author | Burak Emir <emir@epfl.ch> | 2007-08-14 18:41:08 +0000 |
---|---|---|
committer | Burak Emir <emir@epfl.ch> | 2007-08-14 18:41:08 +0000 |
commit | 7d793f6ff59152a24ce4b22291c49dc1c4c01798 (patch) | |
tree | de3e85afa8a083896e71a42dd68651c3e03a9e98 | |
parent | 2465b7e2aaddefb2204e3dec32ca6c0f3cbe681b (diff) | |
download | scala-7d793f6ff59152a24ce4b22291c49dc1c4c01798.tar.gz scala-7d793f6ff59152a24ce4b22291c49dc1c4c01798.tar.bz2 scala-7d793f6ff59152a24ce4b22291c49dc1c4c01798.zip |
reverted typer change, no feature #1196
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/Typers.scala | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala index 0ba003908c..4fe2159a34 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala @@ -1687,11 +1687,23 @@ trait Typers { self: Analyzer => if (!isFullyDefined(pt)) assert(false, tree+" ==> "+UnApply(fun1, args1)+", pt = "+pt) // <pending-change> // this would be a better choice (from #1196), but fails due to (broken?) refinements - val itype = refinedType(List(pt, arg.tpe), context.owner) + // val itype = refinedType(List(pt, arg.tpe), context.owner) // </pending-change> // restore old type (arg is a dummy tree, just needs to pass typechecking) arg.tpe = oldArgType - UnApply(fun1, args1) setPos tree.pos setType itype //pt + UnApply(fun1, args1) setPos tree.pos setType pt //itype //pt + // + // if you use the better itype, then the following happens. + // the required type looks wrong... + // + ///files/pos/bug0646.scala [FAILED] + // + //failed with type mismatch; + // found : scala.xml.NodeSeq{ ... } + // required: scala.xml.NodeSeq{ ... } with scala.xml.NodeSeq{ ... } with scala.xml.Node on: temp3._data().==("Blabla").&&({ + // exit(temp0); + // true + //}) } else { errorTree(tree, "wrong number of arguments for "+treeSymTypeMsg(fun)) } |