remove an extra copy, possibly improving compilation for functions returning references