mirror of
https://github.com/odin-lang/Odin.git
synced 2026-02-18 00:48:23 +00:00
Make diverging procedure types different from ones without a return type
This commit is contained in:
@@ -1213,7 +1213,7 @@ void check_stmt_internal(CheckerContext *ctx, Ast *node, u32 flags) {
|
||||
GB_ASSERT(proc_type->kind == Type_Proc);
|
||||
// Type *proc_type = c->proc_stack[c->proc_stack.count-1];
|
||||
TypeProc *pt = &proc_type->Proc;
|
||||
if (pt->no_return) {
|
||||
if (pt->diverging) {
|
||||
error(rs->token, "Diverging procedures may not return");
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user