Skip to content

Commit 7a62032

Browse files
author
Kim Barrett
committed
8336081: Fix -Wzero-as-null-pointer-constant warnings in JVMTypedFlagLimit ctors
Reviewed-by: dholmes, jwaters
1 parent f677b90 commit 7a62032

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/hotspot/share/runtime/flags/jvmFlagLimit.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2020, 2023, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -155,15 +155,15 @@ class JVMTypedFlagLimit : public JVMFlagLimit {
155155
// dummy - no range or constraint. This object will not be emitted into the .o file
156156
// because we declare it as "const" but has no reference to it.
157157
constexpr JVMTypedFlagLimit(int type_enum) :
158-
JVMFlagLimit(0, 0, JVMFlagConstraintPhase::AtParse, 0), _min(0), _max(0) {}
158+
JVMFlagLimit(0, 0, JVMFlagConstraintPhase::AtParse, 0), _min(), _max() {}
159159

160160
// range only
161161
constexpr JVMTypedFlagLimit(int type_enum, T min, T max) :
162162
JVMFlagLimit(type_enum, 0, JVMFlagConstraintPhase::AtParse, HAS_RANGE), _min(min), _max(max) {}
163163

164164
// constraint only
165165
constexpr JVMTypedFlagLimit(int type_enum, ConstraintMarker dummy2, short func, JVMFlagConstraintPhase phase) :
166-
JVMFlagLimit(type_enum, func, phase, HAS_CONSTRAINT), _min(0), _max(0) {}
166+
JVMFlagLimit(type_enum, func, phase, HAS_CONSTRAINT), _min(), _max() {}
167167

168168
// range and constraint
169169
constexpr JVMTypedFlagLimit(int type_enum, T min, T max, ConstraintMarker dummy2, short func, JVMFlagConstraintPhase phase) :

0 commit comments

Comments
 (0)