#include "defs.h" prchips(chp) CHP chp; { REG SIG s; REG CHP c=chp; while(c) { TAG t=c->c_type; c_chip=c; c_type=t; if(t==nil(TAG)) { errmsg("chip type not defined", "\n"); } elif((t->val)!=nil(TAG)) { TAG chp; STRING cn; cn=c->c_tag->tc; chp=find(cn, LCHP); notnil(chp); c_type=c->c_type; s=c->c_sig; if(chp) { while(s) { xprod(s,chp); s=s->s_next; } } } if(c->c_bdx) { print(".c %s\n", c->c_tag->tc); print(".c%c", (c->c_bdx==SOFT ? 's' : 'h')); print(" %d\n", c->c_bdp); } c=c->c_next; } /* scan for macros */ c=chp; while(c) { TAG t=c->c_type; c_chip=c; c_type=t; if((t!=nil(TAG)) && ((t->val)==nil(TAG))) { /* process file */ TAG save=t->nxt; if(save==nil(TAG)) { errmsg(t->tc, "called recursively\n"); } else { expand(c); } t->nxt=save; } c=c->c_next; } } TAG follow(t) TAG t; { if(t->val) return(t->val); else return(t); }