public void flush() { if (enterCount != 0) return; enterCount++; try { while (q.nonEmpty()) q.next().enterAnnotation(); } finally { enterCount--; } }
public void flush() { if (enterCount != 0) return; enterCount++; try { while (q.nonEmpty()) q.next().enterAnnotation(); } finally { enterCount--; } }
public void flush() { if (enterCount != 0) return; enterCount++; try { while (q.nonEmpty()) { q.next().run(); } while (typesQ.nonEmpty()) { typesQ.next().run(); } while (repeatedQ.nonEmpty()) { repeatedQ.next().run(); } while (afterRepeatedQ.nonEmpty()) { afterRepeatedQ.next().run(); } while (validateQ.nonEmpty()) { validateQ.next().run(); } } finally { enterCount--; } }
public void flush() { if (enterCount != 0) return; enterCount++; try { while (q.nonEmpty()) { q.next().run(); } while (typesQ.nonEmpty()) { typesQ.next().run(); } while (repeatedQ.nonEmpty()) { repeatedQ.next().run(); } while (afterRepeatedQ.nonEmpty()) { afterRepeatedQ.next().run(); } while (validateQ.nonEmpty()) { validateQ.next().run(); } } finally { enterCount--; } }
void run(ListBuffer<Env<AttrContext>> list, Iterable<? extends TypeElement> classes) { Set<TypeElement> set = new HashSet<TypeElement>(); for (TypeElement item: classes) set.add(item); List<Env<AttrContext>> defer = List.<Env<AttrContext>>nil(); while (list.nonEmpty()) { Env<AttrContext> env = list.next(); ClassSymbol csym = env.enclClass.sym; if (csym != null && set.contains(csym.outermostClass())) process(env); else defer = defer.prepend(env); } for (List<Env<AttrContext>> l = defer; l.nonEmpty(); l = l.tail) list.prepend(l.head); }
/** * Attribute a list of parse trees, such as found on the "todo" list. * Note that attributing classes may cause additional files to be * parsed and entered via the SourceCompleter. * Attribution of the entries in the list does not stop if any errors occur. * @returns a list of environments for attributd classes. */ public List<Env<AttrContext>> attribute(ListBuffer<Env<AttrContext>> envs) { ListBuffer<Env<AttrContext>> results = lb(); while (envs.nonEmpty()) results.append(attribute(envs.next())); return results.toList(); }
private void locateNestedTypes(Type type, TypeAnnotationPosition p) { // The number of "steps" to get from the full type to the // left-most outer type. ListBuffer<TypePathEntry> depth = new ListBuffer<>(); Type encl = type.getEnclosingType(); while (encl != null && encl.getKind() != TypeKind.NONE && encl.getKind() != TypeKind.ERROR) { depth = depth.append(TypePathEntry.INNER_TYPE); encl = encl.getEnclosingType(); } if (depth.nonEmpty()) { p.location = p.location.prependList(depth.toList()); } }
private void locateNestedTypes(Type type, TypeAnnotationPosition p) { // The number of "steps" to get from the full type to the // left-most outer type. ListBuffer<TypePathEntry> depth = new ListBuffer<>(); Type encl = type.getEnclosingType(); while (encl != null && encl.getKind() != TypeKind.NONE && encl.getKind() != TypeKind.ERROR) { depth = depth.append(TypePathEntry.INNER_TYPE); encl = encl.getEnclosingType(); } if (depth.nonEmpty()) { p.location = p.location.prependList(depth.toList()); } }
while (uncompleted.nonEmpty()) { ClassSymbol clazz = uncompleted.next(); if (c == null || c == clazz || prevUncompleted == null)
while (uncompleted.nonEmpty()) { ClassSymbol clazz = uncompleted.next(); if (c == null || c == clazz || prevUncompleted == null)
while (uncompleted.nonEmpty()) { ClassSymbol clazz = uncompleted.next(); if (c == null || c == clazz || prevUncompleted == null)
while (uncompleted.nonEmpty()) { ClassSymbol clazz = uncompleted.next(); if (c == null || c == clazz || prevUncompleted == null)
if (res.contains(l.head) && !t.contains(l.head)) openVars.append(l.head); if (openVars.nonEmpty()) { if (t.isRaw()) {
if (res.contains(l.head) && !t.contains(l.head)) openVars.append(l.head); if (openVars.nonEmpty()) { if (t.isRaw()) {
abstracts = abstracts.append(provSym); if (defaults.nonEmpty() && defaults.size() + abstracts.size() >= 2) {
if (res.contains(l.head) && !t.contains(l.head)) openVars.append(l.head); if (openVars.nonEmpty()) { if (t.isRaw()) {
abstracts = abstracts.append(provSym); if (defaults.nonEmpty() && defaults.size() + abstracts.size() >= 2) {
if (res.contains(l.head) && !t.contains(l.head)) openVars.append(l.head); if (openVars.nonEmpty()) { if (t.isRaw()) {