static typeId ctbase_typeId (ctbase p_c);
static /*@only@*/ cstring ctbase_dump (ctbase p_c);
-static /*@only@*/ ctbase ctbase_undump (char **p_c);
+static /*@only@*/ ctbase ctbase_undump (char **p_c) /*@requires maxRead(*p_c) >= 2 @*/;
static int ctbase_compare (ctbase p_c1, ctbase p_c2, bool p_strict);
static bool ctbase_matchArg (ctbase p_c1, ctbase p_c2);
static /*@notnull@*/ /*@only@*/ ctbase
return (message ("%t *", c->contents.base));
}
case CT_FIXEDARRAY:
- return (message ("%t [%d]", c->contents.farray->base,
+ return (message ("%t [%d]",
+ c->contents.farray->base,
(int) c->contents.farray->size));
case CT_ARRAY:
return (message ("%t []", c->contents.base));
BADEXIT;
}
-static ctbase ctbase_undump (d_char *c)
+static ctbase ctbase_undump (d_char *c) /*@requires maxRead(*c) >= 2 @*/
{
ctbase res;
char p = **c;
llerror (FLG_SYNTAX,
message ("Bad Library line (type): %s", cstring_fromChars (*c)));
- while (**c != '\0')
+ /*drl bee: pbr*/ while (**c != '\0')
{
(*c)++;
}
long int ctbase_getArraySize (ctbase ctb)
{
- llassert (ctbase_isDefined (ctb) );
+ /*drl 1/25/2002 fixed discover by Jim Francis */
+ ctbase r;
+
- llassert (ctbase_isFixedArray(ctb) );
+ llassert (ctbase_isDefined (ctb) );
+ r = ctbase_realType (ctb);
+ llassert (ctbase_isFixedArray(r) );
+
- return (ctb->contents.farray->size);
+
+ return (r->contents.farray->size);
}