summaryrefslogtreecommitdiff
path: root/src/compiler
diff options
context:
space:
mode:
authorEugene Burmako <xeno.by@gmail.com>2012-07-02 00:37:59 +0200
committerEugene Burmako <xeno.by@gmail.com>2012-07-02 00:53:04 +0200
commit105d3efcc723cb7312a25a898a7769c7f762b57e (patch)
treec36e1188cd883b1b9da10b36369c6ee2611cf7f9 /src/compiler
parentcd1e6f94e92f2c8fc79aa3c76b1e3b813182e2d3 (diff)
downloadscala-105d3efcc723cb7312a25a898a7769c7f762b57e.tar.gz
scala-105d3efcc723cb7312a25a898a7769c7f762b57e.tar.bz2
scala-105d3efcc723cb7312a25a898a7769c7f762b57e.zip
moves reflective compiler into scala.tools.reflect
Diffstat (limited to 'src/compiler')
-rw-r--r--src/compiler/scala/tools/reflect/ReflectGlobal.scala (renamed from src/compiler/scala/tools/nsc/ReflectGlobal.scala)9
-rw-r--r--src/compiler/scala/tools/reflect/ReflectMain.scala (renamed from src/compiler/scala/tools/nsc/ReflectMain.scala)12
-rw-r--r--src/compiler/scala/tools/reflect/ReflectSetup.scala (renamed from src/compiler/scala/tools/nsc/ReflectSetup.scala)7
-rw-r--r--src/compiler/scala/tools/reflect/ToolBoxFactory.scala1
4 files changed, 19 insertions, 10 deletions
diff --git a/src/compiler/scala/tools/nsc/ReflectGlobal.scala b/src/compiler/scala/tools/reflect/ReflectGlobal.scala
index 4f4db83339..f8ded56ec6 100644
--- a/src/compiler/scala/tools/nsc/ReflectGlobal.scala
+++ b/src/compiler/scala/tools/reflect/ReflectGlobal.scala
@@ -1,12 +1,15 @@
-package scala.tools.nsc
+package scala.tools
+package reflect
-import reporters.Reporter
+import scala.tools.nsc.Global
+import scala.tools.nsc.reporters.Reporter
+import scala.tools.nsc.Settings
/** A version of Global that uses reflection to get class
* infos, instead of reading class or source files.
*/
class ReflectGlobal(currentSettings: Settings, reporter: Reporter, override val rootClassLoader: ClassLoader)
- extends Global(currentSettings, reporter) with scala.tools.nsc.ReflectSetup with scala.reflect.runtime.SymbolTable {
+ extends Global(currentSettings, reporter) with scala.tools.reflect.ReflectSetup with scala.reflect.runtime.SymbolTable {
override def transformedType(sym: Symbol) =
erasure.transformInfo(sym,
diff --git a/src/compiler/scala/tools/nsc/ReflectMain.scala b/src/compiler/scala/tools/reflect/ReflectMain.scala
index 161391fc2c..116ae24cdd 100644
--- a/src/compiler/scala/tools/nsc/ReflectMain.scala
+++ b/src/compiler/scala/tools/reflect/ReflectMain.scala
@@ -1,8 +1,12 @@
-package scala.tools.nsc
+package scala.tools
+package reflect
-import tools.util.PathResolver
-import util.ClassPath.DefaultJavaContext
-import util.ScalaClassLoader
+import scala.tools.nsc.Driver
+import scala.tools.nsc.Global
+import scala.tools.nsc.Settings
+import scala.tools.nsc.util.ClassPath.DefaultJavaContext
+import scala.tools.nsc.util.ScalaClassLoader
+import scala.tools.util.PathResolver
object ReflectMain extends Driver {
diff --git a/src/compiler/scala/tools/nsc/ReflectSetup.scala b/src/compiler/scala/tools/reflect/ReflectSetup.scala
index 26c720a10f..f18c114d62 100644
--- a/src/compiler/scala/tools/nsc/ReflectSetup.scala
+++ b/src/compiler/scala/tools/reflect/ReflectSetup.scala
@@ -1,7 +1,10 @@
-package scala.tools.nsc
+package scala.tools
+package reflect
+
+import scala.tools.nsc.Global
/** A helper trait to initialize things that need to be set before JavaMirrors and other
* reflect specific traits are initialized */
-private[nsc] trait ReflectSetup { this: Global =>
+private[reflect] trait ReflectSetup { this: Global =>
phase = new Run().typerPhase
} \ No newline at end of file
diff --git a/src/compiler/scala/tools/reflect/ToolBoxFactory.scala b/src/compiler/scala/tools/reflect/ToolBoxFactory.scala
index 278f4e3ff7..b4178102b9 100644
--- a/src/compiler/scala/tools/reflect/ToolBoxFactory.scala
+++ b/src/compiler/scala/tools/reflect/ToolBoxFactory.scala
@@ -2,7 +2,6 @@ package scala.tools
package reflect
import scala.tools.nsc.reporters._
-import scala.tools.nsc.ReflectGlobal
import scala.tools.nsc.CompilerCommand
import scala.tools.nsc.Global
import scala.tools.nsc.typechecker.Modes