[nem-bug] [Nemerle 0001009]: Incorrect type lookup if exists type with and without type parameters

feedback at nemerle.org feedback at nemerle.org
Sat May 5 14:14:00 CEST 2007


The following issue has been SUBMITTED.
======================================================================
<http://nemerle.org/bugs/view.php?id=1009> 
======================================================================
Reported By:                VladD2
Assigned To:                
======================================================================
Project:                    Nemerle
Issue ID:                   1009
Category:                   Compiler (type engine)
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     new
======================================================================
Date Submitted:             05-05-2007 14:14 CEST
Last Modified:              05-05-2007 14:14 CEST
======================================================================
Summary:                    Incorrect type lookup if exists type with and
without type parameters
Description: 
using System.Console;


class A
{
  public static Test1() : void {  }
}

class A[T]
{
  public static Test2() : void {  }
}

module Program
{
  Main() : void
  {
    A.Test1();       //E: unbound name 'Test1' in 'A'
    A.[int].Test2();
  }
}
In this example typer recognize 'A' as A[T].
See line 310 of
http://nemerle.org/svn/nemerle/trunk/ncc/hierarchy/GlobalEnv.n
for detailes.
The pref.LookupType (type_part, -1) return firste defined type (which is
A[T]).
======================================================================

Issue History
Date Modified  Username       Field                    Change              
======================================================================
05-05-07 14:14 VladD2         New Issue                                    
======================================================================




More information about the bugs mailing list