Пример #1
0
  /** Run all pending passes on <code>job</code>. */
  public boolean runAllPasses(Job job) {
    List pending = job.pendingPasses();

    // Run until there are no more passes.
    if (!pending.isEmpty()) {
      Pass lastPass = (Pass) pending.get(pending.size() - 1);
      return runToPass(job, lastPass);
    }

    return true;
  }
Пример #2
0
 /**
  * The confluence operator for <code>Initializer</code>s and <code>Constructor</code>s needs to be
  * a little special, as we are only concerned with non-exceptional flows in these cases. This
  * method ensures that a slightly different confluence is performed for these <code>Term</code>s,
  * otherwise <code>confluence(List, Term)</code> is called instead.
  */
 protected Item confluence(List items, List itemKeys, Term node, FlowGraph graph) {
   if (node instanceof Initializer || node instanceof ConstructorDecl) {
     List filtered = filterItemsNonException(items, itemKeys);
     if (filtered.isEmpty()) {
       return createInitDFI();
     } else if (filtered.size() == 1) {
       return (Item) filtered.get(0);
     } else {
       return confluence(filtered, node, graph);
     }
   }
   return confluence(items, node, graph);
 }