Why rbtree.length isn't const?

Steven Schveighoffer via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Thu Feb 26 07:44:55 PST 2015


On 2/26/15 3:20 AM, drug wrote:
> Is it intended by some reason?

No, it can be fixed. RBTree was not written to support const because D 
doesn't support tail-const ranges, which makes const really difficult to 
deal with. But length can definitely be const.

Please submit an issue. http://issues.dlang.org

-Steve


More information about the Digitalmars-d-learn mailing list