remove uses of ~str