Skip to content

Commit 35b1fb2

Browse files
committed
fix pre-existing dev clang-format violations
Reformat 5 files that violated the dev clang-format config (ColumnLimit 59) so the grep_clangformat_cppcheck CI job passes. Line-wrapping only; no behavior change. - library/dsu/kruskal_tree.hpp - library/strings/longest_common_subsequence/lcs_dp.hpp - library/strings/manacher/manacher.hpp - tests/.../data_structures/bit_ordered_set.test.cpp - tests/.../strings/sa_sort_pairs.test.cpp
1 parent dc0274e commit 35b1fb2

5 files changed

Lines changed: 11 additions & 5 deletions

File tree

library/dsu/kruskal_tree.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#pragma once
22
//! https://mzhang2021.github.io/cp-blog/kruskal/
3-
//! requires n >= 1 (2*n-1 allocation underflows when n == 0)
3+
//! requires n >= 1 (2*n-1 allocation underflows when n ==
4+
//! 0)
45
//! @time O(n log n)
56
//! @space O(n)
67
struct kr_tree {

library/strings/longest_common_subsequence/lcs_dp.hpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@
1010
template<class T> struct lcs_dp {
1111
T t;
1212
vi dp;
13-
lcs_dp(const T& t): t(t), dp(sz(t)) { ranges::iota(dp, 0); }
13+
lcs_dp(const T& t): t(t), dp(sz(t)) {
14+
ranges::iota(dp, 0);
15+
}
1416
void push_onto_s(int c) {
1517
int v = -1;
1618
rep(i, 0, sz(t)) if (c == t[i] || dp[i] < v)

library/strings/manacher/manacher.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@
1414
//! string b a a b a
1515
//! center 1 3 5 7
1616
//!
17-
//! requires n >= 1 (2*n-1 allocation underflows when n == 0)
17+
//! requires n >= 1 (2*n-1 allocation underflows when n ==
18+
//! 0)
1819
//! @time O(n)
1920
//! @space O(n)
2021
vi manacher(const auto& s) {

tests/library_checker_aizu_tests/data_structures/bit_ordered_set.test.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ int main() {
1717
compress.push_back(x);
1818
}
1919
ranges::sort(compress);
20-
compress.erase(begin(ranges::unique(compress)), end(compress));
20+
compress.erase(begin(ranges::unique(compress)),
21+
end(compress));
2122
BIT bit(sz(compress));
2223
auto get_compressed_idx = [&](int val) -> int {
2324
int l = 0, r = sz(compress);

tests/library_checker_aizu_tests/strings/sa_sort_pairs.test.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ int main() {
1010
for (int& x : arr) cin >> x;
1111
vi compress(arr);
1212
ranges::sort(compress);
13-
compress.erase(begin(ranges::unique(compress)), end(compress));
13+
compress.erase(begin(ranges::unique(compress)),
14+
end(compress));
1415
for (int& x : arr) {
1516
int l = -1, r = int(sz(compress));
1617
while (r - l > 1) {

0 commit comments

Comments
 (0)