xo-procedure2: + type_ member [WIP]

This commit is contained in:
Roland Conybeare 2026-03-12 20:43:14 -05:00
commit 337835409a
3 changed files with 14 additions and 1 deletions

View file

@ -40,6 +40,9 @@ namespace xo {
/* struct<a:T,b:U,..> */
t_struct,
/* any numeric type: i16|i32|i64|f32|f64 */
t_numeric,
/* any type at all */
t_any,
};
@ -64,6 +67,7 @@ namespace xo {
static Metatype t_function() { return Metatype(code::t_function); }
static Metatype t_struct() { return Metatype(code::t_struct); }
static Metatype t_numeric() { return Metatype(code::t_numeric); }
static Metatype t_any() { return Metatype(code::t_any); }
/** description string for this type category **/

View file

@ -29,6 +29,7 @@ namespace xo {
case code::t_function: return "function";
case code::t_struct: return "struct";
case code::t_numeric: return "numeric";
case code::t_any: return "any";
}
}
@ -68,6 +69,8 @@ namespace xo {
case code::t_struct:
return false;
case code::t_numeric:
return true;
case code::t_any:
return true;
}