digitalmars.D.bugs - [Issue 12320] New: std.stdio.LockingTextReader populates .front in .empty
- d-bugmail puremagic.com (22/22) Mar 08 2014 https://d.puremagic.com/issues/show_bug.cgi?id=12320
https://d.puremagic.com/issues/show_bug.cgi?id=12320 Summary: std.stdio.LockingTextReader populates .front in .empty Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: minor Priority: P2 Component: Phobos AssignedTo: nobody puremagic.com ReportedBy: peter.alexander.au gmail.com 11:35:55 PST --- In std.stdio.LockingTextReader, if you call .front after calling popFront, the value will be dchar.init. You have to call .empty before .front to get a meaningful value. This is fine for the vast majority of use cases, but if you happen to know a file has so many bytes then you might call .front without calling .empty, and that should work. -- Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Mar 08 2014