On 2019-12-31 21:36:56 +0000, Steven Schveighoffer said:
The fact that a Grapheme's return requires you keep the grapheme in
scope for operations seems completely incorrect and dangerous IMO (note
that operators are going to always have a ref this, even when called on
an rvalue). So even though using ref works, I think the underlying
issue here really is the lifetime problem.
Thanks for all the answers, pretty enlighting even I'm not sure I get
So, what to do for now? File a bug-report? What needs to be fixed?
I'm using the ref approach for now, in hope it will be OK for my
use-case, which is converting a wstring to a grapheme, alter the
array, and map it back to a wstring. Sounds like a lot of porcessing
for handling unicode text, but I don't think it gets a lot simpler than
Robert M. Münch
smarter | better | faster