13 ms·
I've read somewhere that because of these getter setter patterns, JVM authors had to optimise their JIT to detect and inline those. Related discussion on SO: h
by whiteros_e 2y ago
I've read somewhere that because of these getter setter patterns, JVM authors had to optimise their JIT to detect and inline those.
Related discussion on SO: https://stackoverflow.com/questions/37109924/if-getter-setter-are-replaced-at-compile-time-in-java-how-can-their-purpose-be https://stackoverflow.com/questions/37109924/if-getter-sette...
- mikmoila 2y agoThere is nothing special in getters and setters, the runtime sees them as methods and may optimize them as it'd do for any other methods.