diff options
author | Eugene Burmako <xeno.by@gmail.com> | 2014-01-28 18:45:30 +0300 |
---|---|---|
committer | Eugene Burmako <xeno.by@gmail.com> | 2014-02-14 14:16:44 +0100 |
commit | c7fd03900b7023967f22932f1f32b98d57983e9b (patch) | |
tree | 508c8b7a5ab347157dc792d297ffcad239a1c6c1 | |
parent | 7fc77f83c873ce3fada0e01db4947caeb67527ab (diff) | |
download | scala-c7fd03900b7023967f22932f1f32b98d57983e9b.tar.gz scala-c7fd03900b7023967f22932f1f32b98d57983e9b.tar.bz2 scala-c7fd03900b7023967f22932f1f32b98d57983e9b.zip |
ValOrDefDef.name is now TermName
Back then when we planned to introduce type macros, we relaxed the type
of DefDef.name from TermName to Name in order to potentially be able to
accommodate type names for type macros.
Since then, type macros have been cancelled (and, for the record, my
implementation of type macros in paradise 1.0 didn’t involve DefDefs
with TypeNames), and we’ve rolled back the change to DefDef.name.
What we forgot to do, however, was to change the type of ValOrDefDef.name,
which is taken care of in this commit.
-rw-r--r-- | src/reflect/scala/reflect/api/Trees.scala | 2 | ||||
-rw-r--r-- | src/reflect/scala/reflect/internal/Trees.scala | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/reflect/scala/reflect/api/Trees.scala b/src/reflect/scala/reflect/api/Trees.scala index 95d9d84597..ab39dce035 100644 --- a/src/reflect/scala/reflect/api/Trees.scala +++ b/src/reflect/scala/reflect/api/Trees.scala @@ -475,7 +475,7 @@ trait Trees { self: Universe => */ trait ValOrDefDefApi extends MemberDefApi { this: ValOrDefDef => /** @inheritdoc */ - def name: Name // can't be a TermName because macros can be type names. + def name: TermName /** The type ascribed to the definition. * An empty `TypeTree` if the type hasn't been specified explicitly diff --git a/src/reflect/scala/reflect/internal/Trees.scala b/src/reflect/scala/reflect/internal/Trees.scala index 2e35293f4a..4e09472fe6 100644 --- a/src/reflect/scala/reflect/internal/Trees.scala +++ b/src/reflect/scala/reflect/internal/Trees.scala @@ -303,7 +303,7 @@ trait Trees extends api.Trees { object ModuleDef extends ModuleDefExtractor abstract class ValOrDefDef extends MemberDef with ValOrDefDefApi { - def name: Name + def name: TermName def tpt: Tree def rhs: Tree } |