summaryrefslogtreecommitdiff
path: root/docs/examples/plugintemplate/src/plugintemplate/standalone/PluginRunner.scala
diff options
context:
space:
mode:
Diffstat (limited to 'docs/examples/plugintemplate/src/plugintemplate/standalone/PluginRunner.scala')
-rw-r--r--docs/examples/plugintemplate/src/plugintemplate/standalone/PluginRunner.scala36
1 files changed, 0 insertions, 36 deletions
diff --git a/docs/examples/plugintemplate/src/plugintemplate/standalone/PluginRunner.scala b/docs/examples/plugintemplate/src/plugintemplate/standalone/PluginRunner.scala
deleted file mode 100644
index 06fe669cbd..0000000000
--- a/docs/examples/plugintemplate/src/plugintemplate/standalone/PluginRunner.scala
+++ /dev/null
@@ -1,36 +0,0 @@
-package plugintemplate.standalone
-
-import plugintemplate.{TemplateAnnotationChecker, TemplatePlugin}
-import scala.tools.nsc.{Global, Settings, SubComponent}
-import scala.tools.nsc.reporters.{ConsoleReporter, Reporter}
-
-/** This class is a compiler that will be used for running
- * the plugin in standalone mode.
- */
-class PluginRunner(settings: Settings, reporter: Reporter)
-extends Global(settings, reporter) {
- def this(settings: Settings) = this(settings, new ConsoleReporter(settings))
-
- val annotChecker = new TemplateAnnotationChecker {
- val global: PluginRunner.this.type = PluginRunner.this
- }
- addAnnotationChecker(annotChecker.checker)
-
- /** The phases to be run.
- *
- * @todo: Adapt to specific plugin implementation
- */
- override protected def computeInternalPhases() {
- phasesSet += syntaxAnalyzer
- phasesSet += analyzer.namerFactory
- phasesSet += analyzer.typerFactory
- phasesSet += superAccessors // add super accessors
- phasesSet += pickler // serialize symbol tables
- phasesSet += refChecks // perform reference and override checking, translate nested objects
-
- for (phase <- TemplatePlugin.components(this)) {
- phasesSet += phase
- }
- }
-
-}