1 cananian 1.1.2.4 // PreciselyTyped.java, created Wed Aug 11 16:03:47 1999 by duncan 2 cananian 1.1.2.4 // Copyright (C) 1998 C. Scott Ananian <cananian@alumni.princeton.edu> 3 cananian 1.1.2.4 // Licensed under the terms of the GNU GPL; see COPYING for details. 4 duncan 1.1.2.1 package harpoon.IR.Tree; 5 duncan 1.1.2.1 6 duncan 1.1.2.1 /** 7 duncan 1.1.2.1 * The <code>PreciselyTyped</code> interface allows access to type 8 duncan 1.1.2.1 * information for expressions which have a type which cannot be expressed 9 duncan 1.1.2.1 * by the standard types in the <code>Typed</code> interface. 10 cananian 1.1.2.3 * Only <code>CONST</code>, <code>MEM</code>, and <code>ESEQ</code> implement 11 cananian 1.1.2.2 * <code>PreciselyTyped</code>. All other <code>Tree.Exp</code>s deal 12 cananian 1.1.2.2 * with register-native types. 13 duncan 1.1.2.1 * 14 duncan 1.1.2.1 * @author C. Scott Ananian <cananian@alumni.princeton.edu> 15 cananian 1.1.2.5 * @author Duncan Bryce <duncan@lcs.mit.edu> 16 cananian 1.2 * @version $Id: PreciselyTyped.java,v 1.2 2002/02/25 21:05:40 cananian Exp $ 17 duncan 1.1.2.1 */ 18 duncan 1.1.2.1 public interface PreciselyTyped extends Typed { 19 cananian 1.1.2.3 /** Returns <code>true</code> if this expression is a small type, 20 cananian 1.1.2.3 * <code>false</code> otherwise. */ 21 cananian 1.1.2.3 public boolean isSmall(); 22 cananian 1.1.2.2 23 cananian 1.1.2.2 /** Returns the size of the expression, in bits. 24 cananian 1.1.2.3 * Only valid if the <code>isSmall()==true</code>. */ 25 duncan 1.1.2.1 public int bitwidth(); 26 duncan 1.1.2.1 27 cananian 1.1.2.2 /** Returns true if this is a signed expression, false otherwise. 28 cananian 1.1.2.3 * Only valid if the <code>isSmall()==true</code>. */ 29 duncan 1.1.2.1 public boolean signed(); 30 cananian 1.2 }