I narrowed down the error without a line number that Dan saw in Walnut. I don't know that DMD is reject code that is invalid in Dan's case, but obviously the code in my reduced example is invalid code. The error message should be improved to show where the error occurs. Example: <code> struct MyStruct { } static const MyStruct FALSE = { b:false }; </code> Error Message: Error: 'b' is not a member of 'MyStruct' (no line number provided by DMD)
I fixed the summary.
Umm... well, this issue is blocking any development on my program with any compiler after 1.020 (whatever changed, happened in 1.021) My code shows: struct Value { union { bool b; int i; ... } } static const Value UNDEFINED = ... FALSE = { b:false ... } ... I get an error message which is completely not useful. It just says "b is not a member of Value"; which it clearly is. Please help. Regards, Dan
DMD 1.025 seems to have fixed the missing line number bug. My test case now yields a filename and line number: <quote> test1.d(14): Error: 'b' is not a member of 'MyStruct' </quote> It also may have fixed Dan's code since this snippet now compiles, too: <code> struct Value { union { bool b; int i; } } static const Value FALSE = { b:false}; </code> (But I think that snippet seemed to compile with DMD 1.024, too.) Dan, if you continue to have related problems, you should probably post a new bug report with a new description, test case, etc., since the description and keyword of this bug report doesn't apply anymore since the line number is provided for invalid code.
AltStyle によって変換されたページ (->オリジナル) / アドレス: モード: デフォルト 音声ブラウザ ルビ付き 配色反転 文字拡大 モバイル