Skip to content

Commit 9745c91

Browse files
committed
Formatting
1 parent b87f63c commit 9745c91

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

libcxx/include/optional

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1448,17 +1448,17 @@ _LIBCPP_HIDE_FROM_ABI constexpr optional<decay_t<_Tp>> make_optional(_Tp&& __v)
14481448

14491449
template <class _Tp, class... _Args>
14501450
_LIBCPP_HIDE_FROM_ABI constexpr optional<_Tp> make_optional(_Args&&... __args) {
1451-
#if _LIBCPP_STD_VER >= 26
1452-
static_assert(!is_reference_v<_Tp>, "make_optional<T&, Args...> is disallowed");
1453-
#endif
1451+
# if _LIBCPP_STD_VER >= 26
1452+
static_assert(!is_reference_v<_Tp>, "make_optional<T&, Args...> is disallowed");
1453+
# endif
14541454
return optional<_Tp>(in_place, std::forward<_Args>(__args)...);
14551455
}
14561456

14571457
template <class _Tp, class _Up, class... _Args>
14581458
_LIBCPP_HIDE_FROM_ABI constexpr optional<_Tp> make_optional(initializer_list<_Up> __il, _Args&&... __args) {
1459-
#if _LIBCPP_STD_VER >= 26
1460-
static_assert(!is_reference_v<_Tp>, "make_optional<T&, Args...> is disallowed");
1461-
#endif
1459+
# if _LIBCPP_STD_VER >= 26
1460+
static_assert(!is_reference_v<_Tp>, "make_optional<T&, Args...> is disallowed");
1461+
# endif
14621462
return optional<_Tp>(in_place, __il, std::forward<_Args>(__args)...);
14631463
}
14641464

libcxx/test/std/utilities/optional/optional.specalg/make_optional_ref.verify.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@
1313
// template <class T, class... Args>
1414
// constexpr optional<T> make_optional(Args&&... args);
1515

16-
#include <optional>
16+
#include <optional>
1717

18-
struct Foo{
18+
struct Foo {
1919
int x, y;
2020
};
2121

@@ -31,7 +31,7 @@ int main(int, char**) {
3131
// expected-error-re@optional:* 3 {{static assertion failed{{.*}} make_optional<T&, Args...> is disallowed}}
3232
std::make_optional<X&>(i);
3333
std::make_optional<int&>(1);
34-
std::make_optional<Foo&>(1,2);
34+
std::make_optional<Foo&>(1, 2);
3535

3636
// FIXME: Garbage error messages that Clang produces after the static_assert is triggered
3737
// expected-error-re@optional:* 0+ {{no matching constructor for initialization of 'optional<{{.*}}>'}}

0 commit comments

Comments
 (0)