From cdbb4669c43202ab8d7f9b7496369f2da9f0df68 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Tue, 20 Mar 2018 17:35:09 +0000 Subject: [PATCH] add format function --- src/interface_decl.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/interface_decl.py b/src/interface_decl.py index 04fd8bf..e34d102 100644 --- a/src/interface_decl.py +++ b/src/interface_decl.py @@ -64,6 +64,8 @@ class Interface(object): def __str__(self): return '\n'.join(map(str, self.pins)) + def format(self, i): + return str(self).format(i) # basic test if __name__ == '__main__': -- 2.30.2