[libcxx-commits] [libcxx] 98e3d98 - [libc++] Rename local variable to avoid shadowing error (#77672)
via libcxx-commits
libcxx-commits at lists.llvm.org
Wed Jan 10 14:28:27 PST 2024
Author: Christopher Di Bella
Date: 2024-01-10T17:28:22-05:00
New Revision: 98e3d98bf34ff9202e8b82d4967c02e4fd7d6532
URL: https://github.com/llvm/llvm-project/commit/98e3d98bf34ff9202e8b82d4967c02e4fd7d6532
DIFF: https://github.com/llvm/llvm-project/commit/98e3d98bf34ff9202e8b82d4967c02e4fd7d6532.diff
LOG: [libc++] Rename local variable to avoid shadowing error (#77672)
Due to the inclusion of a header, a global type is was being shadowed,
which upset GCC.
Added:
Modified:
libcxx/test/std/ranges/range.adaptors/range.join/range.join.sentinel/ctor.other.pass.cpp
Removed:
################################################################################
diff --git a/libcxx/test/std/ranges/range.adaptors/range.join/range.join.sentinel/ctor.other.pass.cpp b/libcxx/test/std/ranges/range.adaptors/range.join/range.join.sentinel/ctor.other.pass.cpp
index fb1e8eb1ebefa6..8e78c3732e2080 100644
--- a/libcxx/test/std/ranges/range.adaptors/range.join/range.join.sentinel/ctor.other.pass.cpp
+++ b/libcxx/test/std/ranges/range.adaptors/range.join/range.join.sentinel/ctor.other.pass.cpp
@@ -71,10 +71,10 @@ constexpr bool test() {
BufferView<forward_iterator<const Inner*>, sentinel_wrapper<forward_iterator<const Inner*>>,
bidirectional_iterator<Inner*>, sentinel_wrapper<bidirectional_iterator<Inner*>>>;
using JoinView = std::ranges::join_view<ConstInconvertibleOuter>;
- using sentinel = std::ranges::sentinel_t<JoinView>;
- using const_sentinel = std::ranges::sentinel_t<const JoinView>;
- static_assert(!std::constructible_from<sentinel, const_sentinel>);
- static_assert(!std::constructible_from<const_sentinel, sentinel>);
+ using sentinel_t = std::ranges::sentinel_t<JoinView>;
+ using const_sentinel_t = std::ranges::sentinel_t<const JoinView>;
+ static_assert(!std::constructible_from<sentinel_t, const_sentinel_t>);
+ static_assert(!std::constructible_from<const_sentinel_t, sentinel_t>);
}
return true;
}
More information about the libcxx-commits
mailing list