X-Git-Url: https://git.libre-soc.org/?p=sv2nmigen.git;a=blobdiff_plain;f=absyn.py;fp=absyn.py;h=12f1c0a2a46265994e874508337dfded4671d882;hp=a1b34274d4840f5415964eee20b64b6062b7dbe1;hb=ef7e6ced2fbede9970934dfc86140ab241f1a32d;hpb=26277f5a20d201ac895bccf941d17bc7e28c3596 diff --git a/absyn.py b/absyn.py index a1b3427..12f1c0a 100644 --- a/absyn.py +++ b/absyn.py @@ -34,6 +34,9 @@ class Absyn: return Leaf(token.DEDENT, '') def nl(self): return Leaf(token.NEWLINE, '\n') + + def port_decl(self,comment, dt, name): + return None # TODO def initPorts(self,params,ports): pass_stmt = Node(syms.pass_stmt ,[Leaf(token.NAME, "def __init__(self):#FIXME")]) @@ -86,7 +89,12 @@ class Absyn: stmts.children.append(self.indent(2)) stmts.children.append(Leaf(token.STRING,"m = Module()")) stmts.children.append(self.nl()) - ## + ## + for a in self.assign: + stmts.children.append(self.indent(2)) + stmts.children.append(Leaf(token.STRING,"#FIXME_ASSIGN"+str(list(a[8])))) + stmts.children.append(self.nl()) + stmts.children.append(self.indent(2)) stmts.children.append(Leaf(token.STRING,"return m")) stmts.children.append(self.nl()) @@ -119,5 +127,5 @@ class Absyn: # combinatorical assign def cont_assign_1(self,p): - self.printpy("#ASSIGN"+str(list(p))) + #self.printpy("#ASSIGN"+str(list(p))) self.assign += [p]