From: Anders Nordstrom (andersn@nortelnetworks.com)
Date: Thu Jun 24 1999 - 07:50:18 PDT
BAD MSG:
BTF Team,
ontent-Length: 2454
X-Lines: 104
X-Status: $$$$
X-UID: 0000000972
Status: RO
Please review the enclosed proposal for errata BE84 and vote to the reflector via email before
June 30.
Regards,
Anders
<x-html><HTML>
<HEAD>
<TITLE> BE84 </TITLE>
</HEAD>
<BODY BGCOLOR="#FFFFFF">
<BR>
<HR SIZE=5 NOSHADE>
<H2> BE84 - Function and Register Name Errata</H2>
<TABLE BORDER COLS=2 WIDTH="75%" >
<TR><TD>
Section: </TD><TD> 10.3.1 and 10.3.2 (Draft 2)
</TD></TR><TR><TD>
Date Submitted: </TD><TD> 990429
</TD></TR><TR><TD>
Requestor: </TD><TD> Mike McNamara
</TD></TR><TR><TD>
Status: </TD><TD> Proposal
</TD></TR><TR><TD>
Analyzed by: </TD><TD> Mike McNamara & Anders Nordstrom
</TD></TR>
</TABLE>
<H3> Details </H3>
One of our users just got tripped up by this one. I looked in the
standard, but it is not clear.
<BR>
They had code that essentially was:
<PRE>
module test(a,b,c);
input [7:0] a;
input [2:0] b;
output [2 : 0] c ;
assign c = problem(a,b);
function [2 : 0] problem ;
input [7 : 0] a ;
input [2 : 0] b ;
reg [2 : 0] problem ;
begin
problem = b + a;
end
endfunction
endmodule
</PRE>
VCS happily accepts this code, VXL gives an error message.
Of course VXL is right, we all know that you cannot define a register
with the same name as the function, because, in truth, there is
already one implicitly defined by defining the register.
I feel we should add language that explicitly states that one cannot
declare another object with the same name as a function in the scope
where the function is declared (I.E, in the module) or inside the
function.
-mac
<PRE>
From: asingh@cupertino.synopsys.com (Ajay Singh)
To: spear@synopsys.com, vcs_support@synopsys.com, btf@boyd.com
Subject: Re: vcs/18556 : Function contains register with same name
</PRE>
Hello Chris Spear,
An Enhancement request TR 3323 is filed for this PR.
I am closing this PR for now.
Thanks,
Ajay
<p><H3> Proposal </H3>
Before the last sentence in section 10.3.2 on page 144 in Draft 2 add:
It is illegal to declare another object with the same name as the
function in the scope where the function is declared or inside
the function.
I also found another minor errata in section 10.3.1 of Draft 2 only.
Change the word <B>endtask</B> to the word <B>endfunction</B> on the
third line in the section below Syntax 10-3 on page 143 of Draft 2.
<HR SIZE=5 NOSHADE>
</BODY>
</HTML>
</x-html>
Attachment Converted: "E:\INCOMING\andersn2.vcf"
This archive was generated by hypermail 2.1.4
: Mon Jul 08 2002 - 12:53:28 PDT
and
sponsored by Boyd Technology, Inc.