Thread overview
[Issue 1054] New: regression: circular aliases cause segfaults
Mar 12, 2007
d-bugmail
Mar 29, 2007
d-bugmail
Apr 14, 2007
d-bugmail
Apr 03, 2009
d-bugmail
[Issue 1054] regression: circular aliases cause compiler stack overflow
May 14, 2009
Don
Jul 09, 2009
Walter Bright
March 12, 2007
http://d.puremagic.com/issues/show_bug.cgi?id=1054

           Summary: regression: circular aliases cause segfaults
           Product: D
           Version: 1.009
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P3
         Component: DMD
        AssignedTo: bugzilla@digitalmars.com
        ReportedBy: thomas-dloop@kuehne.cn


# alias a b;
# alias b a;
#
# b x;

dmd -c a.d -> segfaults

# alias a b;
# alias b a;

dmd -c a.d -> compiles even though it shouldn't

test cases: http://dstress.kuehne.cn/nocompile/a/alias_30_G.d http://dstress.kuehne.cn/nocompile/a/alias_30_J.d http://dstress.kuehne.cn/nocompile/a/alias_30_K.d http://dstress.kuehne.cn/nocompile/e/enum_44_E.d


-- 

March 29, 2007
http://d.puremagic.com/issues/show_bug.cgi?id=1054


thomas-dloop@kuehne.cn changed:

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




------- Comment #1 from thomas-dloop@kuehne.cn  2007-03-29 14:08 -------
*** Bug 1063 has been marked as a duplicate of this bug. ***


-- 

April 14, 2007
http://d.puremagic.com/issues/show_bug.cgi?id=1054


braddr@puremagic.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|normal                      |regression




-- 

April 03, 2009
http://d.puremagic.com/issues/show_bug.cgi?id=1054


clugdbug@yahoo.com.au changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|accepts-invalid             |




------- Comment #2 from clugdbug@yahoo.com.au  2009-04-03 02:28 -------
The first case no longer segfaults -- it stack overflows instead, and the second case now generates an error.

On DMD1.042, the first case displays:

fog.d(2): Error: alias fog.a recursive alias declaration
Stack overflow

and on DMD2.027, it gets caught in an infinite loop:
fog.d(2): Error: alias fog.a recursive alias declaration
fog.d(2): Error: alias fog.a recursive alias declaration
fog.d(2): Error: alias fog.a recursive alias declaration
fog.d(2): Error: alias fog.a recursive alias declaration
fog.d(2): Error: alias fog.a recursive alias declaration


-- 

May 14, 2009
http://d.puremagic.com/issues/show_bug.cgi?id=1054


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

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |clugdbug@yahoo.com.au
            Summary|regression: circular        |regression: circular
                   |aliases cause segfaults     |aliases cause compiler
                   |                            |stack overflow




--- Comment #3 from Don <clugdbug@yahoo.com.au>  2009-05-14 05:26:01 PDT ---
This is fixed in DMD2.030, but not in DMD1.045.

alias a b;
alias b a;
a y;
---
ice.d(544): Error: alias ice.a recursive alias declaration
Stack overflow

----------

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


Walter Bright <bugzilla@digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |bugzilla@digitalmars.com
         Resolution|                            |FIXED




--- Comment #4 from Walter Bright <bugzilla@digitalmars.com>  2009-07-09 02:53:56 PDT ---
Fixed dmd 1.046

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