aboutsummaryrefslogtreecommitdiffstats
path: root/src/xtools
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2014-12-14 12:36:43 +0100
committerTristan Gingold <tgingold@free.fr>2014-12-14 12:36:43 +0100
commit51f657fde8d771ca5c4002ca70ad5175c6ef3cdf (patch)
treef5487dafd4682425ec2af9947fcac279153fc3ac /src/xtools
parentdf03d4120b0689b30dc4f629407d96b45b0db5a4 (diff)
downloadghdl-51f657fde8d771ca5c4002ca70ad5175c6ef3cdf.tar.gz
ghdl-51f657fde8d771ca5c4002ca70ad5175c6ef3cdf.tar.bz2
ghdl-51f657fde8d771ca5c4002ca70ad5175c6ef3cdf.zip
iirs: reduce size of signal_declaration.
Diffstat (limited to 'src/xtools')
-rwxr-xr-xsrc/xtools/pnodes.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/xtools/pnodes.py b/src/xtools/pnodes.py
index e00cf4d89..f62180208 100755
--- a/src/xtools/pnodes.py
+++ b/src/xtools/pnodes.py
@@ -696,9 +696,13 @@ elif args.action == 'meta_body':
print
for f in funcs:
gen_has_func_spec(f.name, ' is')
- print ' begin'
choices = [k for k in kinds if f.name in nodes[k].attrs]
- if len(choices) == 1:
+ if len(choices) == 0:
+ print ' pragma Unreferenced (K);'
+ print ' begin'
+ if len(choices) == 0:
+ print ' return False;'
+ elif len(choices) == 1:
print ' return K = ' + prefix_name + choices[0] + ';'
else:
print ' case K is'