Commit 626ccb50 authored by Martin Jeřábek's avatar Martin Jeřábek

testfw: ghw_parse: fix stupid errors

parent 52d3b2f3
Pipeline #6712 passed with stages
in 13 minutes and 36 seconds
......@@ -74,7 +74,7 @@ def parse(s: str) -> dict:
curr_ws = 0
last = dict()
stack = [last]
for i, line in enumerate(lines[:4096]):
for i, line in enumerate(lines):
l = line.lstrip()
if not l:
continue
......
......@@ -81,11 +81,11 @@ class TclFuncs:
self.format = 'hex'
self.signal = None
self.isdivider = False
self.group = None
self.expand = False
self.color = None
def __init__(self):
self.group = None
self.reset()
@staticmethod
......@@ -145,8 +145,10 @@ class TclFuncs:
pass
elif a0 == '-group':
if o.group:
log.debug('Closing group {}'.format(o.group))
self.gtkw.end_group(o.group, closed=False)
o.group = args[i]
log.debug('Opening group {}'.format(o.group))
self.gtkw.begin_group(o.group, closed=False)
i += 1
elif a0[0] == '-':
......@@ -164,6 +166,7 @@ class TclFuncs:
self._add_trace(signal, type, label=o.label, datafmt=o.format, expand=o.expand, color=o.color)
o.reset()
if o.group:
log.debug('Closing group {}'.format(o.group))
self.gtkw.end_group(o.group)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment