harpoon.IR.Tree
Class ExpList

java.lang.Object
  extended by harpoon.IR.Tree.ExpList

public final class ExpList
extends Object

ExpLists form singly-linked lists of Exps.

Version:
$Id: ExpList.java,v 1.4 2004/02/08 01:55:51 cananian Exp $
Author:
C. Scott Ananian <cananian@alumni.princeton.edu>, based on Modern Compiler Implementation in Java by Andrew Appel.

Field Summary
 Exp head
          The expression at this list entry.
 ExpList tail
          The next list entry.
 
Constructor Summary
ExpList(Exp head, ExpList tail)
          List constructor.
 
Method Summary
static Iterator iterator(ExpList el)
          FSK: didn't use standard JDK instance-local iterators because ExpLists are allowed to be null, and so such a definition would encourage attempted method-calls on null.
static ExpList rename(ExpList e, TreeFactory tf, TempMap tm, Tree.CloneCallback cb)
           
static ExpList replace(ExpList e, Exp eOld, Exp eNew)
           
static int size(ExpList e)
           
static ExpList toExpList(List list)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

head

public final Exp head
The expression at this list entry.


tail

public final ExpList tail
The next list entry.

Constructor Detail

ExpList

public ExpList(Exp head,
               ExpList tail)
List constructor.

Method Detail

toExpList

public static ExpList toExpList(List list)

iterator

public static Iterator iterator(ExpList el)
FSK: didn't use standard JDK instance-local iterators because ExpLists are allowed to be null, and so such a definition would encourage attempted method-calls on null.


size

public static int size(ExpList e)

replace

public static ExpList replace(ExpList e,
                              Exp eOld,
                              Exp eNew)

rename

public static ExpList rename(ExpList e,
                             TreeFactory tf,
                             TempMap tm,
                             Tree.CloneCallback cb)

toString

public String toString()
Overrides:
toString in class Object