Implement nova64 API with native yield function and registration
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
extern "nova64" fn yield(timeout_ms: u32) void;
|
||||
|
||||
pub fn main() void {
|
||||
_ = add(1, 2);
|
||||
while (true) {
|
||||
yield(16); // Yield for 1 second
|
||||
}
|
||||
}
|
||||
|
||||
export fn add(a: i32, b: i32) i32 {
|
||||
return a + b;
|
||||
}
|
||||
Reference in New Issue
Block a user