[Mono-bugs] [Bug 353744] CodeTypeReference has some issues with generic types

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Sun Nov 28 12:45:14 EST 2010


https://bugzilla.novell.com/show_bug.cgi?id=353744

https://bugzilla.novell.com/show_bug.cgi?id=353744#c3


David Waters <davidwaters at google.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |davidwaters at google.com

--- Comment #3 from David Waters <davidwaters at google.com> 2010-11-28 17:45:13 UTC ---
I have also incounted this bug, I will attach another code sample that works
when run in ms.net and fails in mono. 

It creates a CodeCompileUnit adds one class with one method with one generic
type parameter. then it generates code to disk in the working directory. It
also trys to compile from CodeCompileUnit. Both of these are successful in
ms.net both fail in 
Mono JIT compiler version 2.8.1 (tarball)

I would suspect error in
Mono.CSharp.CSharpCodeGenerator.GetTypeOutput(CodeTypeReference type)
example output below.

C:\java\projects\TestCodeGeneration\TestCodeGeneration>C:\Windows\Microsoft.NET\Framework\v3.5\csc
Program.cs
Microsoft (R) Visual C# 2008 Compiler version 3.5.30729.4926
for Microsoft (R) .NET Framework version 3.5
Copyright (C) Microsoft Corporation. All rights reserved.

C:\java\projects\TestCodeGeneration\TestCodeGeneration>Program.exe
Compilation Passed

C:\java\projects\TestCodeGeneration\TestCodeGeneration>"C:\Program
Files\Mono-2.8.1\bin\mcs" Program.cs

C:\java\projects\TestCodeGeneration\TestCodeGeneration>Program.exe
Compilation Passed

C:\java\projects\TestCodeGeneration\TestCodeGeneration>"C:\Program
Files\Mono-2.8.1\bin\mono" Program.exe
C:\Users\DAVIDW~1\AppData\Local\Temp\339c2b52\32a21bd2.0.cs(18,73) : error
CS0305: Using the generic type `System.Colle
tions.Generic.IDictionary<TKey,TValue>' requires `2' type argument(s)
(0,0) : error : C:\Program Files\Mono-2.8.1\lib\mono\2.0\mscorlib.dll (Location
of the symbol related to previous error

C:\java\projects\TestCodeGeneration\TestCodeGeneration>"C:\Program
Files\Mono-2.8.1\bin\mono" --version
Mono JIT compiler version 2.8.1 (tarball)
Copyright (C) 2002-2010 Novell, Inc and Contributors. www.mono-project.com
        TLS:           normal
        SIGSEGV:       normal
        Notification:  Thread + polling
        Architecture:  x86
        Disabled:      none
        Misc:          softdebug
        LLVM:          supported, not enabled.
        GC:            Included Boehm (with typed GC and Parallel Mark)

C:\java\projects\TestCodeGeneration\TestCodeGeneration>

-- 
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