I just tried the dmd 2.060 beta on my work app and got an error that wasn't present on 2.059. This is trimmed down as small as I can: === class Cgi { struct PostParserState { UploadedFile piece; } static struct UploadedFile { string contentFilename; } } === $ dmd -c regression.d regression.d(6): Error: struct regression.Cgi.UploadedFile no size yet for forward reference If I take the static off of UploadedFile, the error goes away. Or I can swap the order of the definitions and the error goes away, but it used to work the way it is.
Thanks for filing this. I've hit similar issue with my project but failed to narrow it down.
https://github.com/D-Programming-Language/dmd/pull/1067
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/98467f4202d7bca6abd18cc28a51e95a0bc57100 fix Issue 8437 - [2.060 beta] static struct no size yet for forward reference This is a regression introduced fixing aggregate alignment. Introduced Commit: 154e44a006270d53745f99ec3e538a0ce526ae76 In VarDeclaration::semantic, if scope alignment is default, then its type's alignment is used, and it needs to resolve forward reference. But, in ClassDeclaration::semantic, the calling setScope for AttribDeclaration members was lacked. https://github.com/D-Programming-Language/dmd/commit/c59699ae29dde0f32239bcadb853c7793ee4bada Merge pull request #1067 from 9rnsr/fix8437 Issue 8437 - [2.060 beta] static struct no size yet for forward reference
I'm going to mark this fixed. dmd from git now compiles my original project without problem.
AltStyle によって変換されたページ (->オリジナル) / アドレス: モード: デフォルト 音声ブラウザ ルビ付き 配色反転 文字拡大 モバイル