https://issues.dlang.org/show_bug.cgi?id=17021

          Issue ID: 17021
           Summary: Invalid code generated for out parameters in naked asm
                    functions
           Product: D
           Version: D2
          Hardware: x86
                OS: Windows
            Status: NEW
          Severity: major
          Priority: P1
         Component: dmd
          Assignee: [email protected]
          Reporter: [email protected]

Despite the naked statement, the inline assembler emits initialization code of
out parameters:

void test(out int x)
{
  asm
  {
     naked;
     ret;
  }
}

generated code inside the function:

mov EAX, [EBP -4];
mov dword ptr [EAX], 0;
ret;

--

Reply via email to