Thread overview
[Issue 10575] New: struct and alloca cause internal error
Aug 20, 2013
yebblies
Aug 28, 2013
Don
July 08, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=10575

           Summary: struct and alloca cause internal error
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody@puremagic.com
        ReportedBy: maximechevalierb@gmail.com


--- Comment #0 from Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> 2013-07-08 11:54:40 PDT ---
Created an attachment (id=1231)
failing test case

Using alloca in a function with a struct that has a destructor seems to cause an internal compiler error in DMD. The following error message results:

Internal error: eh.c 54

A failing test case is attached.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
August 20, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=10575


yebblies <yebblies@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice
                 CC|                            |yebblies@gmail.com


--- Comment #1 from yebblies <yebblies@gmail.com> 2013-08-21 00:40:24 EST ---
For small test cases, please paste inline instead of attaching.

import core.stdc.stdlib;

struct TheStruct
{
    ~this()
    {
    }
}

void bar()
{
}

void main()
{
    auto s = TheStruct();
    bar();
    auto a = alloca(16);
}

I can't reproduce on win32, but that is not a surprise as eh.c is posix-only.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
August 28, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=10575


Don <clugdbug@yahoo.com.au> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |DUPLICATE


--- Comment #2 from Don <clugdbug@yahoo.com.au> 2013-08-28 00:20:03 PDT ---
*** This issue has been marked as a duplicate of issue 3753 ***

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------