Tree qual1 = makeStableId(tree.pos, pre);
Tree qual1 = gen.This(tree.pos, nextcontext.enclClass.owner);
    Tree transformIdent(Tree tree, Name name) {	//System.out.println("transforming " + name);//DEBUG	// find applicable definition and assign to `sym'	Symbol sym = Symbol.NONE;	Type pre;	Tree qual = Tree.Empty;	int stopPos = Integer.MIN_VALUE;	Context nextcontext = context;	while (sym.kind == NONE && nextcontext != Context.NONE) {	    sym = nextcontext.scope.lookup(name);	    if (sym.kind != NONE) {		stopPos = sym.pos;	    } else {		nextcontext = nextcontext.enclClass;		if (nextcontext != Context.NONE) {		    sym = nextcontext.owner.thisSym().info().lookup(name);		    if (sym.kind != NONE) {			stopPos = nextcontext.owner.pos;		    } else {			nextcontext = nextcontext.outer;		    }		}	    }	}	// find applicable import and assign to `sym1'	ImportList nextimports = context.imports;	ImportList lastimports = null;	Symbol sym1 = Symbol.NONE;   //	System.out.println("name = " + name + ", pos = " + tree.pos + ", importlist = ");//DEBUG//	for (ImportList imp = nextimports; imp != null; imp = imp.prev) {//	    new TextTreePrinter().print("    ").print(imp.tree).println().end();//DEBUG//	}	while (nextimports != null && nextimports.tree.pos >= tree.pos) {	    nextimports = nextimports.prev;	}	while (sym1.kind == NONE && 	       nextimports != null && nextimports.tree.pos > stopPos) {	    sym1 = nextimports.importedSymbol(name);	    lastimports = nextimports;	    nextimports = nextimports.prev;	}	// evaluate what was found	if (sym1.kind == NONE) {	    if (sym.kind == NONE) {		//System.out.println(name);//DEBUG		error(tree.pos, "not found: " + decode(name));		return tree.setSymbol(Symbol.ERROR).setType(Type.ErrorType);	    } else {		if (sym.owner().kind == CLASS) {		    pre = nextcontext.enclClass.owner.thisType();		    if (!sym.owner().isPackage()) {			Tree qual1 = makeStableId(tree.pos, pre);			tree = make.Select(tree.pos, qual1, name);			//System.out.println(name + " :::> " + tree + " " + qual1.symbol());//DEBUG		    }		} else {		    pre = Type.localThisType;		}	    }	} else if (sym.kind != NONE && !sym.isExternal()) {	    return error(tree.pos, 			 "reference to " + name + " is ambiguous;\n" +			 "it is both defined in " + sym.owner() + 			 " and imported subsequently by \n" + nextimports.tree);	} else {	    // check that there are no other applicable imports in same scope.	    while (nextimports != null && 		   nextimports.enclscope == lastimports.enclscope) {		if (!nextimports.sameImport(lastimports) &&		    nextimports.importedSymbol(name).kind != NONE) {		    return error(tree.pos, 				 "reference to " + name + " is ambiguous;\n" +				 "it is imported twice in the same scope by\n    " + 				 lastimports.tree + "\nand " + nextimports.tree);		}		nextimports = nextimports.prev;	    }	    sym = sym1;	    qual = lastimports.importPrefix().duplicate();	    pre = qual.type;	    //new TextTreePrinter().print(name + " => ").print(lastimports.tree).print("." + name).println().end();//DEBUG	    tree = make.Select(tree.pos, qual, name);	}	Type symtype = (sym.isType() ? sym.typeConstructor() : sym.type())	    .asSeenFrom(pre, sym.owner());	if (qual != Tree.Empty) 	    symtype = checkAccessible(tree.pos, sym, symtype, qual);	if (symtype == Type.NoType)	    return error(tree.pos, "not found: " + decode(name));	//System.out.println(name + ":" + symtype);//DEBUG	return mkStable(tree.setSymbol(sym).setType(symtype), pre, mode, pt);    }