www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 2217] New: Cannot create deprecated alias of type derived from deprecated type

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2217

           Summary: Cannot create deprecated alias of type derived from
                    deprecated type
           Product: D
           Version: 1.032
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Keywords: rejects-valid
          Severity: regression
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: smjg iname.com


With the purported deprecation bug fixes in DMD 1.032, a number of new
deprecation bugs seem to have (re)surfaced.  Issue 2207 and issue 2208 are two;
here is another (probably related to 2208).

----------
deprecated {
    class DepClass {}

    alias DepClass DepClassAlias;     // works
    alias DepClass* DepClassPointer;  // all the rest fail
    alias DepClass[] DepClassArray;
    alias void function(DepClass) DepClassParam;
    alias DepClass function() DepClassReturn;
}
----------
dep_1032_a.d(5): class dep_1032_a.DepClass is deprecated
dep_1032_a.d(6): class dep_1032_a.DepClass is deprecated
dep_1032_a.d(7): class dep_1032_a.DepClass is deprecated
dep_1032_a.d(8): class dep_1032_a.DepClass is deprecated
----------

The aliases being created are themselves deprecated, so it is within their
rights to depend on deprecated stuff.

This happens regardless of whether the original deprecated type is a class,
interface, struct, union, enum, alias or typedef.

This has broken the WindowsAPI project at least.


-- 
Jul 11 2008
parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2217


clugdbug yahoo.com.au changed:

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






DMD1.033.

*** This bug has been marked as a duplicate of 2208 ***


-- 
Jul 11 2008