[Issue 11168] New: core.stdc.time.asctime() is incorrectly marked as @trusted
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Thu Oct 3 20:23:58 PDT 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11168
Summary: core.stdc.time.asctime() is incorrectly marked as
@trusted
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: P2
Component: druntime
AssignedTo: nobody at puremagic.com
ReportedBy: bugzilla at digitalmars.com
--- Comment #0 from Walter Bright <bugzilla at digitalmars.com> 2013-10-03 20:23:56 PDT ---
https://github.com/D-Programming-Language/druntime/blob/master/src/core/stdc/time.d#L89
asctime() is not @trusted because it is allowed to return a non-shared pointer
to shared data. It's also not reentrant - it'll produce mangled garbage if
called from multiple threads. There's no way this can be marked as @trusted.
The similar functions in the same module need to be carefully reviewed.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list