mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-22 16:45:32 +00:00
pyosys generator: ignore attributes
* this allows log_error, log_file_error and log_cmd_error which are all marked [[noreturn]] to be supported
This commit is contained in:
parent
b2d78589e2
commit
de728c9824
1 changed files with 5 additions and 0 deletions
|
@ -1268,6 +1268,11 @@ class WFunction:
|
|||
func.duplicate = False
|
||||
func.namespace = namespace
|
||||
str_def = str_def.replace("operator ","operator")
|
||||
|
||||
# remove attributes from the start
|
||||
if str.startswith(str_def, "[[") and "]]" in str_def:
|
||||
str_def = str_def[str_def.find("]]")+2:]
|
||||
|
||||
if str.startswith(str_def, "static "):
|
||||
func.is_static = True
|
||||
str_def = str_def[7:]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue