diff options
author | Paul Phillips <paulp@improving.org> | 2011-10-01 05:16:22 +0000 |
---|---|---|
committer | Paul Phillips <paulp@improving.org> | 2011-10-01 05:16:22 +0000 |
commit | 55109d0d253c7e89660f1b61d17408648c0c53a4 (patch) | |
tree | db44f381515b79a575562cb2eacaaa8b7b590b7d /src/compiler/scala | |
parent | ff5619e1f0d1653642e93e2c6a051c88231c95fb (diff) | |
download | scala-55109d0d253c7e89660f1b61d17408648c0c53a4.tar.gz scala-55109d0d253c7e89660f1b61d17408648c0c53a4.tar.bz2 scala-55109d0d253c7e89660f1b61d17408648c0c53a4.zip |
Shuffling classes around.
Old Man Reflection is coming home and he's not going to like finding
out a bunch of beans have moved into his reflecting room. We had better
evict those guys before he blows his stack.
scala.reflect.*Bean* --> scala.beans.*
scala.beans, that's kind of a fancy package name for some beans. I
figure it's time to start fishing or cutting bait on this kind of thing.
I don't even know what beans are, but if we're going to have them in the
mainline, the least surprising place to find them is scala.beans. If we
don't want to put them in scala.beans for whatever reason, then I say
they don't belong in trunk at all.
Bonus round:
scala.annotation.target --> scala.beans.meta
I don't know if there is any more unfortunate name for a package
possible than "target". Maybe ".svn" or ".git" if you could have dots
in package names. Package CVS wouldn't hit too hard these days. Package
lib_managed? I'll try to come up with something. In any case this golden
opportunity could not be squandered.
There is a new starr included, because GenJVM contains all kinds of
shooting-from-the-hip Bean-related name hardcoding. (Yes, still. I ran
out of stones. So a few birds escape with their lives... this time.)
Diffstat (limited to 'src/compiler/scala')
-rw-r--r-- | src/compiler/scala/reflect/internal/Definitions.scala | 12 | ||||
-rw-r--r-- | src/compiler/scala/reflect/internal/StdNames.scala | 4 | ||||
-rw-r--r-- | src/compiler/scala/tools/nsc/backend/jvm/GenJVM.scala | 12 |
3 files changed, 14 insertions, 14 deletions
diff --git a/src/compiler/scala/reflect/internal/Definitions.scala b/src/compiler/scala/reflect/internal/Definitions.scala index 1f918d0df1..a46b7d6bc7 100644 --- a/src/compiler/scala/reflect/internal/Definitions.scala +++ b/src/compiler/scala/reflect/internal/Definitions.scala @@ -209,12 +209,12 @@ trait Definitions extends reflect.api.StandardDefinitions { lazy val ElidableMethodClass = getClass("scala.annotation.elidable") lazy val ImplicitNotFoundClass = getClass("scala.annotation.implicitNotFound") lazy val VarargsClass = getClass("scala.annotation.varargs") - lazy val FieldTargetClass = getClass("scala.annotation.target.field") - lazy val GetterTargetClass = getClass("scala.annotation.target.getter") - lazy val SetterTargetClass = getClass("scala.annotation.target.setter") - lazy val BeanGetterTargetClass = getClass("scala.annotation.target.beanGetter") - lazy val BeanSetterTargetClass = getClass("scala.annotation.target.beanSetter") - lazy val ParamTargetClass = getClass("scala.annotation.target.param") + lazy val FieldTargetClass = getClass("scala.beans.meta.field") + lazy val GetterTargetClass = getClass("scala.beans.meta.getter") + lazy val SetterTargetClass = getClass("scala.beans.meta.setter") + lazy val BeanGetterTargetClass = getClass("scala.beans.meta.beanGetter") + lazy val BeanSetterTargetClass = getClass("scala.beans.meta.beanSetter") + lazy val ParamTargetClass = getClass("scala.beans.meta.param") lazy val ScalaInlineClass = getClass("scala.inline") lazy val ScalaNoInlineClass = getClass("scala.noinline") lazy val SpecializedClass = getClass("scala.specialized") diff --git a/src/compiler/scala/reflect/internal/StdNames.scala b/src/compiler/scala/reflect/internal/StdNames.scala index 4947334c1e..eb17a13dd4 100644 --- a/src/compiler/scala/reflect/internal/StdNames.scala +++ b/src/compiler/scala/reflect/internal/StdNames.scala @@ -606,8 +606,8 @@ trait StdNames extends /*reflect.generic.StdNames with*/ NameManglers { self: Sy } private class J2SENames extends JavaNames { - final val BeanProperty: TypeName = "scala.reflect.BeanProperty" - final val BooleanBeanProperty: TypeName = "scala.reflect.BooleanBeanProperty" + final val BeanProperty: TypeName = "scala.beans.BeanProperty" + final val BooleanBeanProperty: TypeName = "scala.beans.BooleanBeanProperty" final val Code: TypeName = "scala.reflect.Code" final val JavaSerializable: TypeName = "java.io.Serializable" } diff --git a/src/compiler/scala/tools/nsc/backend/jvm/GenJVM.scala b/src/compiler/scala/tools/nsc/backend/jvm/GenJVM.scala index d7e2d92837..7f1dc1fbcd 100644 --- a/src/compiler/scala/tools/nsc/backend/jvm/GenJVM.scala +++ b/src/compiler/scala/tools/nsc/backend/jvm/GenJVM.scala @@ -180,10 +180,10 @@ abstract class GenJVM extends SubComponent with GenJVMUtil with GenAndroid with val MethodHandleType = new JObjectType("java.dyn.MethodHandle") // Scala attributes - val BeanInfoAttr = definitions.getClass("scala.reflect.BeanInfo") - val BeanInfoSkipAttr = definitions.getClass("scala.reflect.BeanInfoSkip") - val BeanDisplayNameAttr = definitions.getClass("scala.reflect.BeanDisplayName") - val BeanDescriptionAttr = definitions.getClass("scala.reflect.BeanDescription") + val BeanInfoAttr = definitions.getClass("scala.beans.BeanInfo") + val BeanInfoSkipAttr = definitions.getClass("scala.beans.BeanInfoSkip") + val BeanDisplayNameAttr = definitions.getClass("scala.beans.BeanDisplayName") + val BeanDescriptionAttr = definitions.getClass("scala.beans.BeanDescription") lazy val CloneableClass = definitions.getClass("java.lang.Cloneable") lazy val RemoteInterface = definitions.getClass("java.rmi.Remote") @@ -443,7 +443,7 @@ abstract class GenJVM extends SubComponent with GenJVMUtil with GenAndroid with val beanInfoClass = fjbgContext.JClass(javaFlags(c.symbol), javaName(c.symbol) + "BeanInfo", - "scala/reflect/ScalaBeanInfo", + "scala/beans/ScalaBeanInfo", JClass.NO_INTERFACES, c.cunit.source.toString) @@ -497,7 +497,7 @@ abstract class GenJVM extends SubComponent with GenJVMUtil with GenAndroid with // invoke the superclass constructor, which will do the // necessary java reflection and create Method objects. - jcode.emitINVOKESPECIAL("scala/reflect/ScalaBeanInfo", "<init>", conType) + jcode.emitINVOKESPECIAL("scala/beans/ScalaBeanInfo", "<init>", conType) jcode.emitRETURN() // write the bean information class file. |