diff --git a/.verify-helper/timestamps.remote.json b/.verify-helper/timestamps.remote.json index cea03d47..16833fc1 100644 --- a/.verify-helper/timestamps.remote.json +++ b/.verify-helper/timestamps.remote.json @@ -19,10 +19,10 @@ "tests/library_checker_aizu_tests/data_structures/disjoint_rmq_inc.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/data_structures/disjoint_rmq_inc_lines.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/data_structures/disjoint_rmq_inc_sum.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/data_structures/distinct_query.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/data_structures/implicit_seg_tree.test.cpp": "2026-07-06 13:10:16 -0700", +"tests/library_checker_aizu_tests/data_structures/distinct_query.test.cpp": "2026-07-07 10:02:09 -0700", +"tests/library_checker_aizu_tests/data_structures/implicit_seg_tree.test.cpp": "2026-07-07 10:02:09 -0700", "tests/library_checker_aizu_tests/data_structures/kd_bit_1d.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/data_structures/kth_smallest_pst.test.cpp": "2026-07-06 13:10:16 -0700", +"tests/library_checker_aizu_tests/data_structures/kth_smallest_pst.test.cpp": "2026-07-07 10:02:09 -0700", "tests/library_checker_aizu_tests/data_structures/kth_smallest_wavelet_matrix.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/data_structures/lazy_segment_tree.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/data_structures/lazy_segment_tree_constructor.test.cpp": "2026-07-06 13:10:16 -0700", @@ -31,8 +31,8 @@ "tests/library_checker_aizu_tests/data_structures/merge_sort_tree.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/data_structures/mode_query.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/data_structures/permutation_tree.test.cpp": "2026-07-07 09:17:02 -0700", -"tests/library_checker_aizu_tests/data_structures/persistent_queue_tree.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/data_structures/persistent_seg_tree.test.cpp": "2026-07-06 13:10:16 -0700", +"tests/library_checker_aizu_tests/data_structures/persistent_queue_tree.test.cpp": "2026-07-07 10:02:09 -0700", +"tests/library_checker_aizu_tests/data_structures/persistent_seg_tree.test.cpp": "2026-07-07 10:02:09 -0700", "tests/library_checker_aizu_tests/data_structures/pq_ds_undo_sliding_window.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/data_structures/rmq_linear.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/data_structures/rmq_sparse_table.test.cpp": "2026-07-06 13:10:16 -0700", @@ -74,14 +74,14 @@ "tests/library_checker_aizu_tests/graphs/strongly_connected_components_aizu.test.cpp": "2026-07-07 09:27:22 -0700", "tests/library_checker_aizu_tests/graphs/strongly_connected_components_lib_checker.test.cpp": "2026-07-07 09:27:22 -0700", "tests/library_checker_aizu_tests/graphs/two_edge_components.test.cpp": "2026-07-07 09:27:22 -0700", -"tests/library_checker_aizu_tests/handmade_tests/count_paths.test.cpp": "2026-07-07 09:27:22 -0700", +"tests/library_checker_aizu_tests/handmade_tests/count_paths.test.cpp": "2026-07-07 10:12:26 -0700", "tests/library_checker_aizu_tests/handmade_tests/dsu.test.cpp": "2026-07-07 09:17:02 -0700", "tests/library_checker_aizu_tests/handmade_tests/edge_cd_small_trees.test.cpp": "2026-07-07 09:27:22 -0700", "tests/library_checker_aizu_tests/handmade_tests/fib_matrix_expo.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/handmade_tests/functional_graph.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/handmade_tests/hilbert_mos.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/handmade_tests/kd_bit.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/handmade_tests/kth_par.test.cpp": "2026-07-06 13:10:16 -0700", +"tests/library_checker_aizu_tests/handmade_tests/kth_par.test.cpp": "2026-07-07 10:12:26 -0700", "tests/library_checker_aizu_tests/handmade_tests/manacher.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/handmade_tests/merge_st_and_wavelet.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/handmade_tests/mobius.test.cpp": "2026-07-06 13:10:16 -0700", @@ -104,7 +104,7 @@ "tests/library_checker_aizu_tests/math/matrix_determinant.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/math/matrix_mult.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/math/n_choose_k.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/math/num_subsequences.test.cpp": "2026-07-06 13:10:16 -0700", +"tests/library_checker_aizu_tests/math/num_subsequences.test.cpp": "2026-07-07 10:02:09 -0700", "tests/library_checker_aizu_tests/math/partitions.test.cpp": "2025-08-28 13:19:16 -0600", "tests/library_checker_aizu_tests/math/prime_sieve.test.cpp": "2026-07-06 13:10:16 -0700", "tests/library_checker_aizu_tests/math/solve_linear_mod.test.cpp": "2026-07-06 13:10:16 -0700", @@ -137,17 +137,17 @@ "tests/library_checker_aizu_tests/trees/edge_cd_contour_range_update.test.cpp": "2026-07-07 09:27:22 -0700", "tests/library_checker_aizu_tests/trees/edge_cd_count_paths_per_length.test.cpp": "2026-07-07 09:27:22 -0700", "tests/library_checker_aizu_tests/trees/edge_cd_reroot_dp.test.cpp": "2026-07-07 09:27:22 -0700", -"tests/library_checker_aizu_tests/trees/hld_aizu1.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/trees/hld_aizu2.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/trees/hld_lib_checker_path.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/trees/hld_lib_checker_subtree_edges.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/trees/hld_lib_checker_subtree_nodes.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/trees/kth_path_hagerup.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/trees/kth_path_ladder.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/trees/kth_path_linear.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/trees/kth_path_tree_lift.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/trees/lca_all_methods_aizu.test.cpp": "2026-07-06 13:10:16 -0700", -"tests/library_checker_aizu_tests/trees/lca_all_methods_lib_checker.test.cpp": "2026-07-06 13:10:16 -0700", +"tests/library_checker_aizu_tests/trees/hld_aizu1.test.cpp": "2026-07-07 10:12:26 -0700", +"tests/library_checker_aizu_tests/trees/hld_aizu2.test.cpp": "2026-07-07 10:12:26 -0700", +"tests/library_checker_aizu_tests/trees/hld_lib_checker_path.test.cpp": "2026-07-07 10:12:26 -0700", +"tests/library_checker_aizu_tests/trees/hld_lib_checker_subtree_edges.test.cpp": "2026-07-07 10:12:26 -0700", +"tests/library_checker_aizu_tests/trees/hld_lib_checker_subtree_nodes.test.cpp": "2026-07-07 10:12:26 -0700", +"tests/library_checker_aizu_tests/trees/kth_path_hagerup.test.cpp": "2026-07-07 10:12:26 -0700", +"tests/library_checker_aizu_tests/trees/kth_path_ladder.test.cpp": "2026-07-07 10:12:26 -0700", +"tests/library_checker_aizu_tests/trees/kth_path_linear.test.cpp": "2026-07-07 10:12:26 -0700", +"tests/library_checker_aizu_tests/trees/kth_path_tree_lift.test.cpp": "2026-07-07 10:12:26 -0700", +"tests/library_checker_aizu_tests/trees/lca_all_methods_aizu.test.cpp": "2026-07-07 10:12:26 -0700", +"tests/library_checker_aizu_tests/trees/lca_all_methods_lib_checker.test.cpp": "2026-07-07 10:12:26 -0700", "tests/library_checker_aizu_tests/trees/shallowest_aizu_tree_height.test.cpp": "2026-07-07 09:27:22 -0700", "tests/library_checker_aizu_tests/trees/shallowest_lib_checker_tree_path_composite.test.cpp": "2026-07-07 09:27:22 -0700", "tests/library_checker_aizu_tests/trees/subtree_isomorphism.test.cpp": "2026-07-07 09:27:22 -0700" diff --git a/library/trees/hld.hpp b/library/trees/hld.hpp index 65263ba5..27b18e21 100644 --- a/library/trees/hld.hpp +++ b/library/trees/hld.hpp @@ -14,6 +14,7 @@ template struct HLD { int n; vi p, siz, rt, tin; HLD(auto& g): n(sz(g)), p(n), siz(n, 1), rt(n), tin(n) { + // pass-self, not deducing this: gcc bug 118291 auto dfs1 = [&](auto dfs1, int u) -> void { for (int& v : g[u]) { erase(g[v], p[v] = u); diff --git a/library/trees/lca_rmq.hpp b/library/trees/lca_rmq.hpp index 1b87f7ef..9914ab90 100644 --- a/library/trees/lca_rmq.hpp +++ b/library/trees/lca_rmq.hpp @@ -16,6 +16,7 @@ struct LCA { LCA(const auto& g): n(sz(g)), tin(n), siz(n, 1), d(n), p(n) { vi order; + // pass-self, not deducing this: gcc bug 118291 auto dfs = [&](auto&& dfs, int u) -> void { tin[u] = sz(order), order.push_back(u); for (int v : g[u]) diff --git a/library/trees/linear_lca.hpp b/library/trees/linear_lca.hpp index 9fa513ca..fbc14084 100644 --- a/library/trees/linear_lca.hpp +++ b/library/trees/linear_lca.hpp @@ -13,6 +13,7 @@ struct linear_lca { linear_lca(const auto& g): n(sz(g)), d(n), in(n), asc(n), head(n + 1) { vector order; + // pass-self, not deducing this: gcc bug 118291 auto dfs = [&](auto&& dfs, int u, int p) -> void { order.emplace_back(u, p), in[u] = sz(order); for (int v : g[u]) diff --git a/library/trees/tree_lift.hpp b/library/trees/tree_lift.hpp index f2283f09..13fe0b42 100644 --- a/library/trees/tree_lift.hpp +++ b/library/trees/tree_lift.hpp @@ -11,6 +11,7 @@ struct tree_lift { vi d, p, j; tree_lift(const auto& g): d(sz(g)), p(d), j(d) { + // pass-self, not deducing this: gcc bug 118291 auto dfs = [&](auto&& dfs, int u) -> void { int up = d[u] + d[j[j[u]]] == 2 * d[j[u]] ? j[j[u]] : u; diff --git a/library/trees/uncommon/hagerup_kth_par.hpp b/library/trees/uncommon/hagerup_kth_par.hpp index 63648298..dc4ca57c 100644 --- a/library/trees/uncommon/hagerup_kth_par.hpp +++ b/library/trees/uncommon/hagerup_kth_par.hpp @@ -21,6 +21,7 @@ template struct hagerup { jmp[t] = st[max(0, s - K * (t & -t))]; t++; }; + // pass-self, not deducing this: gcc bug 118291 auto dfs = [&](auto&& dfs, int u, int p) -> void { int& l = leaf[u] = st[d[u]] = u; pos[u] = t; diff --git a/library/trees/uncommon/ladder_decomposition.hpp b/library/trees/uncommon/ladder_decomposition.hpp index bc9e31e5..f9b636cd 100644 --- a/library/trees/uncommon/ladder_decomposition.hpp +++ b/library/trees/uncommon/ladder_decomposition.hpp @@ -20,6 +20,7 @@ struct ladder { n(sz(g)), d(n), p(n), idx(n), lad(2 * n) { int i = 0; vi st(n); + // pass-self, not deducing this: gcc bug 118291 auto dfs = [&](auto&& dfs, int u) -> vi { vi path; st[d[u]] = u; diff --git a/library/trees/uncommon/linear_kth_par.hpp b/library/trees/uncommon/linear_kth_par.hpp index f5224ce8..f59cb683 100644 --- a/library/trees/uncommon/linear_kth_par.hpp +++ b/library/trees/uncommon/linear_kth_par.hpp @@ -23,6 +23,7 @@ struct linear_kth_par { jmp[t] += st[du - k]; d_tour[t++] = du; }; + // pass-self, not deducing this: gcc bug 118291 auto dfs = [&](auto&& dfs, int u, int p) -> vi { vi path; tin[st[d[u]] = u] = t; diff --git a/tests/scripts/grep_clangformat_cppcheck.sh b/tests/scripts/grep_clangformat_cppcheck.sh index 353b9935..f38184cc 100755 --- a/tests/scripts/grep_clangformat_cppcheck.sh +++ b/tests/scripts/grep_clangformat_cppcheck.sh @@ -27,9 +27,7 @@ echo "check vi instead of vector" grep "vector" --recursive ../library/**/*.hpp && exit 1 echo "check begin(arr) instead of arr.begin(), similarly for end, rbegin, rend, empty, size:" -# TODO: remove this define filter if/when we move to -std=c++20 -grep --invert-match --fixed-strings "#define" --recursive ../library/ library_checker_aizu_tests/ | - grep --fixed-strings --regexp=".begin()" --regexp=".rbegin()" --regexp=".end()" --regexp=".rend()" --regexp=".empty()" --regexp=".size()" && exit 1 +grep --recursive ../library/ library_checker_aizu_tests/ --fixed-strings --regexp=".begin()" --regexp=".rbegin()" --regexp=".end()" --regexp=".rend()" --regexp=".empty()" --regexp=".size()" && exit 1 echo "check that there are no empty lines" grep "^$" ../library/**/*.hpp && exit 1