diff options
| author | gingerBill <bill@gingerbill.org> | 2019-08-31 20:13:28 +0100 |
|---|---|---|
| committer | gingerBill <bill@gingerbill.org> | 2019-08-31 20:13:28 +0100 |
| commit | b9d3129fb3a4ba7ef49cea69d086a7f705819f2e (patch) | |
| tree | d985a8be38dc2bbf05ea13d13e700ab5074b87ed /src/checker.cpp | |
| parent | b311540b1672129e87a7249650a19cf11d2fccef (diff) | |
`where` clauses for procedure literals
Diffstat (limited to 'src/checker.cpp')
| -rw-r--r-- | src/checker.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/checker.cpp b/src/checker.cpp index b00b4bbac..8fe71b63c 100644 --- a/src/checker.cpp +++ b/src/checker.cpp @@ -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; |