Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ItaniumDemangle] reapply 0e754e114a6 #79488

Merged
merged 4 commits into from
Jan 26, 2024
Merged

[ItaniumDemangle] reapply 0e754e114a6 #79488

merged 4 commits into from
Jan 26, 2024

Conversation

nico
Copy link
Contributor

@nico nico commented Jan 25, 2024

It got lost in 50b58e8.

@nico nico requested a review from a team as a code owner January 25, 2024 19:14
@nico nico requested a review from dwblaikie January 25, 2024 19:15
@llvmbot llvmbot added the libc++abi libc++abi C++ Runtime Library. Not libc++. label Jan 25, 2024
@llvmbot
Copy link
Collaborator

llvmbot commented Jan 25, 2024

@llvm/pr-subscribers-libcxxabi

Author: Nico Weber (nico)

Changes

It got lost in 50b58e8.


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

2 Files Affected:

  • (modified) libcxxabi/src/demangle/ItaniumDemangle.h (+2-4)
  • (modified) llvm/include/llvm/Demangle/ItaniumDemangle.h (+2-4)
diff --git a/libcxxabi/src/demangle/ItaniumDemangle.h b/libcxxabi/src/demangle/ItaniumDemangle.h
index 5a53a18bcc5fe2c..9057899f7f72325 100644
--- a/libcxxabi/src/demangle/ItaniumDemangle.h
+++ b/libcxxabi/src/demangle/ItaniumDemangle.h
@@ -39,13 +39,11 @@
 DEMANGLE_NAMESPACE_BEGIN
 
 template <class T, size_t N> class PODSmallVector {
-  static_assert(std::is_pod<T>::value,
-                "T is required to be a plain old data type");
-
+  static_assert(std::is_trivial_v<T>, "T is required to be a trivial type");
   T *First = nullptr;
   T *Last = nullptr;
   T *Cap = nullptr;
-  T Inline[N] = {0};
+  T Inline[N] = {};
 
   bool isInline() const { return First == Inline; }
 
diff --git a/llvm/include/llvm/Demangle/ItaniumDemangle.h b/llvm/include/llvm/Demangle/ItaniumDemangle.h
index 06956f47c1f0b54..8dddc8dd2291155 100644
--- a/llvm/include/llvm/Demangle/ItaniumDemangle.h
+++ b/llvm/include/llvm/Demangle/ItaniumDemangle.h
@@ -38,13 +38,11 @@
 DEMANGLE_NAMESPACE_BEGIN
 
 template <class T, size_t N> class PODSmallVector {
-  static_assert(std::is_pod<T>::value,
-                "T is required to be a plain old data type");
-
+  static_assert(std::is_trivial_v<T>, "T is required to be a trivial type");
   T *First = nullptr;
   T *Last = nullptr;
   T *Cap = nullptr;
-  T Inline[N] = {0};
+  T Inline[N] = {};
 
   bool isInline() const { return First == Inline; }
 

Copy link

github-actions bot commented Jan 25, 2024

✅ With the latest revision this PR passed the C/C++ code formatter.

@nico
Copy link
Contributor Author

nico commented Jan 26, 2024

https://buildkite.com/llvm-project/libcxx-ci/builds/33217 is apparently a required check. It's been running for 3h 37m now. How about requiring required checks to complete in 20 min or so?

@nico
Copy link
Contributor Author

nico commented Jan 26, 2024

First windows bot failed with

mt.exe : general error c101008d: Failed to write the updated manifest to the resource of file "tools\mlir\unittests\Debug\MLIRDebugTests.exe". Operation did not complete successfully because the file contains a virus or potentially unwanted software.

Second with

# \| OSError: [WinError 225] Operation did not complete successfully because the file contains a virus or potentially unwanted software

I'm going to claim that's unrelated and the interesting part (the build) passed with this.

@nico nico merged commit fd0637c into llvm:main Jan 26, 2024
42 of 43 checks passed
@nico nico deleted the blaikie branch January 26, 2024 02:59
@dwblaikie
Copy link
Collaborator

Thanks for the catch!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
libc++abi libc++abi C++ Runtime Library. Not libc++.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants