where clauses for procedure literals

This commit is contained in:
gingerBill
2019-08-31 20:13:28 +01:00
parent b311540b16
commit b9d3129fb3
10 changed files with 272 additions and 24 deletions

View File

@@ -3697,6 +3697,14 @@ void check_proc_info(Checker *c, ProcInfo pi) {
return;
}
if (pt->is_polymorphic && pt->is_poly_specialized) {
Entity *e = pi.decl->entity;
if ((e->flags & EntityFlag_Used) == 0) {
// NOTE(bill, 2019-08-31): It was never used, don't check
return;
}
}
bool bounds_check = (pi.tags & ProcTag_bounds_check) != 0;
bool no_bounds_check = (pi.tags & ProcTag_no_bounds_check) != 0;