Re: Declaring outside a loop: speed? memory?
- From: Philipp <sicsicsic@xxxxxxxxxxx>
- Date: Tue, 23 Jan 2007 13:20:37 +0100
Ben Caradoc-Davies wrote:
Philipp wrote:Just wondering, is there a speed or memory difference between the two following codes?
Funny you should ask, because it was just mentioned on Planet Classpath http://planet.classpath.org/
Local Variables in Java
http://rmathew.blogspot.com/2007/01/local-variables-in-java.html
In short, there is no difference. The JVM specification requires them to be the same, and the same bytecode is generated.
Thanks.
.
- References:
- Declaring outside a loop: speed? memory?
- From: Philipp
- Re: Declaring outside a loop: speed? memory?
- From: Ben Caradoc-Davies
- Declaring outside a loop: speed? memory?
- Prev by Date: Re: Declaring outside a loop: speed? memory?
- Next by Date: Re: Bloomberg interview questions for java
- Previous by thread: Re: Declaring outside a loop: speed? memory?
- Next by thread: Re: Declaring outside a loop: speed? memory?
- Index(es):
Relevant Pages
|