//// a.d //// import b; void main() { S[1] arr; } //// b.d //// struct S {} ///////////// This doesn't link: Error 42: Symbol Undefined _D1b1S6__initZ Using individual (non-array) variables of type S, as well as making the array static, seem to fix the linker error.
https://github.com/D-Programming-Language/dmd/pull/5014
*** Issue 14014 has been marked as a duplicate of this issue. ***
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/e2be39899a71f1d82d8d23ebf52c97f8efb13485 fix Issue 14992 - static array local variables always require .init Add one more special case for static array of struct initialization with zero, similar to the special case for struct initialization. https://github.com/D-Programming-Language/dmd/commit/8388211efea46340e1ada6b3b889452efd40ccd5 Merge pull request #5014 from 9rnsr/fix14992 Issue 14992 - static array local variables always require .init
Commits pushed to stable at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/e2be39899a71f1d82d8d23ebf52c97f8efb13485 fix Issue 14992 - static array local variables always require .init https://github.com/D-Programming-Language/dmd/commit/8388211efea46340e1ada6b3b889452efd40ccd5 Merge pull request #5014 from 9rnsr/fix14992