https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90136
Bug ID: 90136 Summary: [d] Merge UDAs between function prototype and definitions Product: gcc Version: 9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: d Assignee: ibuclaw at gdcproject dot org Reporter: ibuclaw at gdcproject dot org Target Milestone: --- For two function declarations that have identical signatures (there's no mismatched nothrow/pure/@nogc/...) any user defined attributes applied to one should be merged with the other. Given: @("foo") void bar(ref double[4]); void bar(ref double[4] a) { foreach (ref b; a) b += 42; } This is important for one use of the gcc.attribute module. static if (GNU_ARM_EABI_Unwinder) { @attribute("target", ("general-regs-only")) private _Unwind_Reason_Code __gdc_personality(_Unwind_Action actions, _Unwind_Exception_Class exceptionClass, _Unwind_Exception* unwindHeader, _Unwind_Context* context); }