aboutsummaryrefslogtreecommitdiffstats
path: root/testsuite/gna/issue641/ent.vhdl
blob: 27e8bf7322b486c4dc52a1ae2e72658573084183 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
-- Helper package
library ieee;
use     ieee.std_logic_1164.all;

package p is
	type BusRecord is record
		Address : std_logic_vector;
		Data    : std_logic_vector;
	end record;
end package;

-- DUT
library ieee;
use     ieee.std_logic_1164.all;
use     work.p.all;

entity e is
	port (
		Axi : inout BusRecord
	);
end entity;

architecture a of e is
	alias  AxiData is Axi.Data;

	signal Address : std_logic_vector(Axi.Address'range);
	signal Data1   : AxiData'subtype;    -- line 27: declaration of signal "data1" with unconstrained array subtype "std_logic_vector" is not allowed
	signal Data2   : Axi.Data'subtype;   -- line 28: prefix must denote an object; a type mark must be a simple or expanded name
begin

end architecture;

-- Top Level
library ieee;
use     ieee.std_logic_1164.all;
use     work.p.all;

entity test is
end entity;

architecture tb of test is
	signal AxiBus : BusRecord(
		Address(7 downto 0),
		Data(31 downto 0)
	);
begin
	DUT: entity work.e
		port map (
			Axi => AxiBus
		);
end architecture;