Test case: ``` struct S { ~this(); } class C { this(S, int) {} } int i(); C create() { return new C(S(), i()); } auto test() { auto c = create(); } ``` When compiled with `-inline` it fails, otherwise it works normally.
@SSoulaimane created dlang/dmd pull request #10627 "Fix issue 20420 - some expressions are missed during by the inliner" fixing this issue: - Fix issue 20420 - some expressions are missed during by the inliner The destructor expression for variable declaration is not scanned, as well as the arguments prefix for the new expression. https://github.com/dlang/dmd/pull/10627
dlang/dmd pull request #10627 "Fix issue 20420 - some expressions are missed during by the inliner" was merged into stable: - c9e5c495cba0c629193b8417215b0d3622a82ef3 by سليمان السهمي (Suleyman Sahmi): Fix issue 20420 - some expressions are missed during by the inliner The destructor expression for variable declaration is not scanned, as well as the arguments prefix for the new expression. https://github.com/dlang/dmd/pull/10627