From 12a38d5b95db2221c68049fb6d2cc7abd5617304 Mon Sep 17 00:00:00 2001 From: Robert Griesemer Date: Tue, 30 Jul 2013 13:35:14 -0700 Subject: [PATCH] container/list: document complexity of Len Fixes #5972. R=golang-dev, adonovan CC=golang-dev https://golang.org/cl/12125043 --- src/pkg/container/list/list.go | 1 + 1 file changed, 1 insertion(+) diff --git a/src/pkg/container/list/list.go b/src/pkg/container/list/list.go index 562a5badbd..20d612ef9a 100644 --- a/src/pkg/container/list/list.go +++ b/src/pkg/container/list/list.go @@ -62,6 +62,7 @@ func (l *List) Init() *List { func New() *List { return new(List).Init() } // Len returns the number of elements of list l. +// The complexity is O(1). func (l *List) Len() int { return l.len } // Front returns the first element of list l or nil -- 2.48.1