public MethodRec GetMethod(ClassRec c, AstId mid) { MethodRec m; while (c != null) { if ((m = c.GetMethod(mid)) != null) return m; c = c.Parent(); } throw new SymbolException("Method " + mid.s + " not defined"); }
public string UniqueMethodName(ClassRec c, AstId mid) { MethodRec m; while (c != null) { if ((m = c.GetMethod(mid)) != null) return c.Id().s + "_" + mid.s; c = c.Parent(); } throw new SymbolException("Method " + mid.s + " not defined"); }