add ports function to RecordObject
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 20 Apr 2019 21:53:34 +0000 (22:53 +0100)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 20 Apr 2019 21:53:34 +0000 (22:53 +0100)
src/add/singlepipe.py

index 52decdbb5e793873c42cccdb70d3ac15043c2076..231b9ab31523cb293a4a77968946edcdaeed6673 100644 (file)
@@ -197,6 +197,9 @@ class RecordObject(Record):
         for x in self.fields.values():
             yield x
 
+    def ports(self):
+        return list(self)
+
 
 class PrevControl:
     """ contains signals that come *from* the previous stage (both in and out)