works with closures in subblocks