mirror of
https://github.com/myhdl/myhdl.git
synced 2025-01-24 21:52:56 +08:00
Deprecation warning
This commit is contained in:
parent
5c84578076
commit
1d4625838f
@ -5,6 +5,7 @@ import os
|
|||||||
import tempfile
|
import tempfile
|
||||||
import subprocess
|
import subprocess
|
||||||
import difflib
|
import difflib
|
||||||
|
import warnings
|
||||||
|
|
||||||
from collections import namedtuple
|
from collections import namedtuple
|
||||||
|
|
||||||
@ -116,7 +117,11 @@ class _VerificationClass(object):
|
|||||||
elif isinstance(func, _ModuleInstance):
|
elif isinstance(func, _ModuleInstance):
|
||||||
name = func.mod.__name__
|
name = func.mod.__name__
|
||||||
else:
|
else:
|
||||||
name = func.__name__
|
warnings.warn("Deprecated use of analyze()/verify(): use a ModuleInstance argument", stacklevel=2)
|
||||||
|
try:
|
||||||
|
name = func.__name__
|
||||||
|
except:
|
||||||
|
raise TypeError(str(type(func)))
|
||||||
|
|
||||||
vals = {}
|
vals = {}
|
||||||
vals['topname'] = name
|
vals['topname'] = name
|
||||||
|
Loading…
x
Reference in New Issue
Block a user