refactor rw.scope (scope.parent is gone)