mirror of
https://github.com/openvswitch/ovs
synced 2025-10-21 14:49:41 +00:00
python: Stop using xrange().
Python 2 had range() and xrange(). xrange() is more efficient, but behaves differently so range() was retained for compatibility. Python 3 only has range() and it behaves like Python 2's xrange(). Remove explicit use of xrange() and use six.moves.range() to make sure we're using xrange() from Python 2 or range() from Python 3. Signed-off-by: Russell Bryant <russell@ovn.org> Acked-by: Ben Pfaff <blp@ovn.org>
This commit is contained in:
@@ -15,6 +15,8 @@
|
||||
import re
|
||||
import uuid
|
||||
|
||||
from six.moves import range
|
||||
|
||||
from ovs.db import error
|
||||
import ovs.db.parser
|
||||
|
||||
|
Reference in New Issue
Block a user