Skip to content

Commit e7cf4bb

Browse files
committed
update warning message
1 parent 776f0a0 commit e7cf4bb

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

src/hotspot/share/runtime/arguments.cpp

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3934,17 +3934,15 @@ jint Arguments::apply_ergo() {
39343934
FLAG_SET_DEFAULT(BytecodeVerificationRemote, true);
39353935
}
39363936
if (!is_valhalla_enabled()) {
3937-
#define DISABLE_FLAG_AND_WARN_IF_NOT_DEFAULT(flag) \
3938-
if (!FLAG_IS_DEFAULT(flag)) { \
3939-
warning("Disabling Valhalla-specific flag \"%s\" since --enable-preview is not specified.", #flag); \
3940-
} \
3941-
FLAG_SET_DEFAULT(flag, false);
3942-
3943-
#define WARN_IF_NOT_DEFAULT_FLAG(flag) \
3937+
#define WARN_IF_NOT_DEFAULT_FLAG(flag) \
39443938
if (!FLAG_IS_DEFAULT(flag)) { \
39453939
warning("Valhalla-specific flag \"%s\" has no effect when --enable-preview is not specified.", #flag); \
39463940
}
39473941

3942+
#define DISABLE_FLAG_AND_WARN_IF_NOT_DEFAULT(flag) \
3943+
WARN_IF_NOT_DEFAULT_FLAG(flag) \
3944+
FLAG_SET_DEFAULT(flag, false);
3945+
39483946
DISABLE_FLAG_AND_WARN_IF_NOT_DEFAULT(InlineTypePassFieldsAsArgs);
39493947
DISABLE_FLAG_AND_WARN_IF_NOT_DEFAULT(InlineTypeReturnedAsFields);
39503948
DISABLE_FLAG_AND_WARN_IF_NOT_DEFAULT(UseArrayFlattening);

0 commit comments

Comments
 (0)