diff options
author | Tristan Gingold <tgingold@free.fr> | 2021-11-28 18:13:47 +0100 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2021-11-28 18:13:47 +0100 |
commit | 2f9ff04b013cd837936c4bbeef0f25ef9445e14a (patch) | |
tree | ea2b1174739ae8dc9caf59b006f219ffd5c38424 /src/synth/elab-vhdl_insts.adb | |
parent | 852b1e064f81c7c7108c45847872a266e995d31c (diff) | |
download | ghdl-2f9ff04b013cd837936c4bbeef0f25ef9445e14a.tar.gz ghdl-2f9ff04b013cd837936c4bbeef0f25ef9445e14a.tar.bz2 ghdl-2f9ff04b013cd837936c4bbeef0f25ef9445e14a.zip |
elab-vhdl_insts.adb: do not try to elaborate foreign instances twice
Diffstat (limited to 'src/synth/elab-vhdl_insts.adb')
-rw-r--r-- | src/synth/elab-vhdl_insts.adb | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/synth/elab-vhdl_insts.adb b/src/synth/elab-vhdl_insts.adb index 19b02a745..eb8d6b124 100644 --- a/src/synth/elab-vhdl_insts.adb +++ b/src/synth/elab-vhdl_insts.adb @@ -509,8 +509,13 @@ package body Elab.Vhdl_Insts is is Arch : constant Node := Get_Source_Scope (Syn_Inst); Config : constant Node := Get_Instance_Config (Syn_Inst); - Entity : constant Node := Get_Entity (Arch); + Entity : Node; begin + if Get_Kind (Arch) = Iir_Kind_Foreign_Module then + return; + end if; + + Entity := Get_Entity (Arch); Apply_Block_Configuration (Config, Arch); Elab_Declarations (Syn_Inst, Get_Declaration_Chain (Entity)); |