should this be a reference to `rs` to prevent copying?