@@ -59,18 +59,14 @@ public class HotSpotGraalOptionValues {
59
59
* {@code GRAAL_OPTION_PROPERTY_PREFIX + "MyOption"}.
60
60
*/
61
61
public static final String GRAAL_OPTION_PROPERTY_PREFIX = "jdk.graal." ;
62
- public static final String LEGACY_GRAAL_OPTION_PROPERTY_PREFIX = "graal." ;
62
+
63
+ private static final String LEGACY_GRAAL_OPTION_PROPERTY_PREFIX = "graal." ;
63
64
64
65
/**
65
66
* Prefix for system properties that correspond to libgraal Native Image options.
66
67
*/
67
68
public static final String LIBGRAAL_VM_OPTION_PROPERTY_PREFIX = "jdk.graal.internal." ;
68
69
69
- /**
70
- * Guard for issuing warning about deprecated Graal option prefix at most once.
71
- */
72
- private static final GlobalAtomicLong LEGACY_OPTION_DEPRECATION_WARNED = new GlobalAtomicLong ("LEGACY_OPTION_DEPRECATION_WARNED" , 0L );
73
-
74
70
/**
75
71
* Gets the system property assignment that would set the current value for a given option.
76
72
*/
@@ -114,14 +110,8 @@ public static EconomicMap<OptionKey<?>, Object> parseOptions() {
114
110
String name = e .getKey ();
115
111
if (name .startsWith (LEGACY_GRAAL_OPTION_PROPERTY_PREFIX )) {
116
112
String baseName = name .substring (LEGACY_GRAAL_OPTION_PROPERTY_PREFIX .length ());
117
- name = GRAAL_OPTION_PROPERTY_PREFIX + baseName ;
118
- if (LEGACY_OPTION_DEPRECATION_WARNED .compareAndSet (0L , 1L )) {
119
- System .err .printf ("""
120
- WARNING: The 'graal.' property prefix for the Graal option %s
121
- WARNING: (and all other Graal options) is deprecated and will be ignored
122
- WARNING: in a future release. Please use 'jdk.graal.%s' instead.%n""" ,
123
- baseName , baseName );
124
- }
113
+ String msg = String .format ("The 'graal.' prefix for %s is unsupported - use 'jdk.graal.%s' instead." , baseName , baseName );
114
+ throw new IllegalArgumentException (msg );
125
115
}
126
116
if (name .startsWith (GRAAL_OPTION_PROPERTY_PREFIX )) {
127
117
if (name .startsWith (LIBGRAAL_VM_OPTION_PROPERTY_PREFIX )) {
0 commit comments