[Mono-list] Concatenation Bug

Radu-Adrian Popescu radu.popescu@aldratech.com
Thu, 4 Apr 2002 10:30:51 +0300


This is a multi-part message in MIME format.

------=_NextPart_000_006A_01C1DBC3.CAD29AB0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable


----- Original Message -----=20
From: "Daniel Carrera" <dcarrera@math.toronto.edu>
To: "Mono Mailing List" <mono-list@ximian.com>
Sent: Friday, April 05, 2002 02:47
Subject: [Mono-list] Concatenation Bug


> Hello,
>=20
> I still can't fix the problem.  There is a bug somewhere and I don't =
think
> that it's been fixed.  I have dowloaded the latest CVS for mono and it
> dind't help.  I built mcs myself and it didn't help.
>=20
> Could someone look at my files.  I'm including both the .cs and the =
.exe
> files.  I'd appreciate it if someone could do any of:
>=20
> a.- Try running my .exe file and see if you get the error.
> b.- Try compiling my .cs file and see if you get the error when you =
run
>     it.
> c.- Do a. and b. under Windows and see if it makes any difference.
>=20
> I don't have Windows myself, so I can't try this with the Microsoft =
SDK.
>=20
>=20
> For reference, the error I get is:
>=20
> $ mono ConcatTest.exe
>=20
> (process:20458): ** WARNING **: unhandled exception
> System.OverflowException: "Number overflow"
> in System.String:.ctor ()
> in System.String:Concat ()
> in .TestMoney:Main ()

I've tested it with LINUX (MONO 0.10, distribution (not CVS)) and =
WINDOWS Visual C# .NET Compiler version 7.00.9466 for Microsoft (R) .NET =
Framework version 1.0.3705)
    1. Compile the source code with mcs/linux and run with
        1.1. mint : no errors (output : "Currency:  CAD")
        1.2. mono : error as in your test
        1.3. .net framework sdk  : does not run mcs/linux binaries
    2. Compile the source code with csc/windows and run with=20
        2.1.1. .net framework sdk : no errors
        2.1.2. mint : no errors
        2.1.3. mono : no errors
So, it seems that the problem is definitely mono/mcs related.
Please notice that mint is able to run both binaries, while mono only =
the csc/windows generated one.


------=_NextPart_000_006A_01C1DBC3.CAD29AB0
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2715.400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2>----- Original Message ----- </FONT>
<DIV><FONT size=3D2>From: "Daniel Carrera" &lt;</FONT><A=20
href=3D"mailto:dcarrera@math.toronto.edu"><FONT=20
size=3D2>dcarrera@math.toronto.edu</FONT></A><FONT =
size=3D2>&gt;</FONT></DIV>
<DIV><FONT size=3D2>To: "Mono Mailing List" &lt;</FONT><A=20
href=3D"mailto:mono-list@ximian.com"><FONT=20
size=3D2>mono-list@ximian.com</FONT></A><FONT size=3D2>&gt;</FONT></DIV>
<DIV><FONT size=3D2>Sent: Friday, April 05, 2002 02:47</FONT></DIV>
<DIV><FONT size=3D2>Subject: [Mono-list] Concatenation =
Bug</FONT></DIV></DIV>
<DIV><FONT size=3D2><BR></FONT></DIV>
<DIV><FONT size=3D2>&gt; Hello,<BR>&gt; <BR>&gt; I still can't fix the=20
problem.&nbsp; There is a bug somewhere and I don't think<BR>&gt; that =
it's been=20
fixed.&nbsp; I have dowloaded the latest CVS for mono and it<BR>&gt; =
dind't=20
help.&nbsp; I built mcs myself and it didn't help.<BR>&gt; <BR>&gt; =
Could=20
someone look at my files.&nbsp; I'm including both the .cs and the =
.exe<BR>&gt;=20
files.&nbsp; I'd appreciate it if someone could do any of:<BR>&gt; =
<BR>&gt; a.-=20
Try running my .exe file and see if you get the error.<BR>&gt; b.- Try =
compiling=20
my .cs file and see if you get the error when you run<BR>&gt; =
&nbsp;&nbsp;&nbsp;=20
it.<BR>&gt; c.- Do a. and b. under Windows and see if it makes any=20
difference.<BR>&gt; <BR>&gt; I don't have Windows myself, so I can't try =
this=20
with the Microsoft SDK.<BR>&gt; <BR>&gt; <BR>&gt; For reference, the =
error I get=20
is:<BR>&gt; <BR>&gt; $ mono ConcatTest.exe<BR>&gt; <BR>&gt; =
(process:20458): **=20
WARNING **: unhandled exception<BR>&gt; System.OverflowException: =
"Number=20
overflow"<BR>&gt; in System.String:.ctor ()<BR>&gt; in =
System.String:Concat=20
()<BR>&gt; in .TestMoney:Main ()<BR></FONT></DIV>
<DIV><FONT size=3D2>I've tested it with&nbsp;</FONT><FONT=20
size=3D2><STRONG>LINUX</STRONG> (<STRONG>MONO 0.10</STRONG>, =
distribution (not=20
CVS)) and <FONT size=3D2><STRONG>WINDOWS</STRONG> <STRONG>Visual C# .NET =
Compiler=20
version 7.00.9466 for Microsoft (R) .NET Framework version=20
1.0.3705</STRONG>)</FONT></FONT></DIV>
<DIV><FONT size=3D2>&nbsp;&nbsp;&nbsp; 1. Compile the source code with=20
<STRONG>mcs/linux</STRONG> and run with</FONT></DIV>
<DIV><FONT size=3D2>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; 1.1.=20
<STRONG>mint</STRONG> : no errors (output : "Currency:&nbsp; =
CAD")</FONT></DIV>
<DIV><FONT size=3D2>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; 1.2.=20
<STRONG>mono</STRONG> : error as in your test</FONT></DIV>
<DIV><FONT size=3D2>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; 1.3.=20
<STRONG>.net</STRONG> framework sdk&nbsp; : does not run mcs/linux=20
binaries</FONT></DIV>
<DIV>
<DIV><FONT size=3D2>&nbsp;&nbsp;&nbsp; 2. Compile the source code with=20
<STRONG>csc/windows</STRONG> and run with </FONT></DIV>
<DIV><FONT size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
2.1.1.&nbsp;<STRONG>.net</STRONG> framework sdk : no errors</FONT></DIV>
<DIV><FONT size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2.1.2.=20
<STRONG>mint</STRONG> : no errors</FONT></DIV>
<DIV><FONT size=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2.1.3.=20
<STRONG>mono</STRONG> : no errors</FONT></DIV>
<DIV><FONT size=3D2>So, it seems that the problem is definitely mono/mcs =

related.</FONT></DIV>
<DIV><FONT size=3D2>Please notice that mint is able to run both =
binaries, while=20
mono only the csc/windows generated one.</FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV></DIV></BODY></HTML>

------=_NextPart_000_006A_01C1DBC3.CAD29AB0--