[llvm] [ADT] Add `<cstdint>` to SmallVector (PR #101761)

via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 2 15:09:04 PDT 2024


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-llvm-adt

Author: Sam James (thesamesam)

<details>
<summary>Changes</summary>

SmallVector uses `uint32_t`, `uint64_t` without including `<cstdint>` which fails to build w/ GCC 15 after a change in libstdc++ [0]

[0] https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=3a817a4a5a6d94da9127af3be9f84a74e3076ee2

---
Full diff: https://github.com/llvm/llvm-project/pull/101761.diff


1 Files Affected:

- (modified) llvm/include/llvm/ADT/SmallVector.h (+1) 


``````````diff
diff --git a/llvm/include/llvm/ADT/SmallVector.h b/llvm/include/llvm/ADT/SmallVector.h
index 09676d792dfeb..17444147b102a 100644
--- a/llvm/include/llvm/ADT/SmallVector.h
+++ b/llvm/include/llvm/ADT/SmallVector.h
@@ -19,6 +19,7 @@
 #include <algorithm>
 #include <cassert>
 #include <cstddef>
+#include <cstdint>
 #include <cstdlib>
 #include <cstring>
 #include <functional>

``````````

</details>


https://github.com/llvm/llvm-project/pull/101761


More information about the llvm-commits mailing list