N
Nick Bayard
Guest
I'm getting some odd results when I try to use an aggregate expression to pack several unsigned vectors. I get the error. "This expression must be of a locally static subtype. Invalid aggregate." If I use the concatenate operator (commented below), it seems to compile file. Is this bug from my vendor tool (Aldec) or is there some reason I can't use to_unsigned in an aggregate? Thanks.
library IEEE;
use IEEE.std_logic_1164.all;
use IEEE.numeric_std.all;
entity my_entity is
port
(
output : out unsigned(39 downto 0)
);
end;
architecture my_arch of my_entity is
signal int1 : integer := 0;
signal int2 : integer := 0;
signal us1 : unsigned(9 downto 0) := (others => '0');
signal us2 : unsigned(9 downto 0) := (others => '0');
begin
output <= (to_unsigned(int1,10), to_unsigned(int2,10), us1, us2);
--output <= to_unsigned(int1,10) & to_unsigned(int2,10) & us1 & us2;
end;
library IEEE;
use IEEE.std_logic_1164.all;
use IEEE.numeric_std.all;
entity my_entity is
port
(
output : out unsigned(39 downto 0)
);
end;
architecture my_arch of my_entity is
signal int1 : integer := 0;
signal int2 : integer := 0;
signal us1 : unsigned(9 downto 0) := (others => '0');
signal us2 : unsigned(9 downto 0) := (others => '0');
begin
output <= (to_unsigned(int1,10), to_unsigned(int2,10), us1, us2);
--output <= to_unsigned(int1,10) & to_unsigned(int2,10) & us1 & us2;
end;