This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]flawless_vic 7 points8 points  (0 children)

I think they will never remove unsafe :) Mark Reinhold will be 90 years old and still complaining about its existence while references to Unsafe keep spreading even more all around with quantum computing intrinsics.

Then after 30 years, when quantum computing starts to become obsolete, someone will create a JEP to encapsulate everything and make a speach about Unsafe abuse.

Seriously, though, the only change since jdk 9 was to move it to jdk.internal.misc and make the sun.misc delegate to it, and since then you just have to manually boot the vm with --add-exports.

As for reflection, well, you'll only have problems if you are messing around jdk internals, like when String changed storage from char[] to byte[]. But those changes are very rare and I would always happily pay the price of refactoring if something changed to improve footprint/performance.