llvm-as: crash01.ll:1:9: invalid function return type
declare opaque @t()
^
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61678
91177308-0d34-0410-b5e6-
96231b3b80d8
return Error(LinkageLoc, "invalid function linkage type");
}
- if (!FunctionType::isValidReturnType(RetType))
+ if (!FunctionType::isValidReturnType(RetType) ||
+ isa<OpaqueType>(RetType))
return Error(RetTypeLoc, "invalid function return type");
if (Lex.getKind() != lltok::GlobalVar)