Bug 317516 (MONO73992) - [GMCS] can't resolve overloaded methods that implement generic interfaces
Summary: [GMCS] can't resolve overloaded methods that implement generic interfaces
Status: RESOLVED FIXED
Alias: MONO73992
Product: Mono: Compilers
Classification: Mono
Component: C# (show other bugs)
Version: 1.1
Hardware: Other Other
: P3 - Medium : Normal
Target Milestone: ---
Assignee: Martin Baulig
QA Contact: Mono Bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-23 06:31 UTC by Atsushi Enomoto
Modified: 2007-09-15 21:24 UTC (History)
0 users

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Wiest 2007-09-15 19:11:21 UTC


---- Reported by atsushi@ximian.com 2005-03-22 23:31:39 MST ----

gmcs cannot resolve overloaded methods that implement different generic
interfaces.

Steps to reproduce the problem:

Compile this example with gmcs.

----
using System;
static class Test1 {
  public interface IOp<T> {
    T Func(uint v);
  }
  public struct Op : IOp<ushort>, IOp<uint> {
    ushort IOp<ushort>.Func(uint v) { return (ushort )(v * 2); }
    uint IOp<uint>.Func(uint v) { return v * 4; }
  }
  static public void Main() {
  }
};

Actual Results:
$ gmcs generic-overload.cs
generic-overload.cs(7) error CS0111: Type 'Test1.Op' already defines a
member called 'IOp.Func' with the same parameter types
generic-overload.cs(8): 'Test1.Op.Test1+IOp`1.Func( uint)' (name of symbol
related to previous error
Compilation failed: 1 error(s), 0 warnings

Expected Results:
no error.

How often does this happen? 
consistently.



---- Additional Comments From martin@ximian.com 2005-04-29 08:32:39 MST ----

Fixed in SVN.

This bug blocked bug(s) 73995.

Unknown operating system unknown. Setting to default OS "Other".