diff options
author | Martin Odersky <odersky@gmail.com> | 2013-03-26 16:20:53 +0100 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2013-03-26 16:20:53 +0100 |
commit | ebc23ad054787d87b18b713f26847ee1443d6890 (patch) | |
tree | acd988222be4653366e446f3ff838d916206152c /src/dotty/tools/dotc | |
parent | 5a039031c165fd9116749f28e9d9e6a0b6d5b0e6 (diff) | |
download | dotty-ebc23ad054787d87b18b713f26847ee1443d6890.tar.gz dotty-ebc23ad054787d87b18b713f26847ee1443d6890.tar.bz2 dotty-ebc23ad054787d87b18b713f26847ee1443d6890.zip |
Some more fixes of classfile reading.
Diffstat (limited to 'src/dotty/tools/dotc')
-rw-r--r-- | src/dotty/tools/dotc/core/Definitions.scala | 2 | ||||
-rw-r--r-- | src/dotty/tools/dotc/core/Printers.scala | 6 | ||||
-rw-r--r-- | src/dotty/tools/dotc/core/SymDenotations.scala | 2 | ||||
-rw-r--r-- | src/dotty/tools/dotc/core/Types.scala | 8 |
4 files changed, 10 insertions, 8 deletions
diff --git a/src/dotty/tools/dotc/core/Definitions.scala b/src/dotty/tools/dotc/core/Definitions.scala index 81cdf4826..a94359b97 100644 --- a/src/dotty/tools/dotc/core/Definitions.scala +++ b/src/dotty/tools/dotc/core/Definitions.scala @@ -45,7 +45,7 @@ class Definitions(implicit ctx: Context) { private def mkArityArray(name: String, arity: Int, countFrom: Int): Array[ClassSymbol] = { val arr = new Array[ClassSymbol](arity) - for (i <- countFrom to arity) arr(i) = requiredClass("scala." + name + i) + for (i <- countFrom until arity) arr(i) = requiredClass("scala." + name + i) arr } diff --git a/src/dotty/tools/dotc/core/Printers.scala b/src/dotty/tools/dotc/core/Printers.scala index e789e7db1..6e63eec3a 100644 --- a/src/dotty/tools/dotc/core/Printers.scala +++ b/src/dotty/tools/dotc/core/Printers.scala @@ -96,9 +96,9 @@ object Printers { try { ctx.toTextRecursions += 1 op - } catch { - case ex: CyclicReference => - s"<cycle involving ${ex.denot}>" +// } catch { +// case ex: CyclicReference => +// s"<cycle involving ${ex.denot}>" } finally { ctx.toTextRecursions -= 1 } diff --git a/src/dotty/tools/dotc/core/SymDenotations.scala b/src/dotty/tools/dotc/core/SymDenotations.scala index fc702b85e..106bb1ca6 100644 --- a/src/dotty/tools/dotc/core/SymDenotations.scala +++ b/src/dotty/tools/dotc/core/SymDenotations.scala @@ -171,7 +171,7 @@ object SymDenotations { /** The name with which the denoting symbol was created */ final def originalName = - if (flags is ExpandedName) initial.asSymDenotation.name else name + if (this is ExpandedName) initial.asSymDenotation.name else name /** The encoded full path name of this denotation, where outer names and inner names * are separated by `separator` characters. diff --git a/src/dotty/tools/dotc/core/Types.scala b/src/dotty/tools/dotc/core/Types.scala index 35225e8e7..c1a84604f 100644 --- a/src/dotty/tools/dotc/core/Types.scala +++ b/src/dotty/tools/dotc/core/Types.scala @@ -634,9 +634,11 @@ object Types { if (buf == null) null else { if (tparams == null) tparams = tycon.typeParams - val tparam = tparams(buf.size) - if (name == tparam.name) buf += tp.refinedInfo.argType(tparam) - else null + if (buf.size < tparams.length) { + val tparam = tparams(buf.size) + if (name == tparam.name) buf += tp.refinedInfo.argType(tparam) + else null + } else null } case _ => if (refineCount == 0) null |