RFR: 8345911: Enhance error message when IncompatibleClassChangeError is thrown for sealed class loading failures [v4]
David Holmes
dholmes at openjdk.org
Tue Dec 17 04:10:39 UTC 2024
On Tue, 17 Dec 2024 04:01:37 GMT, David Holmes <dholmes at openjdk.org> wrote:
>> src/hotspot/share/classfile/classFileError.cpp line 97:
>>
>>> 95: void ClassFileParser::classfile_icce_error(const char* msg,
>>> 96: TRAPS) const {
>>> 97: ResourceMark rm(THREAD);
>>
>> I don't know what this ResourceMark does since you allocate resources in the caller, not here.
>
> It follows the same pattern as all the other throwing methods - the RM is for the `_class_name->as_C_string()`. I think you may be right that it is the callers that should have the RM. Can I file a follow up RFE to look at that?
Now I see what you mean. Fixed.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/22703#discussion_r1887866968
More information about the hotspot-dev
mailing list