Trivial bug fix: deque == [] is not a good way to check if a deque is empty.

This commit is contained in:
Armin Rigo 2004-09-27 17:49:00 +00:00
parent ffdb8bb99c
commit b562bc672b
1 changed files with 1 additions and 1 deletions

View File

@ -259,7 +259,7 @@ class fifo:
return len(self.list)
def is_empty (self):
return self.list == []
return not self.list
def first (self):
return self.list[0]