2023-03-20 14:13:34 +00:00
|
|
|
|
|
|
|
// Assert implementation
|
|
|
|
// args: [condition, str_len, str_ptr]
|
|
|
|
// @arg condition: Bool
|
|
|
|
// @arg str_len: Int
|
|
|
|
// @arg str_ptr: Ptr
|
|
|
|
// @ret NULL/NEVER
|
2023-04-12 21:34:08 +00:00
|
|
|
fn assert with bool int ptr returns void then
|
2023-03-20 14:13:34 +00:00
|
|
|
rot
|
|
|
|
if else
|
|
|
|
"Assert failed: \"" eputs eputs
|
|
|
|
"\". Exiting!\n" eputs
|
|
|
|
1 exit
|
|
|
|
end
|
2023-04-12 21:34:08 +00:00
|
|
|
done
|