RFR: 8306872: Rename Node_Array::Size()
Xin Liu
xliu at openjdk.org
Tue Apr 25 21:36:24 UTC 2023
Node_List inherits Node_Array, so it inherits Size(). To resolve naming conflict,
Node_List uses size() (with little s) and keep Size() as capacity. I don't think
it's a good practice to distinct two function using capital initial. In particular
they have different meanings. A true story is that it took me 2 days to find a bug
that I chose wrong one between them.
This patch just renames Node_Array::Size to max. By using different names, this will
avoid from misusing. We need to changes 6 places. 4 are for Node_List::Size() intentionally.
2 of them are for Node_Array::Size().
-------------
Commit messages:
- 8306872: Rename Node_Array::Size()
Changes: https://git.openjdk.org/jdk/pull/13659/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=13659&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8306872
Stats: 7 lines in 5 files changed: 0 ins; 0 del; 7 mod
Patch: https://git.openjdk.org/jdk/pull/13659.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/13659/head:pull/13659
PR: https://git.openjdk.org/jdk/pull/13659
More information about the hotspot-compiler-dev
mailing list