-
-
Notifications
You must be signed in to change notification settings - Fork 80
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement 'last_value for record types. Fixes #1043
- Loading branch information
Showing
4 changed files
with
79 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
entity issue1043 is | ||
end entity; | ||
|
||
architecture test of issue1043 is | ||
type t_rec is record | ||
x : integer; | ||
y : real; | ||
end record; | ||
|
||
type t_array is array (natural range <>) of t_rec; | ||
|
||
signal s : t_rec := (6, 42.0); | ||
signal t : t_array(1 to 3) := (others => (0, 0.0)); | ||
begin | ||
|
||
process is | ||
begin | ||
assert s'last_value = (6, 42.0); | ||
assert t'last_value(1) = (0, 0.0); | ||
s <= (4, 22.0); | ||
wait for 1 ns; | ||
assert s'last_value.x = 6; | ||
t(3) <= (8, 55.0); | ||
wait for 1 ns; | ||
assert t'last_value = (1 to 3 => (0, 0.0)); | ||
wait; | ||
end process; | ||
|
||
end architecture; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1060,3 +1060,4 @@ vlog12 verilog | |
conv15 normal | ||
cover25 cover=functional | ||
issue1035 normal,vhpi,2008 | ||
issue1043 normal |