langtools/src/jdk.compiler/share/classes/com/sun/tools/javac/main/JavaCompiler.java
changeset 26992 92e69fa21956
parent 26264 a09fedde76be
child 27224 228abfa87080
equal deleted inserted replaced
26991:88d998b3bb4b 26992:92e69fa21956
  1226                 //if in fail-over mode, ensure that AST expression nodes
  1226                 //if in fail-over mode, ensure that AST expression nodes
  1227                 //are correctly initialized (e.g. they have a type/symbol)
  1227                 //are correctly initialized (e.g. they have a type/symbol)
  1228                 attr.postAttr(env.tree);
  1228                 attr.postAttr(env.tree);
  1229             }
  1229             }
  1230             compileStates.put(env, CompileState.ATTR);
  1230             compileStates.put(env, CompileState.ATTR);
  1231             if (rootClasses != null && rootClasses.contains(env.enclClass)) {
       
  1232                 // This was a class that was explicitly supplied for compilation.
       
  1233                 // If we want to capture the public api of this class,
       
  1234                 // then now is a good time to do it.
       
  1235                 reportPublicApi(env.enclClass.sym);
       
  1236             }
       
  1237         }
  1231         }
  1238         finally {
  1232         finally {
  1239             log.useSource(prev);
  1233             log.useSource(prev);
  1240         }
  1234         }
  1241 
  1235 
  1242         return env;
  1236         return env;
  1243     }
       
  1244 
       
  1245     /** Report the public api of a class that was supplied explicitly for compilation,
       
  1246      *  for example on the command line to javac.
       
  1247      * @param sym The symbol of the class.
       
  1248      */
       
  1249     public void reportPublicApi(ClassSymbol sym) {
       
  1250        // Override to collect the reported public api.
       
  1251     }
  1237     }
  1252 
  1238 
  1253     /**
  1239     /**
  1254      * Perform dataflow checks on attributed parse trees.
  1240      * Perform dataflow checks on attributed parse trees.
  1255      * These include checks for definite assignment and unreachable statements.
  1241      * These include checks for definite assignment and unreachable statements.