Lambda expressions and method references capture a reference to this
only if required, i.e. when this
is referenced directly or an instance (non-static
) member is accessed.
Of course, if your lambda expression captures the value of a local variable and that value contains a reference to this
it implies referencing this
as well…
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…