[Issue 13348] std.uni.byGrapheme is impure
https://issues.dlang.org/show_bug.cgi?id=13348 Steven Schveighofferchanged: What|Removed |Added CC||schvei...@yahoo.com --- Comment #5 from Steven Schveighoffer --- Something doesn't seem right here. byGrapheme is a template function, including a templated struct. purity should be inferred everywhere here, no? The code itself seems pretty simple, seems like all the impurity comes from Grapheme and possibly decodeGrapheme. --
[Issue 13348] std.uni.byGrapheme is impure
https://issues.dlang.org/show_bug.cgi?id=13348 --- Comment #4 from hst...@quickfur.ath.cx --- It's not a problem that byGrapheme is sometimes impure, but it should not be the one introducing the impurity. I.e., if the incoming range is pure, then byGrapheme ought to be also pure. This can be enforced by not attributing byGrapheme directly, but using a pure nothrow etc. unittest to ensure any impure/throwing/etc. code actually comes from the incoming range, not from byGrapheme itself. --
[Issue 13348] std.uni.byGrapheme is impure
https://issues.dlang.org/show_bug.cgi?id=13348 Thaynechanged: What|Removed |Added CC||astrotha...@gmail.com --- Comment #3 from Thayne --- I don't think byGrapheme can be pure in general, because, in general, the input range used doesn't necessarily have pure input methods. For example the input range could read from I/O. The solution would probably be to add pure if and only if the front, popFront, and empty methods of the inputRange are themselves pure. I'm not sure what the best way to do that would be. --
[Issue 13348] std.uni.byGrapheme is impure
https://issues.dlang.org/show_bug.cgi?id=13348 hst...@quickfur.ath.cx changed: What|Removed |Added Severity|enhancement |blocker --- Comment #2 from hst...@quickfur.ath.cx --- Upgrade to blocker since the fix for issue #7054 is blocked by this. --
[Issue 13348] std.uni.byGrapheme is impure
https://issues.dlang.org/show_bug.cgi?id=13348 hst...@quickfur.ath.cx changed: What|Removed |Added Blocks||7054 --
[Issue 13348] std.uni.byGrapheme is impure
https://issues.dlang.org/show_bug.cgi?id=13348 --- Comment #1 from hst...@quickfur.ath.cx --- Ditto for graphemeStride. --