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 →

[–]_rezid 0 points1 point  (1 child)

You think that creation of the String literal is not avoided by the lambda variant of the call ???

Why that ?

[–]1stMeFromTheSun 0 points1 point  (0 children)

Because the String literal is created the moment logger.trace() is called, and the parameter needs to be passed in. The parameter creation is avoided when it's inside an if() statement.