Skip to content

Commit 91cadd5

Browse files
committed
git-clang-format
Ah! Now I understand why my local run keeps missing these formatting changes. It's because by default it only does C++ formatting on files that end in `.cpp`, so it doesn't search `string` by default, which is where I keep making changes. It's not that CI is running a more up-to-date clang-format which disagrees on style. It's that it's using a longer command line which reminds it to check extensionless C++ standard headers.
1 parent 74e11ac commit 91cadd5

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

libcxx/include/string

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -853,7 +853,10 @@ private:
853853
value_type v;
854854
};
855855
enum { __union_alignment = _LIBCPP_ALIGNOF(__union_alignment_check) };
856-
enum { __full_size = (static_cast<size_t>(__short_packed_size) + static_cast<size_t>(__union_alignment) - 1) & -static_cast<size_t>(__union_alignment) };
856+
enum {
857+
__full_size = (static_cast<size_t>(__short_packed_size) + static_cast<size_t>(__union_alignment) - 1) &
858+
-static_cast<size_t>(__union_alignment)
859+
};
857860

858861
// Now define both structures for real, with padding to ensure they are both
859862
// exactly the calculated size.
@@ -875,7 +878,8 @@ private:
875878

876879
struct __short {
877880
value_type __data_[__min_cap];
878-
_LIBCPP_NO_UNIQUE_ADDRESS __padding<static_cast<size_t>(__full_size) - static_cast<size_t>(__short_packed_size)> __padding_;
881+
_LIBCPP_NO_UNIQUE_ADDRESS __padding<static_cast<size_t>(__full_size) - static_cast<size_t>(__short_packed_size)>
882+
__padding_;
879883
unsigned char __size_ : 7;
880884
unsigned char __is_long_ : 1;
881885
};

0 commit comments

Comments
 (0)