On Tuesday, 6 January 2015 at 16:58:24 UTC, Andrei Alexandrescu wrote:
On 1/5/15 10:43 PM, HaraldZealot wrote:
For my particular project (it binds with something like finite state machine) I will write some counterpart of decode function from std.utf. Future function will decode string backward, return dchar and change
index passed by reference.

Is it interesting for community that I code this feature in general way
targeting in phobos for future?

back() and popBack() for narrow strings do reverse decode. -- Andrei

I need reverse decode from any position, not only from the last.
I have coded a litle with stideBack allready, it works. But usage isn't clear as could: first strideBack, then decode, and decode move index forward, then I have to strideBack again :)

Perhaps i will wrap such algorithm in some function, but an other side i will be forced to optimize that and write real decodeBack function.

Reply via email to