[MonoDevelop] Problems with implicit conversions in Mono 4.0
Sérgio Estêvão
sergioestevao at gmail.com
Tue Oct 26 11:47:45 EDT 2010
Hi All,
I'm having the following problem with Mono 4.0 ( 2.8.0). I have the class
called Real (check attachment)
that has an implicit cast between Real and float.
The problem is when I try to compare a Real with a float, like in the
following example:
Real a = 10.0;
float b = 5.0f;
if ( a >= b) {
....
}
I get the following error:
Error CS0121: The call is ambiguous between the following methods or
properties: `Axiom.Math.Real.operator >=(Axiom.Math.Real, Axiom.Math.Real)'
and `float.operator >=(float, float)' (CS0121) (Axiom.2010)
This doesn't happen with Mono 3.5 and with Microsoft .Net 4.0
Any ideas?
Sérgio Estêvão
http://www.sergioestevao.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/monodevelop-list/attachments/20101026/74cdecc8/attachment-0001.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Real.cs
Type: application/octet-stream
Size: 23874 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/monodevelop-list/attachments/20101026/74cdecc8/attachment-0001.obj
More information about the Monodevelop-list
mailing list