public String UseThisVar(String id,String context){
  SymTabEntry se=null;
  int i=FindSym(id,context);
  if (i == symtab.size())   return id;
  se=(SymTabEntry)symtab.elementAt(i);
  if (se.type == GLOBAL || se.type == PROCESSVAR || se.type == PROCEDUREVAR || se.type == PARAMETER)   return se.useThis;
  i=FindSym(id,"");
  if (se.type == GLOBAL)   return se.useThis;
  return id;
}

public String UseThisVar ( String id , String context ) { SymTabEntry se = null ; int i = FindSym ( id , context ) ; if ( i == symtab . size ( ) ) return id ; se = ( SymTabEntry ) symtab . elementAt ( i ) ; if ( se . type == GLOBAL || se . type == PROCESSVAR || se . type == PROCEDUREVAR || se . type == PARAMETER ) return se . useThis ; i = FindSym ( id , "" ) ; if ( se . type == GLOBAL ) return se . useThis ; return id ; }
given a variable referenced in a context . first get the entry in the context . if no such variable , then see if a global one exists . if not , then use it undisambiguated . note : stop using findsym ; it ' s a bad hack .
