-
Notifications
You must be signed in to change notification settings - Fork 13.6k
[libc++] Fix misplaced _LIBCPP_POP_MACROS #134874
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
Conversation
As a drive-by, also remove unnecessary includes from flat container tests. Closes llvm#134681
@s-barannikov Can you please confirm that this patch solves your problem? |
@llvm/pr-subscribers-libcxx Author: Louis Dionne (ldionne) ChangesAs a drive-by, also remove unnecessary includes from flat container tests. Closes #134681 Full diff: https://github.com/llvm/llvm-project/pull/134874.diff 5 Files Affected:
diff --git a/libcxx/include/istream b/libcxx/include/istream
index 4b177c41cc325..e28d99fd84e57 100644
--- a/libcxx/include/istream
+++ b/libcxx/include/istream
@@ -1373,6 +1373,8 @@ extern template class _LIBCPP_EXTERN_TEMPLATE_TYPE_VIS basic_iostream<char>;
_LIBCPP_END_NAMESPACE_STD
+_LIBCPP_POP_MACROS
+
# endif // _LIBCPP_HAS_LOCALIZATION
# if !defined(_LIBCPP_REMOVE_TRANSITIVE_INCLUDES) && _LIBCPP_STD_VER <= 20
@@ -1382,8 +1384,6 @@ _LIBCPP_END_NAMESPACE_STD
# include <type_traits>
# endif
-_LIBCPP_POP_MACROS
-
#endif // __cplusplus < 201103L && defined(_LIBCPP_USE_FROZEN_CXX03_HEADERS)
#endif // _LIBCPP_ISTREAM
diff --git a/libcxx/test/std/containers/container.adaptors/flat.map/flat.map.iterators/reverse_iterator.pass.cpp b/libcxx/test/std/containers/container.adaptors/flat.map/flat.map.iterators/reverse_iterator.pass.cpp
index fc3949d70745f..7a111e228c115 100644
--- a/libcxx/test/std/containers/container.adaptors/flat.map/flat.map.iterators/reverse_iterator.pass.cpp
+++ b/libcxx/test/std/containers/container.adaptors/flat.map/flat.map.iterators/reverse_iterator.pass.cpp
@@ -28,7 +28,6 @@
#include <iterator>
#include "test_macros.h"
-#include <iostream>
int main(int, char**) {
{
diff --git a/libcxx/test/std/containers/container.adaptors/flat.multimap/flat.multimap.iterators/reverse_iterator.pass.cpp b/libcxx/test/std/containers/container.adaptors/flat.multimap/flat.multimap.iterators/reverse_iterator.pass.cpp
index 8c1e5451f703f..35b2b9f8a9e7e 100644
--- a/libcxx/test/std/containers/container.adaptors/flat.multimap/flat.multimap.iterators/reverse_iterator.pass.cpp
+++ b/libcxx/test/std/containers/container.adaptors/flat.multimap/flat.multimap.iterators/reverse_iterator.pass.cpp
@@ -30,7 +30,6 @@
#include <iterator>
#include "test_macros.h"
-#include <iostream>
int main(int, char**) {
{
diff --git a/libcxx/test/std/containers/container.adaptors/flat.multiset/flat.multiset.iterators/reverse_iterator.pass.cpp b/libcxx/test/std/containers/container.adaptors/flat.multiset/flat.multiset.iterators/reverse_iterator.pass.cpp
index 9d443ef8784e2..76bd49b4abd9e 100644
--- a/libcxx/test/std/containers/container.adaptors/flat.multiset/flat.multiset.iterators/reverse_iterator.pass.cpp
+++ b/libcxx/test/std/containers/container.adaptors/flat.multiset/flat.multiset.iterators/reverse_iterator.pass.cpp
@@ -28,7 +28,6 @@
#include <iterator>
#include "test_macros.h"
-#include <iostream>
void test() {
{
diff --git a/libcxx/test/std/containers/container.adaptors/flat.set/flat.set.iterators/reverse_iterator.pass.cpp b/libcxx/test/std/containers/container.adaptors/flat.set/flat.set.iterators/reverse_iterator.pass.cpp
index d1e4cef3de19e..a9ef87d483e6f 100644
--- a/libcxx/test/std/containers/container.adaptors/flat.set/flat.set.iterators/reverse_iterator.pass.cpp
+++ b/libcxx/test/std/containers/container.adaptors/flat.set/flat.set.iterators/reverse_iterator.pass.cpp
@@ -28,7 +28,6 @@
#include <iterator>
#include "test_macros.h"
-#include <iostream>
void test() {
{
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, LGTM!
It does, thank you! |
I'm going to land this since it's not controversial and has been confirmed to fix the issue. |
/cherry-pick 4ab86ed |
/pull-request #134895 |
Fixes llvm#134681 (cherry picked from commit 4ab86ed)
Fixes #134681