DList.removeAny

monarch_dodra monarchdodra at gmail.com
Tue Mar 12 06:13:11 PDT 2013


On Tuesday, 12 March 2013 at 12:52:20 UTC, jerro wrote:
> On Tuesday, 12 March 2013 at 12:31:45 UTC, thedeemon wrote:
>> Documentation for this method says it takes a value from the 
>> front, but the code actually does the opposite, takes it from 
>> the back. Shall we fix documentation or the code?
>
> Judging by the name, I think documentation shouldn't even 
> specify which element is removed. There are removeFront and 
> removeBack if you want to remove front or back.

The behavior of removeAny is implementation defined. 
Documentation should be fixed.

Note that removeAny, contrary to the other removes returns will 
give you the element that was removed.


More information about the Digitalmars-d mailing list