<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/60616>60616</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
windows compile error:Attributor.h:1137:32 duplicate initialization
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
Y-JC
</td>
</tr>
</table>
<pre>
```
[958/3411] Building CXX object lib/Transforms/IPO/CMakeFiles/LLVMipo.dir/Attributor.cpp.obj
FAILED: lib/Transforms/IPO/CMakeFiles/LLVMipo.dir/Attributor.cpp.obj
D:\Programs\Qt\Tools\mingw730_64\bin\c++.exe -DGTEST_HAS_RTTI=0 -D_DEBUG -D_FILE_OFFSET_BITS=64 -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -IE:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/build_ninja/lib/Transforms/IPO -IE:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/lib/Transforms/IPO -IE:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/build_ninja/include -IE:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/include -Wa,-mbig-obj -Werror=date-time -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wimplicit-fallthrough -Wno-maybe-uninitialized -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wno-comment -Wno-misleading-indentation -ffunction-sections -fdata-sections -O2 -DNDEBUG -fno-exceptions -fno-rtti -UNDEBUG -std=c++1z -MD -MT lib/Transforms/IPO/CMakeFiles/LLVMipo.dir/Attributor.cpp.obj -MF lib\Transforms\IPO\CMakeFiles\LLVMipo.dir\Attributor.cpp.obj.d -o lib/Transforms/IPO/CMakeFiles/LLVMipo.dir/Attributor.cpp.obj -c E:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/lib/Transforms/IPO/Attributor.cpp
In file included from E:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/lib/Transforms/IPO/Attributor.cpp:16:0:
E:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/include/llvm/Transforms/IPO/Attributor.h:1137:32: error: duplicate initialization of 'llvm::AnalysisGetter::HasLegacyWrapper<Analysis, std::void_t<typename Analysis::LegacyWrapper> >'
constexpr bool AnalysisGetter::HasLegacyWrapper<
^~~~~~~~~~~~~~~~~
Analysis, std::void_t<typename Analysis::LegacyWrapper>> = true;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
E:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/include/llvm/Transforms/IPO/Attributor.h:1137:32: error: got 1 template parameters for 'constexpr const bool llvm::AnalysisGetter::HasLegacyWrapper< <template-parameter-1-1>, <template-parameter-1-2> >'
E:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/include/llvm/Transforms/IPO/Attributor.h:1137:32: error: but 2 required
[963/3411] Building CXX object lib/Transforms/IPO/CMakeFiles/LLVMipo.dir/AttributorAttributes.cpp.obj
FAILED: lib/Transforms/IPO/CMakeFiles/LLVMipo.dir/AttributorAttributes.cpp.obj
D:\Programs\Qt\Tools\mingw730_64\bin\c++.exe -DGTEST_HAS_RTTI=0 -D_DEBUG -D_FILE_OFFSET_BITS=64 -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -IE:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/build_ninja/lib/Transforms/IPO -IE:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/lib/Transforms/IPO -IE:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/build_ninja/include -IE:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/include -Wa,-mbig-obj -Werror=date-time -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wimplicit-fallthrough -Wno-maybe-uninitialized -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wno-comment -Wno-misleading-indentation -ffunction-sections -fdata-sections -O2 -DNDEBUG -fno-exceptions -fno-rtti -UNDEBUG -std=c++1z -MD -MT lib/Transforms/IPO/CMakeFiles/LLVMipo.dir/AttributorAttributes.cpp.obj -MF lib\Transforms\IPO\CMakeFiles\LLVMipo.dir\AttributorAttributes.cpp.obj.d -o lib/Transforms/IPO/CMakeFiles/LLVMipo.dir/AttributorAttributes.cpp.obj -c E:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/lib/Transforms/IPO/AttributorAttributes.cpp
In file included from E:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/lib/Transforms/IPO/AttributorAttributes.cpp:14:0:
E:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/include/llvm/Transforms/IPO/Attributor.h:1137:32: error: duplicate initialization of 'llvm::AnalysisGetter::HasLegacyWrapper<Analysis, std::void_t<typename Analysis::LegacyWrapper> >'
constexpr bool AnalysisGetter::HasLegacyWrapper<
^~~~~~~~~~~~~~~~~
Analysis, std::void_t<typename Analysis::LegacyWrapper>> = true;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
E:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/include/llvm/Transforms/IPO/Attributor.h:1137:32: error: got 1 template parameters for 'constexpr const bool llvm::AnalysisGetter::HasLegacyWrapper< <template-parameter-1-1>, <template-parameter-1-2> >'
E:/02_Source/win/llvm/llvm-project-16.0.0rc2.src/llvm/include/llvm/Transforms/IPO/Attributor.h:1137:32: error: but 2 required
[971/3411] Building CXX object lib/Transforms/IPO/CMakeFiles/LLVMipo.dir/IROutliner.cpp.obj
ninja: build stopped: subcommand failed.
```
1. source code: [llvmorg-16.0.0-rc2](https://github.com/llvm/llvm-project/releases/tag/llvmorg-16.0.0-rc2)
2. cmake version 3.23.2
3. mingw32-make: GNU Make 4.2.1 Built for x86_64-w64-mingw32
4. ninja: 1.10.2
5. windows 11: 22621.1105
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJzsWF1zmzgX_jXyjUYMiA_bF77AYFK_Eyd9Y3fTvfIIkIlSIVFJ5KMX-9t3BCRunGa33XU6ndkwHhvrHD3n0dE56BmI1qwSlM5AOAdhOiKtuZJq9jv6XzLKZXk_A5E7fNwUuDEI59NwAnDmB54HwhTOW8ZLJiqYfPwIZX5NCwM5ywHONooIvZOq1gBny_fnAGfJinyiGePUDp2e_rZijXRKpgDOYmMUy1sjlVM0jSPz6z5gFi9PFynw46OiWkAQJu-VrBSpNQiT_xsQJhspuf1TM1Hdjn13GwUgTHImQJgUAM8Bnjv0jkKUnmwW6832XbzeXmw2S-CnLkTpNl3MP5zYm2x5utieZ9l6sdnOl5s18NMosIbtepMm2-T8bL2JzzbbVZxcnK_3huz8YhU_Hz5drpb70eXCsseZi7dr2aqCApzdMgFwxvlNPfygRkm7GciLHNdxVYEdrQqAs9xu2FYwcU2s6zeT-m9jPPi8CvjTBTBR8LakR2L8iHZJAE5QnbMKyfwaokuqlFTAT0tiKDKs7nw4t5Y7owhEl0KiVrSalqghitTUUAXR5a1ihiJtFBOVhuiyINqgzy3h_Yyaac1EhXaM8hIxwQwjnH2hSkPU0JIIw4rek0tRdV8QXbK64axgBu0I5-ZKyba6GvDIfU5RK_ZIZW8Qkt4VtDHI3DeWe0k5NRQJKdANU6YlHJVGqt65kHVNhXmkyCmxPY6YKKkwxDApINrtWlHYW6Rp96sh2pXEkP1_iM4xROlZ3xcQ7YREPY3BXUikjGEQfRh8kDYl8NOh2bwvEK1SiFabI3U_RKusgwqTr6DCxEKFyVdQYfI1VJg8h3JKiOTRaBXw9RruWcj-GbgUcMc4hUPNl3CnZP1TafixFwE_dm3IjtIRW3g_8Nc8riwLzx8DP_axPWaGRo9h2domI8ZmaGimvv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