home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / E / TFF-A32R.LZX / AmigaE3.2a / Src / Tools / Constructors / constructors.e < prev    next >
Encoding:
Text File  |  1992-09-02  |  378 b   |  23 lines

  1. -> various constructors module
  2.  
  3. OPT MODULE
  4. OPT EXPORT
  5.  
  6. MODULE 'exec/lists', 'exec/nodes'
  7.  
  8. PROC newlist(lh=NIL:PTR TO lh,type=0)
  9.   IF lh=NIL THEN lh:=NEW lh
  10.   lh.head:=lh+4
  11.   lh.tailpred:=lh
  12.   lh.tail:=0
  13.   lh.type:=0
  14.   lh.pad:=0
  15. ENDPROC lh
  16.  
  17. PROC newnode(ln=NIL:PTR TO ln,name=NIL,type=0,pri=0)
  18.   IF ln=NIL THEN ln:=NEW ln
  19.   ln.name:=name
  20.   ln.pri:=pri
  21.   ln.type:=type
  22. ENDPROC ln
  23.