Bug 14910 – Take!R does not offer length for char[]
Status
RESOLVED
Resolution
INVALID
Severity
enhancement
Priority
P1
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2015-08-12T08:39:00Z
Last change time
2015-08-12T09:17:50Z
Assigned to
nobody
Creator
schneider.cedric
Comments
Comment #0 by schneider.cedric — 2015-08-12T08:39:57Z
unittest
{
char[] chars = ['h', 'e', 'l', 'l', 'o'];
assert(chars.take(2).length == 2);
}
This unittest fails to compile, complaining that Take!char[] does not have a length, despite Take!R claiming to offer a length property if the input range does.
Comment #1 by petar.p.kirov — 2015-08-12T09:14:46Z