use explicit blocks instead of yield