Skip to content

Commit a87262e

Browse files
committed
8307295: Add warning to not create new ACC flags
Reviewed-by: dholmes, fparain
1 parent 0c6529d commit a87262e

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/hotspot/share/utilities/accessFlags.hpp

+5-4
Original file line numberDiff line numberDiff line change
@@ -37,12 +37,13 @@ class outputStream;
3737
enum {
3838
// See jvm.h for shared JVM_ACC_XXX access flags
3939

40-
// HotSpot-specific access flags
41-
4240
// flags actually put in .class file
4341
JVM_ACC_WRITTEN_FLAGS = 0x00007FFF,
4442

45-
// Klass* flags
43+
// HotSpot-specific access flags
44+
// These Klass flags should be migrated, to a field such as InstanceKlass::_misc_flags,
45+
// or to a similar flags field in Klass itself.
46+
// Do not add new ACC flags here.
4647
JVM_ACC_HAS_FINALIZER = 0x40000000, // True if klass has a non-empty finalize() method
4748
JVM_ACC_IS_CLONEABLE_FAST = (int)0x80000000,// True if klass implements the Cloneable interface and can be optimized in generated code
4849
JVM_ACC_IS_HIDDEN_CLASS = 0x04000000, // True if klass is hidden
@@ -53,7 +54,7 @@ enum {
5354
class AccessFlags {
5455
friend class VMStructs;
5556
private:
56-
jint _flags;
57+
jint _flags; // TODO: move 4 access flags above to Klass and change to u2
5758

5859
public:
5960
AccessFlags() : _flags(0) {}

0 commit comments

Comments
 (0)