We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 46bef71 + 1846ad5 commit 3023ceeCopy full SHA for 3023cee
compiler/src/dotty/tools/dotc/core/Types.scala
@@ -2276,11 +2276,13 @@ object Types {
2276
2277
protected def resultSignature(implicit ctx: Context) = try resultType match {
2278
case rtp: MethodicType => rtp.signature
2279
- case tp => Signature(tp, isJava = false)
+ case tp =>
2280
+ if (tp.isRef(defn.UnitClass)) Signature(Nil, defn.UnitClass.fullName.asTypeName)
2281
+ else Signature(tp, isJava = false)
2282
}
2283
catch {
2284
case ex: AssertionError =>
- println(i"failure while taking result signture of $this: $resultType")
2285
+ println(i"failure while taking result signature of $this: $resultType")
2286
throw ex
2287
2288
0 commit comments