aboutsummaryrefslogtreecommitdiffstats
path: root/testsuite/pyunit/Current.vhdl
diff options
context:
space:
mode:
authortgingold <tgingold@users.noreply.github.com>2021-06-20 16:58:55 +0200
committerGitHub <noreply@github.com>2021-06-20 16:58:55 +0200
commit37920daab7a1cdcdb7f6b54c2799d73b58634524 (patch)
tree8b68056072cdd34e47efa55aa629143552a55ba8 /testsuite/pyunit/Current.vhdl
parent603c44d06dd0b3f2f49af25045b46dd8aa72979a (diff)
parent3f3cf203c02671ab4d181d8d74aac2c3cc2c7c5c (diff)
downloadghdl-37920daab7a1cdcdb7f6b54c2799d73b58634524.tar.gz
ghdl-37920daab7a1cdcdb7f6b54c2799d73b58634524.tar.bz2
ghdl-37920daab7a1cdcdb7f6b54c2799d73b58634524.zip
Merge pull request #1798 from Paebbels/paebbels/aggregates
Python-C/Ada Bindings - Updated decorator
Diffstat (limited to 'testsuite/pyunit/Current.vhdl')
-rw-r--r--testsuite/pyunit/Current.vhdl53
1 files changed, 53 insertions, 0 deletions
diff --git a/testsuite/pyunit/Current.vhdl b/testsuite/pyunit/Current.vhdl
new file mode 100644
index 000000000..5a677546e
--- /dev/null
+++ b/testsuite/pyunit/Current.vhdl
@@ -0,0 +1,53 @@
+library ieee;
+use ieee.std_logic_1164.all;
+use ieee.numeric_std.all;
+
+entity entity_1 is
+ generic (
+ FREQ : real := 100.0;
+ BITS : positive := 8
+ );
+ port (
+ Clock: in std_logic;
+ Reset: in std_logic := '0';
+ Q: out std_logic_vector(BITS - 1 downto 0)
+ );
+
+ constant fire : boolean := True;
+begin
+ wood <= fire;
+end entity entity_1;
+
+architecture behav of entity_1 is
+ constant MAX : positive := -25;
+ signal rst : std_logic := 'U';
+
+ type newInt is range -4 to 3;
+ subtype uint8 is integer range 0 to 255;
+
+ function foo(a : integer; b : boolean) return bit is
+ begin
+
+ end function;
+
+ alias bar is boolean;
+begin
+ process(Clock)
+ begin
+ if rising_edge(Clock) then
+ if Reset = '1' then
+ Q <= (others => '0');
+ else
+ Q <= std_logic_vector(unsigned(Q) + 1);
+ end if;
+ end if;
+ end process;
+end architecture behav;
+
+package package_1 is
+ constant ghdl : float := (3, 5, 0 => 5, 3 => 4, name => 10); -- 2.3;
+end package;
+
+package body package_1 is
+ constant ghdl : float := (1); -- => 2, 4 => 5, others => 10); -- .5;
+end package body;