Update for Python 3 compatibility

You can't sort() over keys() in Python 3. Use sorted(dict)
instead as it is a construct that works with both Python 2
and Python 3.

Change-Id: I6dd5b20eab00e17d9b4bc973cc62e78d9be062a1
This commit is contained in:
Thierry Carrez
2018-06-22 16:33:02 +02:00
parent 7d36714e7c
commit 34e2fddbdd

View File

@@ -264,8 +264,7 @@ class Directive(rst.Directive):
summary_head.append(header)
# then one column for each backend driver
impls = matrix.drivers.keys()
impls.sort()
impls = sorted(matrix.drivers)
for key in impls:
driver = matrix.drivers[key]
implcol = nodes.entry()
@@ -296,8 +295,7 @@ class Directive(rst.Directive):
classes=["sp_feature_" + feature.status]))
# and then one column for each backend driver
impls = matrix.drivers.keys()
impls.sort()
impls = sorted(matrix.drivers)
for key in impls:
impl = feature.implementations[key]
impl_col = nodes.entry()