mirror of
https://github.com/VLSIDA/OpenRAM.git
synced 2026-08-30 09:58:33 +02:00
Drop to debug in debug module when -d
This commit is contained in:
@@ -16,6 +16,9 @@ import sys
|
||||
# 2 = verbose
|
||||
# n = custom setting
|
||||
|
||||
import globals
|
||||
import pdb
|
||||
|
||||
|
||||
def check(check, str):
|
||||
if not check:
|
||||
@@ -26,6 +29,9 @@ def check(check, str):
|
||||
log("ERROR: file {0}: line {1}: {2}\n".format(
|
||||
os.path.basename(filename), line_number, str))
|
||||
|
||||
if globals.OPTS.debug:
|
||||
pdb.set_trace()
|
||||
|
||||
assert 0
|
||||
|
||||
|
||||
@@ -37,6 +43,9 @@ def error(str, return_value=0):
|
||||
log("ERROR: file {0}: line {1}: {2}\n".format(
|
||||
os.path.basename(filename), line_number, str))
|
||||
|
||||
if globals.OPTS.debug:
|
||||
pdb.set_trace()
|
||||
|
||||
assert return_value == 0
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user