Bug 18166 – std.array.replace should be usable in @safe for dstrings

Status
RESOLVED
Resolution
FIXED
Severity
enhancement
Priority
P1
Component
phobos
Product
D
Version
D2
Platform
x86_64
OS
All
Creation time
2018-01-03T02:56:00Z
Last change time
2018-03-12T18:45:47Z
Assigned to
No Owner
Creator
Seb
Blocks
18110

Comments

Comment #0 by greensunny12 — 2018-01-03T02:56:00Z
import std.array; replace("aa"d, 0, 0, "***"d); onlineapp.d(6): Error: @safe function 'onlineapp.test' cannot call @system function 'std.array.replace!(immutable(dchar), dstring).replace'
Comment #1 by github-bugzilla — 2018-03-12T18:45:46Z
Commits pushed to master at https://github.com/dlang/phobos https://github.com/dlang/phobos/commit/13cf12dfda5d9564ea2f63dfbeee0f1d129af94c Fix Issue 18166 - std.array.replace should be usable in @safe for dstrings https://github.com/dlang/phobos/commit/7c9c07552dc289997887675d7cc74a51f5a1c103 Merge pull request #6255 from JackStouffer/issue18166 Fix Issue 18166 - std.array.replace should be usable in @safe for dst… merged-on-behalf-of: Jack Stouffer <[email protected]>