童媱韩国电影 百度云:一个程序 加法器的 报错呀

来源:百度文库 编辑:高校问答 时间:2024/05/06 19:46:35
library ieee;
use ieee.std_logic_1164.all;
use ieee.std_logic_unsigned.all;
entity adder is
port(cin:in std_logic;
a,b:in std_logic_vector(3 downto 0);
s:out std_logic_vector(3 downto 0);
co:out std_logic);
end adder;
architecture behav of adder is
signal temp:std_logic_vector(4 downto 0);
begin
process(a,b,cin)
begin
temp<=('0'&a)+b+cin;
if(temp(3 downto 0)>9 or (temp(4)='1')then
s<=temp(3 downto 0)+6;
co<='1';
else
s<=temp(3 downto 0);
co<='0';
end if;
end process;
end behav;

error:unexpected end-of-file-try using the Text Editor's Syntax Coloring command to find the missing delimiter or keyword
楼上的是什么呀 有中文版吗