Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Zwinkau
libfirm
Commits
299d7e33
Commit
299d7e33
authored
Jan 08, 2013
by
Matthias Braun
Browse files
statev_sql: show a proper error message instead of a failing assert
parent
52ffa32c
Changes
1
Hide whitespace changes
Inline
Side-by-side
scripts/statev_sql.py
View file @
299d7e33
...
...
@@ -258,7 +258,9 @@ class Conv:
idstack
.
append
(
self
.
curr_id
)
keyidx
=
self
.
ctxcols
[
key
]
assert
self
.
ctxvals
[
keyidx
]
==
None
if
self
.
ctxvals
[
keyidx
]
!=
None
:
print
"Error: context key '%s' pushed multiple times"
%
key
sys
.
exit
(
1
)
self
.
ctxvals
[
keyidx
]
=
val
self
.
pushpending
=
True
...
...
@@ -281,7 +283,9 @@ class Conv:
print
"unmatched pop in line %d, push key %s, pop key: %s"
%
(
lineno
,
key
,
popkey
)
keyidx
=
self
.
ctxcols
[
key
]
assert
self
.
ctxvals
[
keyidx
]
!=
None
if
self
.
ctxvals
[
keyidx
]
==
None
:
print
"Error: context key '%s' popped before it was pushed"
%
popkey
sys
.
exit
(
1
)
self
.
ctxvals
[
keyidx
]
=
None
elif
op
==
'E'
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment