@@ -20,9 +20,8 @@ sz argc; char** argv; kvar* vars; } kenv; - /* i'm really sorry okay */ typedef #if (__STDC_VERSION__ >= 199901L) _Bool bool; @@ -40,8 +39,10 @@ #endif ; #ifndef KFclean +# include +# define Kokay(cond) (((cond) % kglobal_module_offset) == 0) # if (__STDC_VERSION__ >= 199901L) ||\ (__cplusplus >= 201103L) # define KVvm_args __VA_ARGS__ # define KVvm_spec ... @@ -145,10 +146,21 @@ _Noreturn void kstop(stat_long code); #else void kstop(stat_long code); #endif + +typedef u16 kcond; +/* this will probably not need to be altered, + * as libk sports a modest number of modules, + * and there are few enough error conditions + * in each that 16-bit address space should + * be more than enough for the foreseeable + * future. however if that changes, altering + * the definition here will effect all the + * necessary changes throughout the library */ +bool kokay(kcond); #ifdef __cplusplus } #endif #endif