Am Mon, 10 Mar 2014 13:55:00 -0400 schrieb "Steven Schveighoffer" <schvei...@yahoo.com>:
> On Mon, 10 Mar 2014 13:06:08 -0400, Brad Anderson <e...@gnuk.net> > wrote: > > > It seems like this would be an even bigger breaking change than > > Walter's proposal though (right or wrong, slicing strings is very > > common). > > You're the second person to mention that, I was not planning on > disabling string slicing. Just random access to individual chars, and > probably .length. > > -Steve Unfortunately slicing by code units is probably the most important safety issue with the current implementation: As was mentioned in the other thread: size_t index = str.countUntil('a'); auto slice = str[0..index]; This can be a safety and security issue. (I realize that this would break lots of code so I'm not sure if we should/can fix it. But I think this was the most important problem mentioned in the other thread.)