[Mono-bugs] [Bug 641146] New: Structural comparison of tuples

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Wed Sep 22 12:21:16 EDT 2010



           Summary: Structural comparison of tuples
    Classification: Mono
           Product: Mono: Class Libraries
           Version: 2.8.x
          Platform: Other
        OS/Version: Ubuntu
            Status: NEW
          Severity: Major
          Priority: P5 - None
         Component: System
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: laurentlb at gmail.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---
           Blocker: ---

User-Agent:       Mozilla/5.0 (X11; U; Linux x86_64; en-GB; rv:
Gecko/20100423 Ubuntu/10.04 (lucid) Firefox/3.6.3

Structural comparison of tuples is not implemented.

ubuntu% ~/mono-git-bin/bin/dmcs --version
Mono C# compiler version

ubuntu% ~/mono-git-bin/bin/mono -V
Mono JIT compiler version 2.8.1 (master/53fb1fb Thu Sep  9 18:40:27 BST 2010)
Copyright (C) 2002-2010 Novell, Inc and Contributors. www.mono-project.com
    TLS:           __thread
    SIGSEGV:       altstack
    Notifications: epoll
    Architecture:  amd64
    Disabled:      none
    Misc:          debugger softdebug 
    LLVM:          supported, not enabled.
    GC:            Included Boehm (with typed GC and Parallel Mark)

ubuntu% cat tuple.cs
using System;
using System.Collections;

namespace Test
  class Test
    public class myComparer : IComparer {
      int IComparer.Compare(Object x, Object y)  {
          return 0;

    static void Main(string[] args)
      Tuple<int, int> t1 = Tuple.Create(1, 2);
      Tuple<int, int> t2 = Tuple.Create(2, 3);
      int b = ((IStructuralComparable) t1).CompareTo(t2, new myComparer());

ubuntu% ~/mono-git-bin/bin/dmcs tuple.cs 
tuple.cs(18,11): warning CS0219: The variable `b' is assigned but its value is
never used
Compilation succeeded - 1 warning(s)

ubuntu% ~/mono-git-bin/bin/mono tuple.exe

Unhandled Exception: System.NotImplementedException: The requested feature is
not implemented.
(System.Object other, IComparer comparer) [0x00000] in <filename unknown>:0 
  at Test.Test.Main (System.String[] args) [0x00000] in <filename unknown>:0

Reproducible: Always

Steps to Reproduce:

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