[Issue 6279] New: array-vararg with pointer type not working in safe code

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Jul 9 19:15:34 PDT 2011


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

           Summary: array-vararg with pointer type not working in safe
                    code
           Product: D
           Version: D2
          Platform: Other
        OS/Version: Mac OS X
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: michel.fortin at michelf.com


--- Comment #0 from Michel Fortin <michel.fortin at michelf.com> 2011-07-09 22:10:27 EDT ---
This code doesn't work in @safe mode because of some compiler-generated code
not being @safe:

@safe:

void foo(string[] val...) {
}

void main() {
    foo("a", "b"); // Error: variable voidinitvararg.main.__arrayArg3 void
initializers for pointers not allowed in safe functions
}

-- 
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