MPS issue job003691

TitleCHECKL is used where CHECKD_NOSIG would give more control
Statusclosed
Prioritynice
Assigned userRichard Brooksby
OrganizationRavenbrook
DescriptionMPS check methods often do CHECKL(FooCheck(foo)) because FooStruct doesn't have a sig. In this case they ought to be using CHECKD_NOSIG(Foo, foo).
AnalysisGlobal replace and clean-up.
Consider defining a macro along with FooStruct so that the call-sites don't have to know.
Also consider whether something similar is needed for AVERT.
How foundinspection
Evidence"Review of mps/branch/2014-02-22/splay-tune" <https://info.ravenbrook.com/mail/2014/03/07/18-03-14/0/>
Created byRichard Brooksby
Created on2014-03-11 12:52:29
Last modified byGareth Rees
Last modified on2014-04-06 22:51:21
History2014-03-11 RB Created.

Fixes

Change Effect Date User Description
185263 closed 2014-04-06 22:51:05 Gareth Rees Improve control over checking:
1. Where Type is a pointer type with a signature, replace CHECKL(TypeCheck(val)) with CHECKD(Type, val).
2. Where Type is a pointer type with no signature, replace CHECKL(TypeCheck(val)) with CHECKD_NOSIG(Type, val).
3. Where Type is a pointer type with a signature, but the structure is not visible at point of checking, replace CHECKL(TypeCheck(val)) with CHECKD_NOSIG(Type, val). Reference <design/check/#.hidden-type>
4. Make BTCheck extern and use it where possible.
5. Replace AVER(TypeCheck(val)) with AVERT(Type, val).