aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2019-07-15 04:07:05 +0200
committerTristan Gingold <tgingold@free.fr>2019-07-15 04:07:05 +0200
commit7059373425a274869b5be2b9042578f410b12fe4 (patch)
treed97232b12a4314ac9ac809f69c98ed4c28d0bb5f
parent57af979704aab10b57c524003fb53343ec99615f (diff)
downloadghdl-7059373425a274869b5be2b9042578f410b12fe4.tar.gz
ghdl-7059373425a274869b5be2b9042578f410b12fe4.tar.bz2
ghdl-7059373425a274869b5be2b9042578f410b12fe4.zip
synth: apply block configuration to for-generate statements.
-rw-r--r--src/synth/synth-insts.adb17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/synth/synth-insts.adb b/src/synth/synth-insts.adb
index 74c4247c3..cdee1d7e7 100644
--- a/src/synth/synth-insts.adb
+++ b/src/synth/synth-insts.adb
@@ -732,8 +732,21 @@ package body Synth.Insts is
end loop;
end;
when Iir_Kind_Block_Configuration =>
- -- TODO
- raise Internal_Error;
+ declare
+ Sub_Blk : constant Node := Get_Block_From_Block_Specification
+ (Get_Block_Specification (Item));
+ begin
+ case Get_Kind (Sub_Blk) is
+ when Iir_Kind_Generate_Statement_Body =>
+ -- Linked chain.
+ Set_Prev_Block_Configuration
+ (Item, Get_Generate_Block_Configuration (Sub_Blk));
+ Set_Generate_Block_Configuration (Sub_Blk, Item);
+ when others =>
+ Vhdl.Errors.Error_Kind
+ ("apply_block_configuration(blk)", Sub_Blk);
+ end case;
+ end;
when others =>
Vhdl.Errors.Error_Kind ("apply_block_configuration", Item);
end case;