mirror of
https://github.com/ziglang/zig.git
synced 2025-12-16 03:03:09 +00:00
this was intended to be included in the previous commit
This commit is contained in:
parent
526d8425ab
commit
2f2215c9f4
@ -1680,14 +1680,6 @@ static TypeTableEntry *analyze_fn_type(CodeGen *g, AstNode *proto_node, Scope *c
|
|||||||
case TypeTableEntryIdBlock:
|
case TypeTableEntryIdBlock:
|
||||||
case TypeTableEntryIdBoundFn:
|
case TypeTableEntryIdBoundFn:
|
||||||
case TypeTableEntryIdMetaType:
|
case TypeTableEntryIdMetaType:
|
||||||
if (!calling_convention_allows_zig_types(fn_type_id.cc)) {
|
|
||||||
add_node_error(g, fn_proto->return_type,
|
|
||||||
buf_sprintf("return type '%s' not allowed in function with calling convention '%s'",
|
|
||||||
buf_ptr(&fn_type_id.return_type->name),
|
|
||||||
calling_convention_name(fn_type_id.cc)));
|
|
||||||
return g->builtin_types.entry_invalid;
|
|
||||||
}
|
|
||||||
return get_generic_fn_type(g, &fn_type_id);
|
|
||||||
case TypeTableEntryIdUnreachable:
|
case TypeTableEntryIdUnreachable:
|
||||||
case TypeTableEntryIdVoid:
|
case TypeTableEntryIdVoid:
|
||||||
case TypeTableEntryIdBool:
|
case TypeTableEntryIdBool:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user