diff options
author | Den Shabalin <den.shabalin@gmail.com> | 2013-09-20 13:32:38 +0200 |
---|---|---|
committer | Den Shabalin <den.shabalin@gmail.com> | 2013-10-14 13:30:49 +0200 |
commit | 3a148cd0cd404751095cd1c5aca09ad8923c51ab (patch) | |
tree | 2ad3cbc115fe0ca270d476171b41519c483ba201 /src/compiler/scala/reflect/macros/contexts/Parsers.scala | |
parent | d7aae49f8ff7ccc6c1a588fc116e8c37fdb9e849 (diff) | |
download | scala-3a148cd0cd404751095cd1c5aca09ad8923c51ab.tar.gz scala-3a148cd0cd404751095cd1c5aca09ad8923c51ab.tar.bz2 scala-3a148cd0cd404751095cd1c5aca09ad8923c51ab.zip |
SI-6841 SI-6657 add support for packages into quasiquotes and toolbox
In order to implement this a new parser entry point
`parseStatsOrPackages` that augments current parseStats with ability
to parse "package name { ... }" syntax.
Diffstat (limited to 'src/compiler/scala/reflect/macros/contexts/Parsers.scala')
-rw-r--r-- | src/compiler/scala/reflect/macros/contexts/Parsers.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/compiler/scala/reflect/macros/contexts/Parsers.scala b/src/compiler/scala/reflect/macros/contexts/Parsers.scala index ae6488b5a8..88cfea8157 100644 --- a/src/compiler/scala/reflect/macros/contexts/Parsers.scala +++ b/src/compiler/scala/reflect/macros/contexts/Parsers.scala @@ -11,7 +11,7 @@ trait Parsers { val sreporter = new StoreReporter() val unit = new CompilationUnit(newSourceFile(code, "<macro>")) { override def reporter = sreporter } val parser = newUnitParser(unit) - val tree = gen.mkTreeOrBlock(parser.parseStats()) + val tree = gen.mkTreeOrBlock(parser.parseStatsOrPackages()) sreporter.infos.foreach { case sreporter.Info(pos, msg, sreporter.ERROR) => throw ParseException(pos, msg) } |