Bug 7796 – std.typecons.Unique is using writeln without importing std.stdio

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2012-03-29T10:52:00Z
Last change time
2012-05-31T04:06:53Z
Assigned to
nobody
Creator
simendsjo

Comments

Comment #0 by simendsjo — 2012-03-29T10:52:51Z
version(unittest) import core.vararg, std.stdio; (...) struct Unique(T) (...) this(RefT p) { writeln("Unique constructor with rvalue"); _p = p; } I guess those writeln's should be removed, or at least wrapped in version(unittest) blocks (or debug(typecons) or something) The following cannot even compile, so I guess no one is using it... import std.typecons; void main() { Unique!int i = 10; }
Comment #1 by github-bugzilla — 2012-05-23T09:24:30Z
Commits pushed to master at https://github.com/D-Programming-Language/phobos https://github.com/D-Programming-Language/phobos/commit/4ee4efe2b03d4d3221a96e06c6b10fd14350390e fix Issue 7796 - std.typecons.Unique is using writeln without importing std.stdio https://github.com/D-Programming-Language/phobos/commit/4a88cd82bf8abba0c799fe01537187a105a08299 Merge pull request #601 from 9rnsr/fix7796 Issue 7796 - std.typecons.Unique is using writeln without importing std.stdio
Comment #2 by github-bugzilla — 2012-05-23T11:17:01Z
Commits pushed to master at https://github.com/D-Programming-Language/phobos https://github.com/D-Programming-Language/phobos/commit/61f991ba515c5cb48b636a8c803ebbb5804e8508 Issue 7796 - std.typecons.Unique is using writeln without importing std.stdio. With Unique being a template, commit 4ee4efe (pull request #601) caused the messages to be printed for unittest builds of client code as well. https://github.com/D-Programming-Language/phobos/commit/a98fb93de808c99e0eba038d828b5cce2ee70ba5 Merge pull request #602 from klickverbot/trace-unique Issue 7796 - std.typecons.Unique is using writeln without importing std.stdio.