mirror of
https://github.com/Ed94/Odin.git
synced 2026-07-31 11:50:07 +00:00
Remove print(ln) and fix swizzle
This commit is contained in:
@@ -124,8 +124,6 @@ enum BuiltinProcId {
|
||||
BuiltinProc_copy,
|
||||
BuiltinProc_append,
|
||||
BuiltinProc_swizzle,
|
||||
BuiltinProc_print,
|
||||
BuiltinProc_println,
|
||||
|
||||
BuiltinProc_Count,
|
||||
};
|
||||
@@ -152,10 +150,6 @@ gb_global BuiltinProc builtin_procs[BuiltinProc_Count] = {
|
||||
{STR_LIT("append"), 2, false, Expression_Expression},
|
||||
|
||||
{STR_LIT("swizzle"), 1, true, Expression_Expression},
|
||||
|
||||
{STR_LIT("print"), 1, true, Expression_Statement},
|
||||
{STR_LIT("println"), 1, true, Expression_Statement},
|
||||
|
||||
};
|
||||
|
||||
struct CheckerContext {
|
||||
|
||||
@@ -1470,7 +1470,6 @@ b32 check_builtin_procedure(Checker *c, Operand *operand, AstNode *call, i32 id)
|
||||
|
||||
case BuiltinProc_static_assert:
|
||||
// static_assert :: proc(cond: bool)
|
||||
// TODO(bill): Should `static_assert` and `assert` be unified?
|
||||
|
||||
if (operand->mode != Addressing_Constant ||
|
||||
!is_type_boolean(operand->type)) {
|
||||
@@ -1663,17 +1662,6 @@ b32 check_builtin_procedure(Checker *c, Operand *operand, AstNode *call, i32 id)
|
||||
Type *elem_type = vector_type->vector.elem;
|
||||
operand->type = make_type_vector(c->allocator, elem_type, arg_count);
|
||||
operand->mode = Addressing_Value;
|
||||
}
|
||||
|
||||
case BuiltinProc_print:
|
||||
case BuiltinProc_println: {
|
||||
for (AstNode *arg = ce->arg_list; arg != NULL; arg = arg->next) {
|
||||
// TOOD(bill): `check_assignment` doesn't allow tuples at the moment, should it?
|
||||
// Or should we destruct the tuple and use each elem?
|
||||
check_assignment(c, operand, NULL, make_string("argument"));
|
||||
if (operand->mode == Addressing_Invalid)
|
||||
return false;
|
||||
}
|
||||
} break;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user