www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - DMD crash, wrong arg passed to new Exception

reply Derek Parnell <derek psych.ward> writes:
This <code>
void main()
{
    throw new Exception(new int);
}
</code>
Gives this error message:

test.d(3): constructor object.Exception.this (char[]) does not match
argument types (int*)

Then crashes DMD.
-- 
Derek Parnell
Melbourne, Australia
http://www.dsource.org/projects/build/ v2.06 released 04/May/2005
http://www.prowiki.org/wiki4d/wiki.cgi?FrontPage
5/05/2005 10:12:59 AM
May 04 2005
parent reply Derek Parnell <derek psych.ward> writes:
On Thu, 5 May 2005 10:13:26 +1000, Derek Parnell wrote:

Actually its worse than I first thought.

Any "does not match argument types" message causes a debug halt.

-- 
Derek
Melbourne, Australia
5/05/2005 10:27:59 AM
May 04 2005
parent zwang <nehzgnaw gmail.com> writes:
Derek Parnell wrote:
 On Thu, 5 May 2005 10:13:26 +1000, Derek Parnell wrote:
 
 Actually its worse than I first thought.
 
 Any "does not match argument types" message causes a debug halt.
 
src/dmd/func.c (1047) is the culprit.
May 04 2005