mirror of
https://github.com/verilator/verilator.git
synced 2025-01-01 04:07:34 +00:00
Fix latest pylint issues (#5465)
This commit is contained in:
parent
dd95e033e7
commit
62a58f420c
@ -135,8 +135,7 @@ def profcfunc(filename):
|
|||||||
|
|
||||||
design_width = 1
|
design_width = 1
|
||||||
for func, func_item in vfuncs.items():
|
for func, func_item in vfuncs.items():
|
||||||
if design_width < len(func_item['design']):
|
design_width = max(design_width, len(func_item['design']))
|
||||||
design_width = len(func_item['design'])
|
|
||||||
|
|
||||||
print("Verilog code profile:")
|
print("Verilog code profile:")
|
||||||
print(" These are split into three categories:")
|
print(" These are split into three categories:")
|
||||||
|
@ -852,6 +852,10 @@ def write_type_tests(prefix, nodeList):
|
|||||||
base = "DfgVertex"
|
base = "DfgVertex"
|
||||||
variable = "vtxp"
|
variable = "vtxp"
|
||||||
enum = "VDfgType"
|
enum = "VDfgType"
|
||||||
|
else:
|
||||||
|
base = None
|
||||||
|
variable = None
|
||||||
|
enum = None
|
||||||
for node in nodeList:
|
for node in nodeList:
|
||||||
fh.write(
|
fh.write(
|
||||||
"template<> inline bool {b}::privateTypeTest<{p}{n}>(const {b}* {v}) {{ ".format(
|
"template<> inline bool {b}::privateTypeTest<{p}{n}>(const {b}* {v}) {{ ".format(
|
||||||
|
@ -11,11 +11,12 @@ import sys
|
|||||||
|
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
|
Bison_Version = None
|
||||||
|
|
||||||
|
|
||||||
def process():
|
def process():
|
||||||
unlink_outputs()
|
unlink_outputs()
|
||||||
|
|
||||||
bison_version_check()
|
|
||||||
supports_report = Bison_Version >= 2.3
|
supports_report = Bison_Version >= 2.3
|
||||||
# supports_counter_examples = Bison_Version >= 3.8
|
# supports_counter_examples = Bison_Version >= 3.8
|
||||||
|
|
||||||
@ -93,9 +94,7 @@ def bison_version_check():
|
|||||||
if v < 1.875:
|
if v < 1.875:
|
||||||
sys.exit("bisonpre: %Error: '" + Args.yacc + "' is version " + v +
|
sys.exit("bisonpre: %Error: '" + Args.yacc + "' is version " + v +
|
||||||
"; version 1.875 or newer is required\n")
|
"; version 1.875 or newer is required\n")
|
||||||
global Bison_Version # pylint: disable=global-variable-undefined
|
return v
|
||||||
Bison_Version = v
|
|
||||||
return
|
|
||||||
|
|
||||||
sys.exit("bisonpre: %Error: '" + Args.yacc + "' is not installed, or not working\n")
|
sys.exit("bisonpre: %Error: '" + Args.yacc + "' is not installed, or not working\n")
|
||||||
|
|
||||||
@ -515,6 +514,8 @@ parser.add_argument('input', help='Passed to bison. Input grammar file.')
|
|||||||
|
|
||||||
Args = parser.parse_args()
|
Args = parser.parse_args()
|
||||||
|
|
||||||
|
Bison_Version = bison_version_check()
|
||||||
|
|
||||||
process()
|
process()
|
||||||
|
|
||||||
######################################################################
|
######################################################################
|
||||||
|
Loading…
Reference in New Issue
Block a user