Browse Source

frontend/define.c, ntharg(), #4/15 express some facts

pre-master-46
rlar 11 years ago
parent
commit
f538b4dba3
  1. 2
      src/frontend/define.c

2
src/frontend/define.c

@ -407,8 +407,10 @@ trcopy(struct pnode *tree, char *args, struct pnode *nn)
static struct pnode * static struct pnode *
ntharg(int num, struct pnode *args) ntharg(int num, struct pnode *args)
{ {
// fact: num >= 1 for all known invocations of ntharg()
while (--num > 0) { while (--num > 0) {
if (args && args->pn_op && (args->pn_op->op_num != PT_OP_COMMA)) { if (args && args->pn_op && (args->pn_op->op_num != PT_OP_COMMA)) {
// fact: num >= 1 because of `while' condition
if (num == 1) if (num == 1)
break; break;
return NULL; return NULL;

Loading…
Cancel
Save