M
mksuth
Guest
I'd like to use a function to compute the 'X downto Y' range of a
vector. Is there a clean way of doing this?
-- something like this would be nice:
function get_slice(n : natural) return range is
begin
return (n+1)*4 downto n*4;
end function
-- so I can use it on an slv like this:
a <= b(get_slice(2));
vector. Is there a clean way of doing this?
-- something like this would be nice:
function get_slice(n : natural) return range is
begin
return (n+1)*4 downto n*4;
end function
-- so I can use it on an slv like this:
a <= b(get_slice(2));