Nathan Ridge
Nathan Ridge
I suspect that, as in https://github.com/clangd/clangd/discussions/2482, the problem is using `-fmodules-ts`, which clang (and clangd) [do not support](https://github.com/llvm/llvm-project/issues/60060). Does using `-fmodules` instead help?
> I suspect, that the issue is that Clangd does not understand GCC specific arguments `-fmodule-mapper` and `-fdeps-format`. Even when I remove them via `.clangd` config, it still does not...
> In my local testing, the module dependency scanner does not seem to respect [`CompileFlags`](https://clangd.llvm.org/config.html#compileflags), even as the regular AST build does respect it. Huh, I think I must have...
> The content of my .clangd file: > > CompileFlags: > Remove: ['-fdeps-format=*', '-fmodule-mapper=*' ] Interesting -- this seems to work in my local testing. Can you share logs taken...
Well, compared to the log in [this comment](https://github.com/clangd/clangd/issues/2477#issuecomment-3271969147), the error: > E[20:58:39.580] Scanning modules dependencies for c:\Users\mail\godot-projects\cxx-modules\src\main.cpp failed: error: unknown argument: '-fmodule-mapper=CMakeFiles\cxx20_modules.dir\src\main.cpp.obj.modmap' error: unknown argument: '-fdeps-format=p1689r5' is gone in the...
The remaining issue seems to be caused by: > E[00:01:53.566] Failed to build module math; due to Failed to compile C:\Users\mail\godot-projects\cxx-modules\src\math.cpp. Use '--log=verbose' to view detailed failure reasons. Additional lines...
Here are the diagnostics in that latter line, formatted for readability: ```json { "jsonrpc": "2.0", "method": "textDocument/publishDiagnostics", "params": { "diagnostics": [ { "code": "redefinition", "message": "In included file: redefinition of...
I'm not quite sure what to make of that error, but that's what needs to be fixed for the module build to succeed. Maybe try playing around with building the...
By the way, @ChuanqiXu9, just to make sure I'm understanding correctly: if there are any diagnostics with severity "error" while building a module, the `pcm` file will not be produced?
> > By the way, [@ChuanqiXu9](https://github.com/ChuanqiXu9), just to make sure I'm understanding correctly: if there are any diagnostics with severity "error" while building a module, the `pcm` file will not...