java compiler's target version “jsr14” with JDK7/8

前端 未结 3 655
無奈伤痛
無奈伤痛 2021-02-08 10:09

Can anybody tell me the jsr14 target option of javac will be still available with JDK7/8?

Say,

$ javac -source 1.5 -target jsr1         


        
3条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2021-02-08 10:11

    The latest OpenJDK source bundle (openjdk-7-ea-src-b130-18_feb_2011.zip) still contains the flag in the source (langtools/src/share/classes/com/sun/tools/javac/jvm/Target.java), but it has never been supported, so relying on it is a bad idea.

    Why do you need it?

提交回复
热议问题