diff options
author | Eugene Burmako <xeno.by@gmail.com> | 2013-02-05 11:24:42 +0100 |
---|---|---|
committer | Eugene Burmako <xeno.by@gmail.com> | 2013-02-05 11:24:42 +0100 |
commit | 4ef2a4971b62e0c7d4547de1096bec3231b918cb (patch) | |
tree | 592f9fa5f32779e6f187e6bf99602560d03a7e91 /src | |
parent | 0e0c8515ff52b0a2998f9a36840fb3c0a72c9f04 (diff) | |
download | scala-4ef2a4971b62e0c7d4547de1096bec3231b918cb.tar.gz scala-4ef2a4971b62e0c7d4547de1096bec3231b918cb.tar.bz2 scala-4ef2a4971b62e0c7d4547de1096bec3231b918cb.zip |
[nomaster] Revert "s/SuperCallArgs/SuperArgs/"
This reverts commit 2621918870e531b7a9bcccdf14bddea9b89804b2.
Diffstat (limited to 'src')
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/StdAttachments.scala | 12 | ||||
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/Typers.scala | 6 |
2 files changed, 9 insertions, 9 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/StdAttachments.scala b/src/compiler/scala/tools/nsc/typechecker/StdAttachments.scala index 20db479463..0a1d3bfa7a 100644 --- a/src/compiler/scala/tools/nsc/typechecker/StdAttachments.scala +++ b/src/compiler/scala/tools/nsc/typechecker/StdAttachments.scala @@ -19,16 +19,16 @@ trait StdAttachments { * by `parentTypes`. This attachment coordinates `parentTypes` and `typedTemplate` and * allows them to complete the synthesis. */ - case class SuperArgsAttachment(argss: List[List[Tree]]) + case class SuperCallArgsAttachment(argss: List[List[Tree]]) - /** Convenience method for `SuperArgsAttachment`. + /** Convenience method for `SuperCallArgsAttachment`. * Compared with `MacroRuntimeAttachment` this attachment has different a usage pattern, * so it really benefits from a dedicated extractor. */ - def superArgs(tree: Tree): Option[List[List[Tree]]] = - tree.attachments.get[SuperArgsAttachment] collect { case SuperArgsAttachment(argss) => argss } + def superCallArgs(tree: Tree): Option[List[List[Tree]]] = + tree.attachments.get[SuperCallArgsAttachment] collect { case SuperCallArgsAttachment(argss) => argss } - /** Determines whether the given tree has an associated SuperArgsAttachment. + /** Determines whether the given tree has an associated SuperCallArgsAttachment. */ - def hasSuperArgs(tree: Tree): Boolean = superArgs(tree).nonEmpty + def hasSuperArgs(tree: Tree): Boolean = superCallArgs(tree).nonEmpty }
\ No newline at end of file diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala index 026c130a87..c7554801a0 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala @@ -1532,7 +1532,7 @@ trait Typers extends Modes with Adaptations with Tags { * * Returns a `TypeTree` representing a resolved parent type. * If the typechecked parent reference implies non-nullary and non-empty argument list, - * this argument list is attached to the returned value in SuperArgsAttachment. + * this argument list is attached to the returned value in SuperCallArgsAttachment. * The attachment is necessary for the subsequent typecheck to fixup a super constructor call * in the body of the primary constructor (see `typedTemplate` for details). * @@ -1598,7 +1598,7 @@ trait Typers extends Modes with Adaptations with Tags { // this is the place where we tell the typer what argss should be used for the super call // if argss are nullary or empty, then (see the docs for `typedPrimaryConstrBody`) // the super call dummy is already good enough, so we don't need to do anything - if (argssAreTrivial) supertpt else supertpt updateAttachment SuperArgsAttachment(argss) + if (argssAreTrivial) supertpt else supertpt updateAttachment SuperCallArgsAttachment(argss) } } @@ -2023,7 +2023,7 @@ trait Typers extends Modes with Adaptations with Tags { val primaryCtor = treeInfo.firstConstructor(body) val primaryCtor1 = primaryCtor match { case DefDef(_, _, _, _, _, Block(earlyVals :+ global.pendingSuperCall, unit)) => - val argss = superArgs(parents1.head) getOrElse Nil + val argss = superCallArgs(parents1.head) getOrElse Nil val pos = wrappingPos(parents1.head.pos, argss.flatten) val superCall = atPos(pos)(PrimarySuperCall(argss)) deriveDefDef(primaryCtor)(block => Block(earlyVals :+ superCall, unit) setPos pos) setPos pos |