1.1 --- a/src/SemanticAnalysis.cpp Sun Jul 29 18:02:13 2012 -0700
1.2 +++ b/src/SemanticAnalysis.cpp Sun Jul 29 18:19:12 2012 -0700
1.3 @@ -717,10 +717,14 @@
1.4 }
1.5
1.6 Local<Type> returnType(zone_);
1.7 - if (node->hasExplicitReturn() || node->fun()->isNative())
1.8 + if (node->returnTag()) {
1.9 + Local<String> tag(zone_, node->returnTag());
1.10 + returnType = zone_->types()->getPrimitiveForTag(tag);
1.11 + } else if (node->hasExplicitReturn() || node->fun()->isNative()) {
1.12 returnType = zone_->types()->getPrimitive(PrimitiveType_Int32);
1.13 - else
1.14 + } else {
1.15 returnType = zone_->types()->getVoid();
1.16 + }
1.17 if (!returnType)
1.18 return false;
1.19