sv_binutils: fix broken script
authorDmitry Selyutin <ghostmansd@gmail.com>
Mon, 10 Apr 2023 16:11:23 +0000 (19:11 +0300)
committerDmitry Selyutin <ghostmansd@gmail.com>
Mon, 10 Apr 2023 16:11:23 +0000 (19:11 +0300)
src/openpower/sv/sv_binutils.py

index b4dea0acf62ed1419fb36cda661c99f2b702d3ee..c2ba879689147107eca223d6ec65da8269f6cca4 100644 (file)
@@ -664,6 +664,12 @@ def collect(db):
 
             if issubclass(cls, Boolean):
                 value = Boolean(value)
+            elif issubclass(cls, Extra):
+                value = tuple(value)
+                if not value:
+                    value = cls["NONE"]
+                else:
+                    value = cls[value[0].name]
             elif issubclass(cls, _enum.Enum):
                 value = cls[value.name]
             else: