[Issue 9317] New: ParameterStorageClassTuple reports errors for inout function

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Jan 14 06:47:35 PST 2013


http://d.puremagic.com/issues/show_bug.cgi?id=9317

           Summary: ParameterStorageClassTuple reports errors for inout
                    function
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P2
         Component: Phobos
        AssignedTo: nobody at puremagic.com
        ReportedBy: k.hara.pg at gmail.com


--- Comment #0 from Kenji Hara <k.hara.pg at gmail.com> 2013-01-14 06:47:34 PST ---
Separation from: http://d.puremagic.com/issues/show_bug.cgi?id=8695#c1

-----------------
import std.traits;

inout int func(inout int param)
{
    return param;
}

void main()    
{
    alias stcs = ParameterStorageClassTuple!(typeof(func));
    pragma(msg, stcs);
}
-----------------
/usr/local/include/dmd2/std/traits.d(97): Error: key 'g' not found in
associative array
['a':cast(FunctionAttribute)1u,'b':cast(FunctionAttribute)2u,'c':cast(FunctionAttribute)4u,'d':cast(FunctionAttribute)8u,'e':cast(FunctionAttribute)16u,'f':cast(FunctionAttribute)32u]
/usr/local/include/dmd2/std/traits.d(458): called from here:
demangleFunctionAttributes("NgiZi"c)
/usr/local/include/dmd2/std/traits.d(97): Error: key 'g' not found in
associative array
['a':cast(FunctionAttribute)1u,'b':cast(FunctionAttribute)2u,'c':cast(FunctionAttribute)4u,'d':cast(FunctionAttribute)8u,'e':cast(FunctionAttribute)16u,'f':cast(FunctionAttribute)32u]
/usr/local/include/dmd2/std/traits.d(458): called from here:
demangleFunctionAttributes("NgiZi"c)
/home/c565/c253.d(10): Error: template instance
std.traits.ParameterStorageClassTuple!(inout int(inout(int) param)) error
instantiating
demangleNextParameter!(demangleFunctionAttributes("NgiZi"c).rest)
-----------------

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


More information about the Digitalmars-d-bugs mailing list