Thanks, my bad, for Back() and Front() is obvious, returns nil when there 
are no elements left.

But I don't see how a Push*() can return nil, it always return an Element. 
If I push a nil it will return an Element with value=nil.


On Tuesday, August 29, 2017 at 7:27:31 AM UTC+3, snmed wrote:
>
> Hi 
>
> As far as the docs are right:
>
> For Back: Back returns the last element of list l or nil.
>
> For PushBack:  PushBack inserts a new element e with value v at the back 
> of list l and returns e.
>
> So if you push nil, you get nil otherwise you get always your pushed 
> element.
>
> Cheers
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to