Reduced from a unittest in std.path, uncovered by https://github.com/dlang/dmd/pull/13993 ``` auto ir(string[] p...) { return p; } ``` As of https://github.com/dlang/dmd/pull/13710, typesafe variadic args may not be `return scope` anymore. However, when the compiler infers `return scope`, the errors is confusing: Error: typesafe variadic function parameter `p` of type `string[]` cannot be marked `return` The compiler should not infer `return scope` in the first place.
*** Issue 23244 has been marked as a duplicate of this issue. ***
@dkorpel created dlang/dmd pull request #14327 "Fix 23022 - typesafe variadic parameter should not infer return" fixing this issue: - Fix 23022 - typesafe variadic parameter should not infer return https://github.com/dlang/dmd/pull/14327
dlang/dmd pull request #14327 "Fix 23022 - typesafe variadic parameter should not infer return" was merged into master: - 6ad296ecae5a5e9fdd9f118f6151678a683b895a by Dennis Korpel: Fix 23022 - typesafe variadic parameter should not infer return https://github.com/dlang/dmd/pull/14327