Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions swift/tools/tracing-config.lua
Original file line number Diff line number Diff line change
Expand Up @@ -99,13 +99,15 @@ function RegisterExtractorPack(id)
if compilerName ~= 'swift-frontend' then
return nil
end
-- Skip the invocation in case it's not called in `-frontend` mode
if compilerArguments.argv[1] ~= '-frontend' then
-- Skip the invocation in case it's not called in `-frontend` or `-emit-module` mode
if compilerArguments.argv[1] ~= '-frontend' and compilerArguments.argv[1] ~= '-emit-module' then
return nil
end

-- Drop the `-frontend` argument
table.remove(compilerArguments.argv, 1)
if compilerArguments.argv[1] == '-frontend' then
table.remove(compilerArguments.argv, 1)
end

-- Skip "info" queries in case there is nothing to extract
if compilerArguments.argv[1] == '-print-target-info' then
Expand Down
Loading