aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/core/Signature.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2014-08-20 11:37:51 +0200
committerMartin Odersky <odersky@gmail.com>2014-08-20 11:37:51 +0200
commitb10c590c59938576e7f27718fff245ea9ffe0629 (patch)
tree2e206d2b7bb03c6fabd73b3ff6cd8355db79f38a /src/dotty/tools/dotc/core/Signature.scala
parent65aa10526340bc618bdba71a4cd5616e8a185715 (diff)
downloaddotty-b10c590c59938576e7f27718fff245ea9ffe0629.tar.gz
dotty-b10c590c59938576e7f27718fff245ea9ffe0629.tar.bz2
dotty-b10c590c59938576e7f27718fff245ea9ffe0629.zip
Fix signature of by-name parameters.
Diffstat (limited to 'src/dotty/tools/dotc/core/Signature.scala')
-rw-r--r--src/dotty/tools/dotc/core/Signature.scala4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/dotty/tools/dotc/core/Signature.scala b/src/dotty/tools/dotc/core/Signature.scala
index 22d038d11..7bee51106 100644
--- a/src/dotty/tools/dotc/core/Signature.scala
+++ b/src/dotty/tools/dotc/core/Signature.scala
@@ -55,6 +55,8 @@ object Signature {
val OverloadedSignature = Signature(List(tpnme.OVERLOADED), EmptyTypeName)
/** The signature of a method with no parameters and result type `resultType`. */
- def apply(resultType: Type, isJava: Boolean)(implicit ctx: Context): Signature =
+ def apply(resultType: Type, isJava: Boolean)(implicit ctx: Context): Signature = {
+ assert(!resultType.isInstanceOf[ExprType])
apply(Nil, sigName(resultType, isJava))
+ }
} \ No newline at end of file