selfhost: for-in support for Channel<T>; fix break/continue C codegen
- lib/Channel.bux: add Channel_Recv_Ok<T> for use in for-in desugaring - hir_lower.bux: Channel for-in desugars to while+recv_ok pattern - c_backend.bux: emit 'break;' / 'continue;' with semicolon, fix missing semicolon when break/continue inside if-block - bootstrap/hir_lower.nim: skip generic methods in vtable generation to avoid referencing non-existent monomorphized C functions
This commit is contained in:
@@ -1717,6 +1717,9 @@ proc lowerModule*(module: Module, sema: Sema): HirModule =
|
||||
var found = false
|
||||
for avail in methods:
|
||||
if avail.name == req.declFuncName:
|
||||
# Skip generic methods — they have no concrete C function to put in vtable
|
||||
if avail.decl.declFuncTypeParams.len > 0:
|
||||
break
|
||||
found = true
|
||||
methodNames.add(req.declFuncName)
|
||||
break
|
||||
|
||||
Reference in New Issue
Block a user