diff options
author | Jason Zaugg <jzaugg@gmail.com> | 2013-11-07 07:30:24 -0800 |
---|---|---|
committer | Jason Zaugg <jzaugg@gmail.com> | 2013-11-07 07:30:24 -0800 |
commit | 877bef66e8644247933218d53c27b2b87beb97a9 (patch) | |
tree | 26dff219adb47d0c2a273779500b71fc2c16abe6 /src | |
parent | 8e1f8a9dcb50cbd596281f459576908fa68dad07 (diff) | |
parent | 1ef0edfc23b11f92b8c182d1811c0361f14e6581 (diff) | |
download | scala-async-877bef66e8644247933218d53c27b2b87beb97a9.tar.gz scala-async-877bef66e8644247933218d53c27b2b87beb97a9.tar.bz2 scala-async-877bef66e8644247933218d53c27b2b87beb97a9.zip |
Merge pull request #38 from phaller/topic/cleanup-cps-fallbackv0.9.0-M2
Remove left-overs of CPS fallback logic
Diffstat (limited to 'src')
-rw-r--r-- | src/main/scala/scala/async/internal/AsyncBase.scala | 6 | ||||
-rw-r--r-- | src/main/scala/scala/async/internal/AsyncTransform.scala | 2 |
2 files changed, 3 insertions, 5 deletions
diff --git a/src/main/scala/scala/async/internal/AsyncBase.scala b/src/main/scala/scala/async/internal/AsyncBase.scala index 89d5a4d..8cacb40 100644 --- a/src/main/scala/scala/async/internal/AsyncBase.scala +++ b/src/main/scala/scala/async/internal/AsyncBase.scala @@ -39,8 +39,6 @@ abstract class AsyncBase { @compileTimeOnly("`await` must be enclosed in an `async` block") def await[T](awaitable: futureSystem.Fut[T]): T = ??? - protected[async] def fallbackEnabled = false - def asyncImpl[T: c.WeakTypeTag](c: Context) (body: c.Expr[T]) (execContext: c.Expr[futureSystem.ExecContext]): c.Expr[futureSystem.Fut[T]] = { @@ -50,8 +48,8 @@ abstract class AsyncBase { val code = asyncMacro.asyncTransform[T]( body.tree.asInstanceOf[asyncMacro.global.Tree], - execContext.tree.asInstanceOf[asyncMacro.global.Tree], - fallbackEnabled)(implicitly[c.WeakTypeTag[T]].asInstanceOf[asyncMacro.global.WeakTypeTag[T]]).asInstanceOf[Tree] + execContext.tree.asInstanceOf[asyncMacro.global.Tree] + )(implicitly[c.WeakTypeTag[T]].asInstanceOf[asyncMacro.global.WeakTypeTag[T]]).asInstanceOf[Tree] // Mark range positions for synthetic code as transparent to allow some wiggle room for overlapping ranges for (t <- code) diff --git a/src/main/scala/scala/async/internal/AsyncTransform.scala b/src/main/scala/scala/async/internal/AsyncTransform.scala index d27b4b8..9003b0b 100644 --- a/src/main/scala/scala/async/internal/AsyncTransform.scala +++ b/src/main/scala/scala/async/internal/AsyncTransform.scala @@ -7,7 +7,7 @@ trait AsyncTransform { val asyncBase: AsyncBase - def asyncTransform[T](body: Tree, execContext: Tree, cpsFallbackEnabled: Boolean) + def asyncTransform[T](body: Tree, execContext: Tree) (resultType: WeakTypeTag[T]): Tree = { // We annotate the type of the whole expression as `T @uncheckedBounds` so as not to introduce |