Add `scope` fn for scope merging