From 055b07e4db30742e8282772d08f1c42811bab4fa Mon Sep 17 00:00:00 2001 From: Eugene Burmako Date: Sat, 5 Jan 2013 00:45:50 +0300 Subject: parentTypes => typedParentTypes I felt really uncomfortable having to stare at `parentTypes`, when everyone else in Typers.scala is named typedSomething. --- src/compiler/scala/tools/nsc/typechecker/Namers.scala | 2 +- src/compiler/scala/tools/nsc/typechecker/Typers.scala | 8 ++++---- src/reflect/scala/reflect/internal/Symbols.scala | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) (limited to 'src') diff --git a/src/compiler/scala/tools/nsc/typechecker/Namers.scala b/src/compiler/scala/tools/nsc/typechecker/Namers.scala index af8858bd60..352090892e 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Namers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Namers.scala @@ -878,7 +878,7 @@ trait Namers extends MethodSynthesis { else tpt.tpe } - val parents = typer.parentTypes(templ) map checkParent + val parents = typer.typedParentTypes(templ) map checkParent enterSelf(templ.self) diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala index 7851261e9c..95d7f9475d 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala @@ -1630,7 +1630,7 @@ trait Typers extends Modes with Adaptations with Tags { ) } - def parentTypes(templ: Template): List[Tree] = templ.parents match { + def typedParentTypes(templ: Template): List[Tree] = templ.parents match { case Nil => List(atPos(templ.pos)(TypeTree(AnyRefClass.tpe))) case first :: rest => try { @@ -1652,7 +1652,7 @@ trait Typers extends Modes with Adaptations with Tags { case ex: TypeError => // fallback in case of cyclic errors // @H none of the tests enter here but I couldn't rule it out - // upd. @E when a definitions inherits itself, we end up here + // upd. @E when a definition inherits itself, we end up here // because `typedParentType` triggers `initialize` for parent types symbols log("Type error calculating parents in template " + templ) log("Error: " + ex) @@ -1763,7 +1763,7 @@ trait Typers extends Modes with Adaptations with Tags { reenterTypeParams(cdef.tparams) val tparams1 = cdef.tparams mapConserve (typedTypeDef) val impl1 = typerReportAnyContextErrors(context.make(cdef.impl, clazz, newScope)) { - _.typedTemplate(cdef.impl, parentTypes(cdef.impl)) + _.typedTemplate(cdef.impl, typedParentTypes(cdef.impl)) } val impl2 = finishMethodSynthesis(impl1, clazz, context) if (clazz.isTrait && clazz.info.parents.nonEmpty && clazz.info.firstParent.typeSymbol == AnyClass) @@ -1803,7 +1803,7 @@ trait Typers extends Modes with Adaptations with Tags { ) val impl1 = typerReportAnyContextErrors(context.make(mdef.impl, clazz, newScope)) { _.typedTemplate(mdef.impl, { - parentTypes(mdef.impl) ++ ( + typedParentTypes(mdef.impl) ++ ( if (noSerializable) Nil else { clazz.makeSerializable() diff --git a/src/reflect/scala/reflect/internal/Symbols.scala b/src/reflect/scala/reflect/internal/Symbols.scala index 7761ace50e..41971338fa 100644 --- a/src/reflect/scala/reflect/internal/Symbols.scala +++ b/src/reflect/scala/reflect/internal/Symbols.scala @@ -2232,7 +2232,7 @@ trait Symbols extends api.Symbols { self: SymbolTable => private case class SymbolKind(accurate: String, sanitized: String, abbreviation: String) private def symbolKind: SymbolKind = { var kind = - if (isTermMacro) ("macro method", "macro method", "MAC") + if (isTermMacro) ("term macro", "macro method", "MACM") else if (isInstanceOf[FreeTermSymbol]) ("free term", "free term", "FTE") else if (isInstanceOf[FreeTypeSymbol]) ("free type", "free type", "FTY") else if (isPackage) ("package", "package", "PK") -- cgit v1.2.3