aboutsummaryrefslogtreecommitdiffstats
path: root/testsuite/gna/issue413/e.vhdl
blob: d348ee1b58792119fb9baa617af4e2efe12993ea (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
library ieee;
use ieee.std_logic_1164.all;
use ieee.numeric_std.all;

entity e is
end entity;

architecture arch of e is
	type t_record is record
		int : integer;
	end record;

	function conversion(slv : std_ulogic_vector) return t_record is
		variable ret : t_record;
	begin
		ret.int := to_integer(unsigned(slv));
		return ret;
	end;

	signal slv : std_ulogic_vector(127 downto 0);
	alias alias_record : t_record is conversion(slv);

	signal s_int : integer := alias_record.int;
begin
end architecture;