mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-05 23:28:48 +00:00
Add extra message to assert
This commit is contained in:
@@ -2081,7 +2081,8 @@ void lb_build_stmt(lbProcedure *p, Ast *node) {
|
|||||||
Ast *name = vd->names[i];
|
Ast *name = vd->names[i];
|
||||||
if (!is_blank_ident(name)) {
|
if (!is_blank_ident(name)) {
|
||||||
Entity *e = entity_of_node(name);
|
Entity *e = entity_of_node(name);
|
||||||
GB_ASSERT(e != nullptr);
|
TokenPos pos = ast_token(name).pos;
|
||||||
|
GB_ASSERT_MSG(e != nullptr, "%s", token_pos_to_string(pos));
|
||||||
if (e->flags & EntityFlag_Static) {
|
if (e->flags & EntityFlag_Static) {
|
||||||
// NOTE(bill): If one of the entities is static, they all are
|
// NOTE(bill): If one of the entities is static, they all are
|
||||||
is_static = true;
|
is_static = true;
|
||||||
|
|||||||
Reference in New Issue
Block a user