diff options
author | Grzegorz Kossakowski <grzegorz.kossakowski@gmail.com> | 2013-07-30 22:26:38 -0700 |
---|---|---|
committer | Grzegorz Kossakowski <grzegorz.kossakowski@gmail.com> | 2013-07-30 22:26:38 -0700 |
commit | 3cb3c8e35c3df31a7f661903eca48cca557d5a49 (patch) | |
tree | dac4cab1e761330d6b61f4347a48c5c6051ca1e1 /src/interactive | |
parent | 115e8b4492851137ad2b5b61b9bf78bb51601dff (diff) | |
download | scala-3cb3c8e35c3df31a7f661903eca48cca557d5a49.tar.gz scala-3cb3c8e35c3df31a7f661903eca48cca557d5a49.tar.bz2 scala-3cb3c8e35c3df31a7f661903eca48cca557d5a49.zip |
Address TODOs around SymbolLoaders and SymbolTable.
SymbolTable refactoring introduced some TODOs that were supposed
to be addressed after M5 release. The reason I couldn't address
those problems right away was a conflict with our plans to modularize
Scaladoc and interactive. However, we decided to delay that work
until after M5 is released so addressing TODOs is not blocked
anymore.
This commit introduces the following changes:
* Eclipse project definitions for interactive and scaladoc
depend on scala-compiler project so they are builded against
latest version of the compiler (quick) instead of STARR.
This aligns our Eclipse project definitions with build.xml
structure.
* Introduce GlobalSymbolLoaders class which wires dependencies
of SymbolLoaders with assumption of dependency on Global.
* Switch to GlobalSymbolLoaders in BrowsingLoaders,
interactive Global and ScaladocGlobal; this eliminates all
TODO comments introduced before
Diffstat (limited to 'src/interactive')
-rw-r--r-- | src/interactive/scala/tools/nsc/interactive/Global.scala | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/src/interactive/scala/tools/nsc/interactive/Global.scala b/src/interactive/scala/tools/nsc/interactive/Global.scala index cfe6d57eb8..492f0f4fb4 100644 --- a/src/interactive/scala/tools/nsc/interactive/Global.scala +++ b/src/interactive/scala/tools/nsc/interactive/Global.scala @@ -365,20 +365,16 @@ class Global(settings: Settings, _reporter: Reporter, projectName: String = "") */ override def registerTopLevelSym(sym: Symbol) { currentTopLevelSyms += sym } + protected type SymbolLoadersInInteractive = GlobalSymbolLoaders { + val global: Global.this.type + val platform: Global.this.platform.type + } /** Symbol loaders in the IDE parse all source files loaded from a package for * top-level idents. Therefore, we can detect top-level symbols that have a name * different from their source file */ - protected type SymbolLoadersInInteractive = SymbolLoaders { - // `global` val is needed so we conform to loaders type in Global in Scala 2.11.0-M4 - // TODO: remove once 2.11.0-M5 is used to build interactive - val global: Global.this.type - val symbolTable: Global.this.type - val platform: Global.this.platform.type - } override lazy val loaders: SymbolLoadersInInteractive = new { val global: Global.this.type = Global.this - val symbolTable: Global.this.type = Global.this val platform: Global.this.platform.type = Global.this.platform } with BrowsingLoaders |