diff options
author | Martin Odersky <odersky@gmail.com> | 2013-06-18 19:38:09 +0200 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2013-06-18 19:38:09 +0200 |
commit | f8a42a0584d855a0548c20c7434ed83a59647ed9 (patch) | |
tree | 9bdb1b8367d5a692cbf26003e6b10b6122a8d03b /src/dotty/tools/dotc/core/Contexts.scala | |
parent | 3c7936515a9aaf383b453fe5844598fd53a2e551 (diff) | |
download | dotty-f8a42a0584d855a0548c20c7434ed83a59647ed9.tar.gz dotty-f8a42a0584d855a0548c20c7434ed83a59647ed9.tar.bz2 dotty-f8a42a0584d855a0548c20c7434ed83a59647ed9.zip |
Added typedIdent method.
Also some refactorings that were caused by adding this method.
Diffstat (limited to 'src/dotty/tools/dotc/core/Contexts.scala')
-rw-r--r-- | src/dotty/tools/dotc/core/Contexts.scala | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/dotty/tools/dotc/core/Contexts.scala b/src/dotty/tools/dotc/core/Contexts.scala index 588c18c4c..874f28bce 100644 --- a/src/dotty/tools/dotc/core/Contexts.scala +++ b/src/dotty/tools/dotc/core/Contexts.scala @@ -138,10 +138,10 @@ object Contexts { protected def typer_=(typer: Typer) = _typer = typer def typer: Typer = _typer - /** The currently visible imports */ - private[this] var _imports: List[ImportInfo] = _ - protected def imports_=(imports: List[ImportInfo]) = _imports = imports - def imports: List[ImportInfo] = _imports + /** The currently active import info */ + private[this] var _importInfo: ImportInfo = _ + protected def importInfo_=(importInfo: ImportInfo) = _importInfo = importInfo + def importInfo: ImportInfo = _importInfo /** The current reporter */ private[this] var _reporter: Reporter = _ @@ -263,7 +263,7 @@ object Contexts { def withScope(scope: Scope): this.type = { this.scope = scope; this } def withNewScope: this.type = { this.scope = newScope; this } def withTyper(typer: Typer): this.type = { this.typer = typer; this.scope = typer.scope; this } - def withImport(importInfo: ImportInfo): this.type = { this.imports = importInfo :: imports; this } + def withImportInfo(importInfo: ImportInfo): this.type = { this.importInfo = importInfo; this } def withReporter(reporter: Reporter): this.type = { this.reporter = reporter; this } def withDiagnostics(diagnostics: Option[StringBuilder]): this.type = { this.diagnostics = diagnostics; this } def withMoreProperties(moreProperties: Map[String, Any]): this.type = { this.moreProperties = moreProperties; this } |