[llvm] [LTO] Fix used before intialised warning (PR #143705)
David Spickett via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 11 06:49:05 PDT 2025
================
@@ -272,8 +272,9 @@ class FunctionImporter {
// A map from destination modules to lists of imports.
class ImportListsTy {
public:
- ImportListsTy() : EmptyList(ImportIDs) {}
- ImportListsTy(size_t Size) : EmptyList(ImportIDs), ListsImpl(Size) {}
+ ImportListsTy() : ImportIDs(), EmptyList(ImportIDs) {}
+ ImportListsTy(size_t Size)
+ : ImportIDs(), EmptyList(ImportIDs), ListsImpl(Size) {}
----------------
DavidSpickett wrote:
In theory we don't need to call ImportIDs() here but I thought it was clearer to do so.
https://github.com/llvm/llvm-project/pull/143705
More information about the llvm-commits
mailing list