projects
/
openpower-isa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0be3bbe
)
oppc/code: support leave keyword
author
Dmitry Selyutin
<ghostmansd@gmail.com>
Sun, 14 Jan 2024 14:43:19 +0000
(17:43 +0300)
committer
Dmitry Selyutin
<ghostmansd@gmail.com>
Tue, 16 Jan 2024 19:10:07 +0000
(22:10 +0300)
src/openpower/oppc/pc_code.py
patch
|
blob
|
history
diff --git
a/src/openpower/oppc/pc_code.py
b/src/openpower/oppc/pc_code.py
index bbacaff1464976c1f17be9aa59b5998e150f6efc..22adf1e51427006a8b85a6c2f9d646818b08baf6 100644
(file)
--- a/
src/openpower/oppc/pc_code.py
+++ b/
src/openpower/oppc/pc_code.py
@@
-462,6
+462,11
@@
class CodeVisitor(pc_util.Visitor):
yield node
self[node].emit(stmt=str(node))
+ @pc_util.Hook(pc_ast.LeaveKeyword)
+ def LeaveKeyword(self, node):
+ yield node
+ self[node].emit(stmt="break;")
+
@pc_util.Hook(pc_ast.Call.Name)
def CallName(self, node):
yield node