1
0
mirror of https://github.com/myhdl/myhdl.git synced 2025-01-24 21:52:56 +08:00

int, long

This commit is contained in:
jand 2004-02-02 22:46:32 +00:00
parent 3a92ce3039
commit bfe2b8fa9d
2 changed files with 3 additions and 1 deletions

View File

@ -108,7 +108,7 @@ def _analyzeGens(top, genNames):
s = inspect.getsource(f)
s = s.lstrip()
ast = compiler.parse(s)
# print ast
print ast
ast.sourcefile = inspect.getsourcefile(f)
ast.lineoffset = inspect.getsourcelines(f)[1]-1
ast.symdict = f.f_globals.copy()

View File

@ -355,6 +355,8 @@ class _ConvertVisitor(_ToVerilogMixin):
self.require(node, val is not None, "cannot calculate len")
self.write(`val`)
return
elif f in (int, long):
opening, closing = '', ''
elif type(f) in (ClassType, type) and issubclass(f, Exception):
self.write(f.__name__)
elif f in (posedge, negedge):