Add Element to list not Working

James Miller james at aatch.net
Sun Apr 1 23:15:14 PDT 2012


On 2 April 2012 17:45, Chris Pons <cmpons at gmail.com> wrote:
> I'm trying to add an element to a list with insert but that doesn't seem to
> do anything at all. If I try using ~= it says that "Error: cannot append
> type Node to type SList!(Node). I'm pretty confused about using ~= because
> it works fine for arrays but apperantly not for lists.
>
> How do I add an element to a list?

opAppend (or whatever it is) isn't defined for alot of types that it
probably should be. There should be an append method that you can use
though.

--
James Miller


More information about the Digitalmars-d-learn mailing list