9 May 09:57
Re: [groovy-user] with(..) method does not work properly in scripts
Jochen Theodorou wrote: > > Sergey Bondarenko schrieb: > "with" is no compiler construct, it is just a normal method that gets a > Closure. What we maybe should do is setting the resolving strategy for > the closure to delegate only, then it wold do the right thing. You can > test this by assigning the Closure to a variable, setting the strategy > and then calling the method normally like map.with(c). I also suggest > you write a JIRA issue for this. > If we were to change the resolving strategy then the behaviour in a class would change. It's entirely possible that this would then break existing code. I think we just have to live with the fact that some stuff just doesn't work in scripts. John Wilson -- -- View this message in context: http://www.nabble.com/with%28..%29-method-does-not-work-properly-in-scripts-tp17077463p17143113.html Sent from the groovy - user mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
RSS Feed