Thread overview
[Issue 6896] New: ICE(glue.c !vthis->csym): on method with alias this access
Nov 05, 2011
dawg@dawgfoto.de
Dec 09, 2011
David Simcha
Dec 09, 2011
David Simcha
Apr 21, 2012
SomeDude
Apr 21, 2012
SomeDude
May 01, 2012
SomeDude
May 04, 2012
SomeDude
November 05, 2011
http://d.puremagic.com/issues/show_bug.cgi?id=6896

           Summary: ICE(glue.c !vthis->csym): on method with alias this
                    access
           Product: D
           Version: D2
          Platform: Other
        OS/Version: All
            Status: NEW
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody@puremagic.com
        ReportedBy: dawg@dawgfoto.de


--- Comment #0 from dawg@dawgfoto.de 2011-11-05 11:12:46 PDT ---
// REQUIRED_ARGS: -inline

struct Nested
{
    int _val;
}

struct S
{
    Nested _nested;
    alias _nested this;

    void set(int v)
    {
        assign(v);
    }

    void assign(int v)
    {
        _val = v;
    }
}

----

Note that this does not happen when the definition of assign
comes lexically before set. So the issue appears to be an alias this
access when inlining a function that was forward referenced.

This is probably related to http://d.puremagic.com/issues/show_bug.cgi?id=2962.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 09, 2011
http://d.puremagic.com/issues/show_bug.cgi?id=6896


David Simcha <dsimcha@yahoo.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dsimcha@yahoo.com


--- Comment #1 from David Simcha <dsimcha@yahoo.com> 2011-12-08 16:21:41 PST ---
Here's another way to reproduce the same failure:

int expression( string op, Lhs, Rhs )
( auto ref Lhs lhs, auto ref Rhs rhs ) {
    return 0;
}

struct BasicMatrix( Storage_ ) {
    auto opBinary( string op, NewRhs )( auto ref NewRhs newRhs ) {
        alias this thisConverted;
        return expression!op( thisConverted, newRhs );
    }
}

void ridgeLargeP() {
    BasicMatrix!double cwc;
    auto foo = cwc * cwc;
}

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 09, 2011
http://d.puremagic.com/issues/show_bug.cgi?id=6896



--- Comment #2 from David Simcha <dsimcha@yahoo.com> 2011-12-08 16:21:49 PST ---
*** Issue 7082 has been marked as a duplicate of this issue. ***

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


SomeDude <lovelydear@mailmetrash.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |lovelydear@mailmetrash.com


--- Comment #3 from SomeDude <lovelydear@mailmetrash.com> 2012-04-20 17:15:45 PDT ---
Both tests pass and run with or without -inline

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



--- Comment #4 from SomeDude <lovelydear@mailmetrash.com> 2012-04-20 17:16:10 PDT ---
(In reply to comment #3)
> Both tests pass and run with or without -inline

On 2.059 Win32

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 01, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=6896



--- Comment #5 from SomeDude <lovelydear@mailmetrash.com> 2012-05-01 15:56:08 PDT ---
Should be closed FIXED.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 04, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=6896


SomeDude <lovelydear@mailmetrash.com> changed:

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


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