Added `setCaptured()` to LazyMethod so we can do capture analysis on methods (#1001)
The ValueVisitor now also handles capture analysis for methods (#1001)