Inside a `with (foo)` block, is there any way to i...
# announcements
m
Inside a
with (foo)
block, is there any way to indicate that I mean variable
bar
from outside the block, rather than a property
bar
of object
foo
?
b
this@MyClass.bar
?
l
this seems confusing tho
m
Yes, it works, but it doesn't look elegant.
Maybe the right answer is not to use
with
g
I agree, if nested scope usage become confusion I would just get rid of this scope and use explicit name instead
I would also say that I almost never use
with
itself (tho I use similar run and apply extensions)