1 pnkfelix 1.1.2.1 // HTempMap.java, created Mon Aug 21 20:02:09 2000 by pnkfelix 2 cananian 1.1.2.2 // Copyright (C) 2000 Felix S. Klock II <pnkfelix@mit.edu> 3 pnkfelix 1.1.2.1 // Licensed under the terms of the GNU GPL; see COPYING for details. 4 pnkfelix 1.1.2.1 package harpoon.Analysis.Instr; 5 pnkfelix 1.1.2.1 6 cananian 1.3 import net.cscott.jutil.GenericInvertibleMap; 7 pnkfelix 1.1.2.1 import harpoon.Temp.TempMap; 8 pnkfelix 1.1.2.1 import harpoon.Temp.Temp; 9 pnkfelix 1.1.2.1 10 pnkfelix 1.1.2.1 /** 11 pnkfelix 1.1.2.1 * <code>HTempMap</code> 12 pnkfelix 1.1.2.1 * 13 cananian 1.1.2.2 * @author Felix S. Klock II <pnkfelix@mit.edu> 14 cananian 1.3 * @version $Id: HTempMap.java,v 1.3 2004/02/08 01:52:07 cananian Exp $ 15 pnkfelix 1.1.2.1 */ 16 pnkfelix 1.1.2.1 class HTempMap extends GenericInvertibleMap implements TempMap { 17 pnkfelix 1.1.2.1 public Temp tempMap(Temp t) { 18 pnkfelix 1.1.2.1 return (Temp) this.get(t); 19 pnkfelix 1.1.2.1 } 20 pnkfelix 1.1.2.1 public Object get(Object key) { 21 pnkfelix 1.1.2.1 Object o = super.get(key); 22 pnkfelix 1.1.2.1 return (o == null) ? key : o; 23 pnkfelix 1.1.2.1 } 24 cananian 1.2 }