Bug 16262 – assumeUTF attributes change between debug and release mode

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2016-07-10T10:27:14Z
Last change time
2020-01-13T16:54:42Z
Keywords
pull
Assigned to
No Owner
Creator
Lodovico Giaretta
Depends on
15710

Comments

Comment #0 by lodovico — 2016-07-10T10:27:14Z
assumeUTF is @nogc in release mode, but not in debug mode. The reason is that in debug mode it performs additional checks, which is not bad per se, but makes working with assumeUTF too difficult (e.g. I cannot use @nogc unittests). In general, this change of meaning between debug and release mode should be avoided. See also https://forum.dlang.org/thread/[email protected]
Comment #1 by dlang-bot — 2019-12-29T15:14:48Z
@berni44 created dlang/phobos pull request #7337 "Fix Issue 16262 - assumeUTF attributes change between debug and release mode" fixing this issue: - Fix Issue 16262 - assumeUTF attributes change between debug and release mode https://github.com/dlang/phobos/pull/7337
Comment #2 by bugzilla — 2020-01-02T15:17:30Z
During the PR I learned, that the @nogc-part is allready fixed. I checked that before filing it, but probably I erred somewhere. Anyway, the behaviour with and without debug mode still differs.