summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArthur LAURENT <[email protected]>2025-05-10 22:19:26 +0200
committerArthur LAURENT <[email protected]>2025-05-10 22:19:26 +0200
commitfca3c75472f07dc5e6f632e89d283c2cda8acaff (patch)
treee33984bd96a430cd7b3c38c8be3329be727e4d89
parent8149a35e80a5ec233956cdb02a93e0a4b62855a0 (diff)
(C++ modules support) fix module parsing when file are added
-rw-r--r--xmake/rules/c++/modules/scanner.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/xmake/rules/c++/modules/scanner.lua b/xmake/rules/c++/modules/scanner.lua
index efbaa20c3..dcb4f22b8 100644
--- a/xmake/rules/c++/modules/scanner.lua
+++ b/xmake/rules/c++/modules/scanner.lua
@@ -421,7 +421,7 @@ function _do_parse(target, sourcebatch)
cxx_sourcebatch.dependfiles = {}
for _, sourcefile in ipairs(sourcebatch.sourcefiles) do
local module = mapper.get(target, sourcefile)
- if not module.interface and not module.implementation then
+ if module and not module.interface and not module.implementation then
table.insert(cxx_sourcebatch.sourcefiles, sourcefile)
local objectfile = target:objectfile(sourcefile)
table.insert(cxx_sourcebatch.dependfiles, target:dependfile(objectfile))