https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112506
--- Comment #1 from Francois-Xavier Coudert <fxcoudert at gcc dot gnu.org> --- The stack trace for the "expecting a DefImp symbol" error is the following: * thread #1, queue = 'com.apple.main-thread', stop reason = breakpoint 2.1 * frame #0: 0x000000010004a240 cc1gm2`::M2Emit_InternalError(message_="expecting a DefImp symbol", _message_high=25) at M2Emit.c:97:8 frame #1: 0x000000010004be0c cc1gm2`::M2Error_InternalError(message_=<unavailable>, _message_high=25) at M2Error.c:2605:24 frame #2: 0x00000001000a9543 cc1gm2`::SymbolTable_IsDefinitionForC(Sym=165) at SymbolTable.c:16397:31 frame #3: 0x0000000100047676 cc1gm2`::M2Comp_compile(void *) at M2Comp.c:1114:43 frame #4: 0x00000001000475db cc1gm2`::M2Comp_compile(void *) at M2Comp.c:1189:28 frame #5: 0x0000000100047246 cc1gm2`::M2Comp_compile(void *) [inlined] Compile(s=0x00006000037079c0) at M2Comp.c:427:11 frame #6: 0x0000000100047246 cc1gm2`::M2Comp_compile(filename=<unavailable>) at M2Comp.c:1540:11 frame #7: 0x00000001000063e1 cc1gm2`::gm2_langhook_parse_file() at gm2-lang.cc:803:26 frame #8: 0x0000000100006393 cc1gm2`::gm2_langhook_parse_file() at gm2-lang.cc:810:25 frame #9: 0x0000000101476d04 cc1gm2`::compile_file() at toplev.cc:446:25 frame #10: 0x0000000101db1d06 cc1gm2`toplev::main(int, char**) at toplev.cc:2129:24 frame #11: 0x0000000101dc13c0 cc1gm2 The trace for the other one is: * thread #1, queue = 'com.apple.main-thread', stop reason = breakpoint 1.1 * frame #0: 0x00000001000692b0 cc1gm2`::M2MetaError_MetaErrorT1(tok=3628, m_="module {%1Ea} has a corresponding DEFINITION MODULE but no IMPLEMENTATION keyword in the main module", _m_high=100, s=155) at M2MetaError.c:3471:1 frame #1: 0x000000010009823d cc1gm2`::P1SymBuild_P1StartBuildProgramModule() at P1SymBuild.c:633:31 frame #2: 0x00000001000e5b43 cc1gm2`::P1Build_CompilationUnit() [inlined] ProgramModule(stopset0=1, stopset1=0, stopset2=0) at P1Build.c:3038:40 frame #3: 0x00000001000e5b10 cc1gm2`::P1Build_CompilationUnit() [inlined] ImplementationOrProgramModule(stopset0=1, stopset1=0, stopset2=0) at P1Build.c:3143:21 frame #4: 0x00000001000e5b10 cc1gm2`::P1Build_CompilationUnit() [inlined] FileUnit(stopset0=1, stopset1=0, stopset2=0) at P1Build.c:2993:37 frame #5: 0x00000001000e51e0 cc1gm2`::P1Build_CompilationUnit() at P1Build.c:6664:12 frame #6: 0x0000000100047c59 cc1gm2`::M2Comp_compile(void *) at M2Comp.c:1258:46 frame #7: 0x0000000100047bd8 cc1gm2`::M2Comp_compile(void *) [inlined] Compile(s=0x000060000370a1c0) at M2Comp.c:433:11 frame #8: 0x0000000100047246 cc1gm2`::M2Comp_compile(filename=<unavailable>) at M2Comp.c:1540:11 frame #9: 0x00000001000063e1 cc1gm2`::gm2_langhook_parse_file() at gm2-lang.cc:803:26 frame #10: 0x0000000100006393 cc1gm2`::gm2_langhook_parse_file() at gm2-lang.cc:810:25 frame #11: 0x0000000101476d04 cc1gm2`::compile_file() at toplev.cc:446:25 frame #12: 0x0000000101db1d06 cc1gm2`toplev::main(int, char**) at toplev.cc:2129:24 frame #13: 0x0000000101dc13c0 cc1gm2