[Mono-dev] Compiler crashes

keks-n keks9n at gmail.com
Tue Jul 26 06:50:48 EDT 2011


$ gmcs lol.cs

Unhandled Exception: System.NullReferenceException: Object reference not set
to an instance of an object
  at Mono.CSharp.TypeParameterInflator.Inflate (Mono.CSharp.TypeSpec type)
[0x00000] in <filename unknown>:0 
  at Mono.CSharp.InflatedTypeSpec.InitializeMemberCache (Boolean onlyTypes)
[0x00000] in <filename unknown>:0 
  at Mono.CSharp.InflatedTypeSpec.get_BaseType () [0x00000] in <filename
unknown>:0 
  at Mono.CSharp.MemberAccess.ResolveNamespaceOrType (IMemberContext rc,
Boolean silent) [0x00000] in <filename unknown>:0 
  at Mono.CSharp.MemberAccess.ResolveAsTypeStep (IMemberContext ec, Boolean
silent) [0x00000] in <filename unknown>:0 
  at Mono.CSharp.Expression.ResolveAsTypeTerminal (IMemberContext ec,
Boolean silent) [0x00000] in <filename unknown>:0 
  at Mono.CSharp.TypeArguments.Resolve (IMemberContext ec) [0x00000] in
<filename unknown>:0 
  at Mono.CSharp.GenericTypeExpr.DoResolveAsTypeStep (IMemberContext ec)
[0x00000] in <filename unknown>:0 
  at Mono.CSharp.TypeExpr.ResolveAsTypeStep (IMemberContext ec, Boolean
silent) [0x00000] in <filename unknown>:0 
  at Mono.CSharp.MemberAccess.ResolveNamespaceOrType (IMemberContext rc,
Boolean silent) [0x00000] in <filename unknown>:0 
  at Mono.CSharp.MemberAccess.ResolveAsTypeStep (IMemberContext ec, Boolean
silent) [0x00000] in <filename unknown>:0 
  at Mono.CSharp.Expression.ResolveAsTypeTerminal (IMemberContext ec,
Boolean silent) [0x00000] in <filename unknown>:0 
  at Mono.CSharp.TypeContainer.ResolveBaseTypes (Mono.CSharp.TypeExpr&
base_class) [0x00000] in <filename unknown>:0 
  at Mono.CSharp.Class.ResolveBaseTypes (Mono.CSharp.TypeExpr& base_class)
[0x00000] in <filename unknown>:0 
  at Mono.CSharp.TypeContainer.DefineBaseTypes () [0x00000] in <filename
unknown>:0 
  at Mono.CSharp.TypeContainer.DefineType () [0x00000] in <filename
unknown>:0 
  at Mono.CSharp.ModuleContainer.Define () [0x00000] in <filename unknown>:0 
  at Mono.CSharp.Driver.Compile () [0x00000] in <filename unknown>:0 
  at Mono.CSharp.Driver.Main (System.String[] args) [0x00000] in <filename
unknown>:0 
$                                                                                                                                                                             
$ cat lol.cs                                                                                                                                                                  
using System;                                                                                                                                                                 
                                                                                                                                                                              
namespace Lol                                                                                                                                                                 
{                                                                                                                                                                             
        public class
Foo<T>:System.Collections.Generic.List&lt;Foo&lt;T&gt;.Bar>                                                                                                       
        {
                class Bar
                {
                }
        }
}

The compiler from MS VS works fine, so it's a bug in Mono compiler. 

--
View this message in context: http://mono.1490590.n4.nabble.com/Compiler-crashes-tp3695350p3695350.html
Sent from the Mono - Dev mailing list archive at Nabble.com.


More information about the Mono-devel-list mailing list