http://bugzilla.novell.com/show_bug.cgi?id=495973


           Summary: compiler hangs (Infinite Loop) during compilation of
                    unsafe code with struct
    Classification: Mono
           Product: Mono: Compilers
           Version: 2.4.x
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: C#
        AssignedTo: [email protected]
        ReportedBy: [email protected]
         QAContact: [email protected]
          Found By: Other


Description of Problem:
The following code produce an infinite loop during compilation. The compiler
keeps running until all memory is exhausted.
This code was successfully compiled with version 2.2 and older of mono
It also works with Microsoft.NET.
Looking at the gmcs sources, the infinite loop is because of recursive call of
Struct.IsUnmanagedType()

Steps to reproduce the problem:
1. Compile the following code with the /unsafe option


Actual Results:
infinite loop, compiler hangs

Expected Results:
compile ok

How often does this happen? 
always

Additional Information:
Here is the code:

unsafe struct A { B* b; }
unsafe struct B { A* a; }
unsafe struct C { B* b; }

-- 
Configure bugmail: http://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.
_______________________________________________
mono-bugs maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-bugs

Reply via email to