[python PATCH 1/5] generator: enum: Don't sort enums by names

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Setting OCDs aside, sorting enums breaks if the definition contains
links to other enums defined in the libvirt header before. Let the
generator generate it in the natural order.
---
 generator.py | 2 --
 1 file changed, 2 deletions(-)

diff --git a/generator.py b/generator.py
index a12c52b..9c497be 100755
--- a/generator.py
+++ b/generator.py
@@ -1786,8 +1786,6 @@ def buildWrappers(module):
         return value

     enumvals = list(enums.items())
-    if enumvals is not None:
-        enumvals.sort(key=lambda x: x[0])
     for type,enum in enumvals:
         classes.write("# %s\n" % type)
         items = list(enum.items())
-- 
2.0.2

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]