https://issues.dlang.org/show_bug.cgi?id=19375
Issue ID: 19375 Summary: .init of a nested struct stumps the inliner Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: normal Priority: P1 Component: dmd Assignee: nob...@puremagic.com Reporter: stanislav.bli...@gmail.com union Erase(T) { T typed; } void func(T)() { pragma(inline, true); auto e = Erase!T(T.init); } void main() { version (TestNested) { struct S { ~this() {} /* so that it's nested */ } } else { static struct S { ~this() {} } } func!S; } $ dmd -inline test.d Compiles $ dmd -inline -version=TestNested test.d test.d(3): Error: function `test.func!(S).func` cannot inline function --