[nem-bug] [Nemerle 0001020]: NullReferenceException in "is" matching operator

feedback at nemerle.org feedback at nemerle.org
Mon May 28 10:43:13 CEST 2007


The following issue has been RESOLVED.
======================================================================
<http://nemerle.org/bugs/view.php?id=1020> 
======================================================================
Reported By:                VladD2
Assigned To:                malekith
======================================================================
Project:                    Nemerle
Issue ID:                   1020
Category:                   Code Completion Engine
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     resolved
Resolution:                 duplicate
Duplicate:                  929
Fixed in Version:           
======================================================================
Date Submitted:             05-26-2007 12:39 CEST
Last Modified:              05-28-2007 10:43 CEST
======================================================================
Summary:                    NullReferenceException in "is" matching operator
Description: 
If try match nulled variable whose type is "variant option type"
NullReferenceException throw:

using System.Console;
using Nemerle.Utility;

variant Test
{
  | A
  | B { next : Test; }
}

module Program
{
  Main() : void
  {
    def x : Test.B = null;
    WriteLine(x is Test.B(Test.A)); // NullReferenceException 
  }
}
======================================================================
Relationships       ID      Summary
----------------------------------------------------------------------
duplicate of        0000929 Pattern matching cannot handle nulls co...
======================================================================

----------------------------------------------------------------------
 malekith - 05-28-07 10:41 
----------------------------------------------------------------------
This exactly the same as what happens with normal matching. There is a bug
report/feature request to change it somewhere...

Issue History
Date Modified  Username       Field                    Change              
======================================================================
05-26-07 12:39 VladD2         New Issue                                    
05-28-07 10:41 malekith       Note Added: 0001911                          
05-28-07 10:43 malekith       Relationship added       duplicate of 0000929
05-28-07 10:43 malekith       Duplicate ID             0 => 929            
05-28-07 10:43 malekith       Status                   new => resolved     
05-28-07 10:43 malekith       Resolution               open => duplicate   
05-28-07 10:43 malekith       Assigned To               => malekith        
======================================================================




More information about the bugs mailing list