let me try that again...


Subject: let me try that again...
From: Rob Anderson (rob@reawebtech.com)
Date: Fri Aug 16 2002 - 19:40:15 PDT


Alex you are right about the C. I forgot we were doing ADA.

function "+"(L:unsigned; R:std_logic) return unsigned;
     constant SIZE: NATURAL := L'LENGTH;
     variable L01 : UNSIGNED(SIZE-1 downto 0);
     variable R01 : UNSIGNED(SIZE-1 downto 0) := (others=>'0');
   begin
     if (L'LENGTH < 1) then return NAU;
     end if;
     if ((L01(L01'LEFT) = 'X') or (R = 'X')) then
       R01 := (others => 'X');
       return R01;
     else return ADD_UNSIGNED(L01, R01, R);
     end if;
   end "+";

How's that?

BTW guys I will be away until the following Saturday
and I cannot get to this mail.

Meanwhile, an volunteer testcases? Well I will probably see
Jim Lewis this week so I can bug him in person :-)

cheers, Rob



This archive was generated by hypermail 2b28 : Fri Aug 16 2002 - 19:38:18 PDT