bbade
03/30/2016, 7:23 PMthis
from an outer scope is implicitly used in an inner-scope. I'm making a framework for defining nested validators for objects, but its basically written very similarly to the HTML Builder example.
outer() {
doOuterThing() // fine, implicitly the same as the following two statements
this.doOuterThing() //fine
this@outer.doOuterThing() // fine
inner() {
doInnerThing() //fine, implicitly is this@inner.doInnerThing()
doOuterThing() // bad, because it is implicitly this@outer.doOuterThing(). Causes weird stuff to happen
}
}