RFR: fixing bugs in NullChecksWriter
Vicente Romero
vromero at openjdk.org
Sun Jan 11 00:58:04 UTC 2026
fixing some bugs in NullChecksWriter, reported by John Rose. In particular there was no null check being generated by javac for code like:
class Test {
void m(String someObject) {
String! x = "foo";
x = (String)someObject; // no null check generated here
}
public static void main(String... args) {
new Test().m(null);
}
}
-------------
Commit messages:
- removing dead code
- fixing bugs in NullChecksWriter
Changes: https://git.openjdk.org/valhalla/pull/1883/files
Webrev: https://webrevs.openjdk.org/?repo=valhalla&pr=1883&range=00
Stats: 26 lines in 2 files changed: 11 ins; 15 del; 0 mod
Patch: https://git.openjdk.org/valhalla/pull/1883.diff
Fetch: git fetch https://git.openjdk.org/valhalla.git pull/1883/head:pull/1883
PR: https://git.openjdk.org/valhalla/pull/1883
More information about the valhalla-dev
mailing list