[Mono-bugs] [Bug 450151] New: Call to ToString fails
bugzilla_noreply at novell.com
bugzilla_noreply at novell.com
Fri Nov 28 12:37:29 EST 2008
https://bugzilla.novell.com/show_bug.cgi?id=450151
Summary: Call to ToString fails
Product: Mono: Compilers
Version: 2.0.x
Platform: Other
OS/Version: Other
Status: NEW
Severity: Normal
Priority: P5 - None
Component: C#
AssignedTo: mono-bugs at lists.ximian.com
ReportedBy: miguel at novell.com
QAContact: mono-bugs at lists.ximian.com
Found By: ---
The following program fails to compile, complaining that there is no ToString()
method that takes zero arguments. This is distilled from a larger program:
using System;
using System.Collections.Generic;
public abstract class AnyObjectId : IComparable<ObjectId>, IComparable
{
public override string ToString()
{
return "Foo";
}
}
public class ObjectId : AnyObjectId
{
public static string ToString (ObjectId i)
{
return i != null ? i.ToString() : "Foo";
}
}
The compiler reports:
ObjectId.cs(16): error CS1501: No overload for method `ToString' takes `0'
arguments
--
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.
More information about the mono-bugs
mailing list