< prev index next >

src/jdk.compiler/share/classes/com/sun/tools/javac/main/JavaCompiler.java

Print this page

        

@@ -301,10 +301,14 @@
 
     /** The flow analyzer.
      */
     protected Flow flow;
 
+    /** The intrinsics analyzer.
+     */
+    protected IntrinsicsVisitor intrinsicsVisitor;
+
     /** The modules visitor
      */
     protected Modules modules;
 
     /** The module finder

@@ -413,10 +417,11 @@
         attr = Attr.instance(context);
         analyzer = Analyzer.instance(context);
         chk = Check.instance(context);
         gen = Gen.instance(context);
         flow = Flow.instance(context);
+        intrinsicsVisitor = IntrinsicsVisitor.instance(context);
         transTypes = TransTypes.instance(context);
         lower = Lower.instance(context);
         annotate = Annotate.instance(context);
         types = Types.instance(context);
         taskListener = MultiTaskListener.instance(context);

@@ -1556,10 +1561,12 @@
                 return;
 
             env.tree = transTypes.translateTopLevelClass(env.tree, localMake);
             compileStates.put(env, CompileState.TRANSTYPES);
 
+            env.tree = intrinsicsVisitor.analyzeTree(env.tree, env);
+
             if (Feature.LAMBDA.allowedInSource(source) && scanner.hasLambdas) {
                 if (shouldStop(CompileState.UNLAMBDA))
                     return;
 
                 env.tree = LambdaToMethod.instance(context).translateTopLevelClass(env, env.tree, localMake);
< prev index next >