diff options
Diffstat (limited to 'src/dotty')
-rw-r--r-- | src/dotty/tools/dotc/core/Constants.scala | 2 | ||||
-rw-r--r-- | src/dotty/tools/dotc/core/Contexts.scala | 2 | ||||
-rw-r--r-- | src/dotty/tools/dotc/core/Names.scala | 2 | ||||
-rw-r--r-- | src/dotty/tools/dotc/core/Scopes.scala | 4 | ||||
-rw-r--r-- | src/dotty/tools/dotc/core/SymbolLoaders.scala | 2 | ||||
-rw-r--r-- | src/dotty/tools/dotc/core/TyperState.scala | 2 | ||||
-rw-r--r-- | src/dotty/tools/dotc/core/pickling/PickleBuffer.scala | 4 | ||||
-rw-r--r-- | src/dotty/tools/dotc/printing/PlainPrinter.scala | 4 | ||||
-rw-r--r-- | src/dotty/tools/dotc/printing/RefinedPrinter.scala | 2 | ||||
-rw-r--r-- | src/dotty/tools/dotc/util/HashSet.scala | 2 | ||||
-rw-r--r-- | src/dotty/tools/dotc/util/NameTransformer.scala | 2 | ||||
-rw-r--r-- | src/dotty/tools/dotc/util/Positions.scala | 2 | ||||
-rw-r--r-- | src/dotty/tools/dotc/util/ShowPickled.scala | 2 |
13 files changed, 16 insertions, 16 deletions
diff --git a/src/dotty/tools/dotc/core/Constants.scala b/src/dotty/tools/dotc/core/Constants.scala index b04ec0e89..48c832c4b 100644 --- a/src/dotty/tools/dotc/core/Constants.scala +++ b/src/dotty/tools/dotc/core/Constants.scala @@ -85,7 +85,7 @@ object Constants { def booleanValue: Boolean = if (tag == BooleanTag) value.asInstanceOf[Boolean] - else throw new Error("value " + value + " is not a boolean"); + else throw new Error("value " + value + " is not a boolean") def byteValue: Byte = tag match { case ByteTag => value.asInstanceOf[Byte] diff --git a/src/dotty/tools/dotc/core/Contexts.scala b/src/dotty/tools/dotc/core/Contexts.scala index 1793a1938..dd96023d7 100644 --- a/src/dotty/tools/dotc/core/Contexts.scala +++ b/src/dotty/tools/dotc/core/Contexts.scala @@ -411,7 +411,7 @@ object Contexts { /** Allocate and return next free superclass id */ private[core] def nextSuperId: Int = { - lastSuperId += 1; + lastSuperId += 1 if (lastSuperId >= classOfId.length) { val tmp = new Array[ClassSymbol](classOfId.length * 2) classOfId.copyToArray(tmp) diff --git a/src/dotty/tools/dotc/core/Names.scala b/src/dotty/tools/dotc/core/Names.scala index 09fa6cf19..7585e1f37 100644 --- a/src/dotty/tools/dotc/core/Names.scala +++ b/src/dotty/tools/dotc/core/Names.scala @@ -251,7 +251,7 @@ object Names { private def equals(index: Int, cs: Array[Char], offset: Int, len: Int): Boolean = { var i = 0 while ((i < len) && (chrs(index + i) == cs(offset + i))) - i += 1; + i += 1 i == len } diff --git a/src/dotty/tools/dotc/core/Scopes.scala b/src/dotty/tools/dotc/core/Scopes.scala index a20433b1f..367713d11 100644 --- a/src/dotty/tools/dotc/core/Scopes.scala +++ b/src/dotty/tools/dotc/core/Scopes.scala @@ -231,7 +231,7 @@ object Scopes { if (e1 == e) hashTable(index) = e.tail else { - while (e1.tail != e) e1 = e1.tail; + while (e1.tail != e) e1 = e1.tail e1.tail = e.tail } } @@ -243,7 +243,7 @@ object Scopes { final def unlink(sym: Symbol)(implicit ctx: Context): Unit = { var e = lookupEntry(sym.name) while (e ne null) { - if (e.sym == sym) unlink(e); + if (e.sym == sym) unlink(e) e = lookupNextEntry(e) } } diff --git a/src/dotty/tools/dotc/core/SymbolLoaders.scala b/src/dotty/tools/dotc/core/SymbolLoaders.scala index 530d084c7..bebad60cc 100644 --- a/src/dotty/tools/dotc/core/SymbolLoaders.scala +++ b/src/dotty/tools/dotc/core/SymbolLoaders.scala @@ -120,7 +120,7 @@ class SymbolLoaders { */ def binaryOnly(owner: Symbol, name: String)(implicit ctx: Context): Boolean = name == "package" && - (owner.fullName == "scala" || owner.fullName == "scala.reflect") + (owner.fullName.toString == "scala" || owner.fullName.toString == "scala.reflect") /** Initialize toplevel class and module symbols in `owner` from class path representation `classRep` */ diff --git a/src/dotty/tools/dotc/core/TyperState.scala b/src/dotty/tools/dotc/core/TyperState.scala index e0c7481c8..6e17767d2 100644 --- a/src/dotty/tools/dotc/core/TyperState.scala +++ b/src/dotty/tools/dotc/core/TyperState.scala @@ -31,7 +31,7 @@ class TyperState(val reporter: Reporter) extends DotClass with Showable { } /** A fresh typer state with the same constraint as this one. - * @param isCommittable The constraint can be committed to an exclosing context. + * @param isCommittable The constraint can be committed to an enclosing context. */ def fresh(isCommittable: Boolean): TyperState = this diff --git a/src/dotty/tools/dotc/core/pickling/PickleBuffer.scala b/src/dotty/tools/dotc/core/pickling/PickleBuffer.scala index 72007758c..2bedcab92 100644 --- a/src/dotty/tools/dotc/core/pickling/PickleBuffer.scala +++ b/src/dotty/tools/dotc/core/pickling/PickleBuffer.scala @@ -110,7 +110,7 @@ class PickleBuffer(data: Array[Byte], from: Int, to: Int) { do { b = readByte() x = (x << 7) + (b & 0x7f) - } while ((b & 0x80) != 0L); + } while ((b & 0x80) != 0L) x } @@ -158,7 +158,7 @@ class PickleBuffer(data: Array[Byte], from: Int, to: Int) { * @return ... */ def until[T](end: Int, op: () => T): List[T] = - if (readIndex == end) List() else op() :: until(end, op); + if (readIndex == end) List() else op() :: until(end, op) /** Perform operation <code>op</code> the number of * times specified. Concatenate the results into a list. diff --git a/src/dotty/tools/dotc/printing/PlainPrinter.scala b/src/dotty/tools/dotc/printing/PlainPrinter.scala index 84936fbac..e5f85d11b 100644 --- a/src/dotty/tools/dotc/printing/PlainPrinter.scala +++ b/src/dotty/tools/dotc/printing/PlainPrinter.scala @@ -23,11 +23,11 @@ class PlainPrinter(_ctx: Context) extends Printer { ctx.toTextRecursions -= 1 } else { - recursionLimitExceeeded() + recursionLimitExceeded() "..." } - protected def recursionLimitExceeeded() = { + protected def recursionLimitExceeded() = { ctx.warning("Exceeded recursion depth attempting to print type.") (new Throwable).printStackTrace } diff --git a/src/dotty/tools/dotc/printing/RefinedPrinter.scala b/src/dotty/tools/dotc/printing/RefinedPrinter.scala index 6fad6738e..399a28511 100644 --- a/src/dotty/tools/dotc/printing/RefinedPrinter.scala +++ b/src/dotty/tools/dotc/printing/RefinedPrinter.scala @@ -13,7 +13,7 @@ import scala.annotation.switch class RefinedPrinter(_ctx: Context) extends PlainPrinter(_ctx) { - override protected def recursionLimitExceeeded() = {} + override protected def recursionLimitExceeded() = {} protected val PrintableFlags = (ModifierFlags | Label | Module).toCommonFlags diff --git a/src/dotty/tools/dotc/util/HashSet.scala b/src/dotty/tools/dotc/util/HashSet.scala index 3c8ffa251..1c132378b 100644 --- a/src/dotty/tools/dotc/util/HashSet.scala +++ b/src/dotty/tools/dotc/util/HashSet.scala @@ -1,6 +1,6 @@ package dotty.tools.dotc.util -/** A hash set that allows some priviliged protected access to its internals +/** A hash set that allows some privileged protected access to its internals */ class HashSet[T >: Null <: AnyRef](initialCapacity: Int, loadFactor: Float = 0.25f) extends Set[T] with scala.collection.generic.Clearable { private var used: Int = _ diff --git a/src/dotty/tools/dotc/util/NameTransformer.scala b/src/dotty/tools/dotc/util/NameTransformer.scala index ecb480549..2c3520236 100644 --- a/src/dotty/tools/dotc/util/NameTransformer.scala +++ b/src/dotty/tools/dotc/util/NameTransformer.scala @@ -99,7 +99,7 @@ object NameTransformer { def decode(name0: String): String = { //System.out.println("decode: " + name);//DEBUG val name = if (name0.endsWith("<init>")) name0.substring(0, name0.length() - ("<init>").length()) + "this" - else name0; + else name0 var buf: StringBuilder = null val len = name.length() var i = 0 diff --git a/src/dotty/tools/dotc/util/Positions.scala b/src/dotty/tools/dotc/util/Positions.scala index 293bb4a4c..46e4f4ee7 100644 --- a/src/dotty/tools/dotc/util/Positions.scala +++ b/src/dotty/tools/dotc/util/Positions.scala @@ -17,7 +17,7 @@ object Positions { /** A position indicates a range between a start offset and an end offset. * Positions can be synthetic or source-derived. A source-derived position - * has in addition a pointlies somewhere between start and end. The point + * has in addition a point lies somewhere between start and end. The point * is roughly where the ^ would go if an error was diagnosed at that position. * All quantities are encoded opaquely in a Long. */ diff --git a/src/dotty/tools/dotc/util/ShowPickled.scala b/src/dotty/tools/dotc/util/ShowPickled.scala index 1a9da23d5..4278f2ec3 100644 --- a/src/dotty/tools/dotc/util/ShowPickled.scala +++ b/src/dotty/tools/dotc/util/ShowPickled.scala @@ -239,7 +239,7 @@ object ShowPickled { case SYMANNOT => printSymbolRef(); printTypeRef(); buf.until(end, printAnnotArgRef) case ANNOTATEDtpe => - printTypeRef(); buf.until(end, printAnnotInfoRef); + printTypeRef(); buf.until(end, printAnnotInfoRef) case ANNOTINFO => printTypeRef(); buf.until(end, printAnnotArgRef) case ANNOTARGARRAY => |