groovy-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jochen Theodorou <blackd...@gmx.org>
Subject Re: A @CompileStatic for class members
Date Thu, 21 Jan 2016 16:49:47 GMT


On 21.01.2016 17:31, Winnebeck, Jason wrote:
> What surprises me is that accessing by property is a lot slower than
> setter. I suppose I figured once Groovy fully initialized the MOP and
> call site that t.member = 1 would perform essentially exactly the same
> as t.setMember(1).

I think there is no callsite caching for setting properties... well, for 
the normal callsite aching... the indy version has it.

Then again, if you are in an open block, like in the example using with, 
there is no way to do caching at all. The Closure can always give it a 
different meaning.


bye Jochen

Mime
View raw message