Thread overview
[Issue 9338] New: Compiler segfault with template mixin creating compile time array
Jan 17, 2013
Robik
[Issue 9338] Compiler segfaults if try to CTFE member function without valid 'this'
Jan 18, 2013
Kenji Hara
Jan 18, 2013
Kenji Hara
Jan 18, 2013
Kenji Hara
January 17, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=9338

           Summary: Compiler segfault with template mixin creating compile
                    time array
           Product: D
           Version: unspecified
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody@puremagic.com
        ReportedBy: szadows@gmail.com


--- Comment #0 from Robik <szadows@gmail.com> 2013-01-17 11:48:55 PST ---
This code segfaults:

----
mixin template SomeMixin()
{
    void test()
    {
        enum members = makeArray();
    }

    string[] makeArray()
    {
        return ["a"];
    }
}

class Foo
{
    mixin SomeMixin;
}
----

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


Kenji Hara <k.hara.pg@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice
            Summary|Compiler segfault with      |Compiler segfaults if try
                   |template mixin creating     |to CTFE member function
                   |compile time array          |without valid 'this'


--- Comment #1 from Kenji Hara <k.hara.pg@gmail.com> 2013-01-17 23:53:35 PST ---
This is not related to mixin. This code also segfaults:

class Foo
{
    void test()
    {
        enum members = makeArray();
    }

    string[] makeArray()
    {
        return ["a"];
    }
}

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


Kenji Hara <k.hara.pg@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |pull


--- Comment #2 from Kenji Hara <k.hara.pg@gmail.com> 2013-01-18 00:13:14 PST ---
https://github.com/D-Programming-Language/dmd/pull/1506

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



--- Comment #3 from github-bugzilla@puremagic.com 2013-01-18 06:22:59 PST ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/7982d16e224495cc28787dd93020db7ab01620b9
fix Issue 9338 - Compiler segfaults if try to CTFE member function without
valid 'this'

https://github.com/D-Programming-Language/dmd/commit/f7e565942292e7edef5b948591afe662cac84e9d Merge pull request #1506 from 9rnsr/fix9338

Issue 9338 - Compiler segfaults if try to CTFE member function without valid 'this'

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


Kenji Hara <k.hara.pg@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |CTFE
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED


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



--- Comment #4 from github-bugzilla@puremagic.com 2013-02-11 12:20:11 PST ---
Commits pushed to staging at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/7982d16e224495cc28787dd93020db7ab01620b9
fix Issue 9338 - Compiler segfaults if try to CTFE member function without
valid 'this'

https://github.com/D-Programming-Language/dmd/commit/f7e565942292e7edef5b948591afe662cac84e9d Merge pull request #1506 from 9rnsr/fix9338

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



--- Comment #5 from github-bugzilla@puremagic.com 2013-02-11 22:49:36 PST ---
Commits pushed to https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/7982d16e224495cc28787dd93020db7ab01620b9
fix Issue 9338 - Compiler segfaults if try to CTFE member function without
valid 'this'

https://github.com/D-Programming-Language/dmd/commit/f7e565942292e7edef5b948591afe662cac84e9d Merge pull request #1506 from 9rnsr/fix9338

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



--- Comment #6 from github-bugzilla@puremagic.com 2013-04-18 11:23:09 PDT ---
Commit pushed to dmd-1.x at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/c3a9411507a9971c9471e29ca1898bab73f71352
fix Issue 9338 - Compiler segfaults if try to CTFE member function without
valid 'this'

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