[nem-bug] [Nemerle 0000569]: list/Nil/Cons mismatch with local generic function

feedback at nemerle.org feedback at nemerle.org
Sat Nov 12 13:40:12 CET 2005


The following issue has been SUBMITTED.
======================================================================
<http://nemerle.org/bugs/view.php?id=569> 
======================================================================
Reported By:                malekith
Assigned To:                
======================================================================
Project:                    Nemerle
Issue ID:                   569
Category:                   Compiler (type engine)
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     new
======================================================================
Date Submitted:             11-12-2005 13:40 CET
Last Modified:              11-12-2005 13:40 CET
======================================================================
Summary:                    list/Nil/Cons mismatch with local generic function
Description: 
def isSorted[Element](sequence) where Element: System.IComparable[Element]
{
  | head::nextOne::tail =>
    isSorted(nextOne::tail) && (head: Element).CompareTo(nextOne: Element)
!= 1
  | []
  | _::[] => true
}

isSorted ([1,2,3]);

======================================================================

Issue History
Date Modified  Username       Field                    Change              
======================================================================
11-12-05 13:40 malekith       New Issue                                    
======================================================================




More information about the bugs mailing list