/dports/devel/functionalplus/FunctionalPlus-0.2.18-p0/test/ |
H A D | numeric_test.cpp | 45 REQUIRE(fplus::is_in_interval(0.09, 0.11, fplus::abs(-0.1))); 46 REQUIRE(fplus::is_in_interval(0.09, 0.11, fplus::abs( 0.1))); 126 using namespace fplus; 150 using namespace fplus; 166 using namespace fplus; 177 using namespace fplus; 209 using namespace fplus; 237 using namespace fplus; 244 using namespace fplus; 251 using namespace fplus; [all …]
|
H A D | readme_examples_test.cpp | 47 REQUIRE_EQ(fplus::count("I", fplus::split_words(false, team)), 2); 64 REQUIRE(fplus::all_by(fplus::logical_and(isCalm, isBright), entities)); 120 auto show_ints = fplus::bind_1st_of_2(fplus::show_cont_with<Ints>, " => "); 170 fplus::fwd::fold_left_1(fplus::set_intersection<characters>), 192 auto ys = fplus::transform(fplus::square<int>, xs); in square_is_even() 193 auto zs = fplus::keep_if(fplus::is_even<int>, ys); in square_is_even() 200 auto zs = fplus::keep_if(fplus::is_even<int>, fplus::transform(fplus::square<int>, xs)); in square_is_even_chain() 209 , fplus::fwd::transform(fplus::square<int>) in square_is_even_fwd_apply() 210 , fplus::fwd::keep_if(fplus::is_even<int>)); in square_is_even_fwd_apply() 215 fplus::fwd::transform(fplus::square<int>), [all …]
|
H A D | search_test.cpp | 22 auto result = fplus::find_first_by(is_even, v); 23 REQUIRE_EQ(result, fplus::just(4)); 30 REQUIRE_EQ(result, fplus::nothing<int>()); 37 REQUIRE_EQ(result, fplus::just(6)); 44 REQUIRE_EQ(result, fplus::nothing<int>()); 65 REQUIRE_EQ(result, fplus::just<size_t>(3)); 78 auto result = fplus::find_first_idx(4, v); 79 REQUIRE_EQ(result, fplus::just<size_t>(2)); 85 auto result = fplus::find_first_idx(4, v); 92 auto result = fplus::find_last_idx(4, v); [all …]
|
H A D | filter_test.cpp | 60 using namespace fplus; 90 const auto result_kept_all_strs = fplus::keep_by_idx(fplus::always<std::size_t>(true), v_strs); 129 using fplus::maybe; 130 using fplus::just; 131 using fplus::nothing; 134 auto result = fplus::justs(v); 140 using fplus::ok; 141 using fplus::error; 145 auto result = fplus::oks(v); 151 using fplus::ok; [all …]
|
H A D | udemy_course_test.cpp | 186 fplus::transform(fplus::fwd::transform(fplus::square<int>), xss); 249 int b = fplus::square(a); 258 fplus::clamp(1, 4, 259 fplus::abs_diff(7, 266 , fplus::fwd::square() 286 using namespace fplus; 366 , fplus::fwd::transform(fplus::fwd::transform_snd(visit_sum)) 375 , fplus::fwd::transform(fplus::fwd::transform_snd(visit_sum)) 398 using namespace fplus; 411 using namespace fplus; [all …]
|
H A D | generate_test.cpp | 47 auto result = fplus::repeat(3, v); 53 auto result = fplus::replicate(3, 1); 60 auto result = fplus::infixes(3, v); 71 auto result = fplus::infixes(3, v); 198 auto result = fplus::power_set(v); 246 auto result = fplus::rotate_left(v); 253 auto result = fplus::rotate_left(v); 260 auto result = fplus::rotate_right(v); 267 auto result = fplus::rotate_right(v); 338 auto result = fplus::inits(v); [all …]
|
H A D | variant_test.cpp | 33 return fplus::show(x); in show_int() 38 return fplus::show(str); in show_string() 44 using namespace fplus; 46 fplus::variant<int, double> int_or_double(3); 68 using nested = fplus::variant<int, float_or_double>; 84 using namespace fplus; 85 fplus::variant<int, std::string> int_or_string_i(3); 93 using namespace fplus; 94 fplus::variant<int, std::string> int_or_string_i(3); 102 using namespace fplus; [all …]
|
H A D | container_common_test.cpp | 58 using namespace fplus; 73 using namespace fplus; 81 using namespace fplus; 87 using namespace fplus; 105 using namespace fplus; 117 using namespace fplus; 123 using namespace fplus; 138 using namespace fplus; 148 using namespace fplus; 158 using namespace fplus; [all …]
|
H A D | benchmark_session_test.cpp | 17 fplus::benchmark_session my_benchmark_session; 53 fplus::numbers<int, std::vector<int>> in benchmark_example() 75 fplus::shuffle(std::mt19937::default_seed, ascending_numbers); in benchmark_example() 84 fplus::sort(shuffled_numbers); in benchmark_example() 98 fplus::sort(descending_numbers); in benchmark_example() 119 fplus::execute_n_times(10, [&]() { benchmark_example_bench(); }); in __anon923246230202() 153 const auto & lines = fplus::split_lines(false, report); 159 REQUIRE( fplus::all_the_same(lines_sizes) ); 162 return (fplus::count('|', s) + fplus::count('+', s) ) == 5; in __anon923246230402() 164 REQUIRE(fplus::all(check_nb_columns)); [all …]
|
H A D | timed_test.cpp | 28 void require_are_timed_equal(const fplus::timed<T> & a, const fplus::timed<T> & b) in require_are_timed_equal() 56 using namespace fplus; 59 fplus::timed<double> v; 65 fplus::timed<double> v(1., 3.); 71 fplus::timed<double> v1(2.); 81 auto v1 = fplus::timed<double>(1.); 82 auto v2 = fplus::timed<double>(2.); 93 fplus::timed<int> v(42, 1); 102 fplus::timed<int> v(42, 1.2345); 113 using namespace fplus; [all …]
|
H A D | compare_test.cpp | 37 using namespace fplus; 44 using namespace fplus; 51 using namespace fplus; 60 using namespace fplus; 71 using namespace fplus; 79 using namespace fplus; 87 using namespace fplus; 97 using namespace fplus; 109 using namespace fplus; 124 using namespace fplus; [all …]
|
H A D | composition_test.cpp | 51 using namespace fplus; 58 using namespace fplus; 66 using namespace fplus; 73 using namespace fplus; 106 using namespace fplus; 117 using namespace fplus; 129 using namespace fplus; 147 using namespace fplus; 157 using namespace fplus; 175 using namespace fplus; [all …]
|
H A D | maybe_test.cpp | 22 fplus::just(fplus::round(sqrt(static_cast<float>(x)))); in __anona315a4a30302() 47 using namespace fplus; 66 using namespace fplus; 82 using namespace fplus; 83 fplus::maybe<int> m(4); 91 using namespace fplus; 98 using namespace fplus; 109 using namespace fplus; 119 using namespace fplus; 149 using namespace fplus; [all …]
|
H A D | transform_test.cpp | 27 using namespace fplus; 33 using namespace fplus; 45 using namespace fplus; 59 using namespace fplus; 73 using namespace fplus; 84 using namespace fplus; 99 using namespace fplus; 114 using namespace fplus; 159 using namespace fplus; 174 auto result = fplus::transform_reduce( [all …]
|
H A D | container_properties_test.cpp | 21 using namespace fplus; 38 using namespace fplus; 54 using namespace fplus; 78 using namespace fplus; 101 using namespace fplus; 123 using namespace fplus; 130 using namespace fplus; 144 using namespace fplus; 153 using namespace fplus; 159 using namespace fplus; [all …]
|
H A D | fwd_test.cpp | 50 using namespace fplus; 71 using namespace fplus; 91 using namespace fplus; 95 fplus::just(fplus::round(sqrt(static_cast<float>(x)))); in __anonaf692af60502() 105 using namespace fplus; 119 using namespace fplus; 137 using namespace fplus; 152 using namespace fplus; 181 using namespace fplus; 193 using namespace fplus; [all …]
|
H A D | shared_ref_test.cpp | 23 test(int x) :m_x(x) { log("test(" + fplus::show(m_x) + ")"); } in test() 24 … test(const test& t) :m_x(t.m_x) { log("test(const test& " + fplus::show(m_x) + ")"); } in test() 25 … test(test&& t) :m_x(std::move(t.m_x)) { log("test(test&& " + fplus::show(m_x) + ")"); } in test() 27 …test& operator=(int x) { m_x = x; log("test::operator=(" + fplus::show(m… in operator =() 28 …est& t) { m_x = t.m_x; log("test::operator=(const test& " + fplus::show(m_x) + ")");… in operator =() 29 …st&& t) { m_x = std::move(t.m_x); log("test::operator=(test&& " + fplus::show(m_x) + ")");… in operator =() 31 ~test() { log("~test(" + fplus::show(m_x) + ")"); } in ~test() 37 using namespace fplus;
|
H A D | pairs_test.cpp | 27 using namespace fplus; 42 using namespace fplus; 52 using namespace fplus; 62 using namespace fplus; 69 using namespace fplus; 109 using namespace fplus; 115 using namespace fplus; 122 using namespace fplus; 128 using namespace fplus; 134 using namespace fplus; [all …]
|
H A D | result_test.cpp | 22 fplus::ok<int, std::string>(fplus::round(sqrt(static_cast<float>(x)))); in __anonf9e3fb340302() 46 using namespace fplus; 56 using namespace fplus; 67 using namespace fplus; 87 using namespace fplus; 123 using namespace fplus; 134 using namespace fplus; 147 using namespace fplus; 168 using namespace fplus; 183 using namespace fplus; [all …]
|
H A D | replace_test.cpp | 16 auto result = fplus::replace_if(is_even, 0, v); 19 auto result_rvalue = fplus::replace_if(is_even, 0, std::vector<int>({ 1, 3, 4, 6, 7 })); 26 auto result = fplus::replace_elem_at_idx(2, 0, v); 29 auto result_rvalue = fplus::replace_elem_at_idx(2, 0, std::vector<int>({ 1, 3, 4, 4, 7 })); 36 auto result = fplus::replace_elems(4, 0, v); 39 auto result_rvalue = fplus::replace_elems(4, 0, std::vector<int>({1, 3, 0, 0, 7})); 48 auto result = fplus::replace_tokens(source, dest, input);
|
/dports/misc/frugally-deep/frugally-deep-0.15.13-p0/include/fdeep/ |
H A D | tensor_shape_variable.hpp | 28 fplus::maybe<std::size_t> height, in tensor_shape_variable() 29 fplus::maybe<std::size_t> width, in tensor_shape_variable() 30 fplus::maybe<std::size_t> depth) : in tensor_shape_variable() 42 fplus::maybe<std::size_t> height, in tensor_shape_variable() 43 fplus::maybe<std::size_t> width, in tensor_shape_variable() 56 fplus::maybe<std::size_t> width, in tensor_shape_variable() 107 fplus::maybe<std::size_t> height_; 108 fplus::maybe<std::size_t> width_; 109 fplus::maybe<std::size_t> depth_; 144 fplus::show_maybe<std::size_t>, fplus::drop(5 - s.rank(), dimensions)); in show_tensor_shape_variable() [all …]
|
H A D | tensor.hpp | 669 fplus::minimum(dims_raw) >= 1 && in check_permute_tensor_dims() 671 fplus::size_of_cont(fplus::nub(dims_raw)) == in check_permute_tensor_dims() 681 const auto dims = fplus::transform(fplus::subtract<std::size_t>(1), dims_raw); in permute_tensor() 900 const auto max_length = fplus::size_of_cont(fplus::maximum_on( in show_tensor() 902 const auto strs = fplus::transform( in show_tensor() 904 return fplus::show_cont( in show_tensor() 913 return fplus::show_cont(fplus::transform(show_tensor, ts)); in show_tensors() 954 fplus::reference_interval( in tensor_into_bytes() 983 const auto values = fplus::concat(fplus::concat( in reshape_tensor_vectors() 984 fplus::transform_inner( in reshape_tensor_vectors() [all …]
|
H A D | tensor_shape.hpp | 202 fplus::just_with_default(default_shape.depth_, shape.depth_)); in make_tensor_shape_with() 205 fplus::just_with_default(default_shape.width_, shape.width_), in make_tensor_shape_with() 206 fplus::just_with_default(default_shape.depth_, shape.depth_)); in make_tensor_shape_with() 210 fplus::just_with_default(default_shape.width_, shape.width_), in make_tensor_shape_with() 211 fplus::just_with_default(default_shape.depth_, shape.depth_)); in make_tensor_shape_with() 216 fplus::just_with_default(default_shape.width_, shape.width_), in make_tensor_shape_with() 217 fplus::just_with_default(default_shape.depth_, shape.depth_)); in make_tensor_shape_with() 223 fplus::just_with_default(default_shape.width_, shape.width_), in make_tensor_shape_with() 256 return fplus::all(fplus::zip_with(tensor_shape_equals_tensor_shape_variable, in operator ==() 376 fplus::drop(5 - s.rank(), dimensions)); in show_tensor_shape() [all …]
|
/dports/devel/functionalplus/FunctionalPlus-0.2.18-p0/api_search/ |
H A D | parse_source_files.cpp | 18 const auto is_comment = fplus::bind_1st_of_2( 67 const auto doc_and_decl = fplus::span(is_comment, fplus::tail(lines)); in lines_to_function_help() 117 return fplus::drop_if(help_is_ok, helps); in get_broken_function_helps() 124 return fplus::replace_tokens( in functions_to_elm_code() 129 return fplus::replace_tokens( in functions_to_elm_code() 134 return fplus::replace_tokens( in functions_to_elm_code() 138 fplus::compose( in functions_to_elm_code() 178 result += fplus::join( in functions_to_elm_code() 193 }, fplus::map_to_pairs(occurences)); in print_duplicates() 214 if (fplus::is_not_empty(broken)) in main() [all …]
|
/dports/devel/functionalplus/FunctionalPlus-0.2.18-p0/include/fplus/ |
H A D | benchmark_session.hpp | 15 namespace fplus namespace 76 auto mean_and_dev = fplus::mean_stddev<double>(times); in make_bench_report() 79 result.total_time = fplus::sum(times); in make_bench_report() 111 fplus::stopwatch timer; in _bench_result() 144 fplus::stopwatch timer; in _bench_result() 265 return fplus::transform(largest_string_size, fplus::transpose(rows)); in show_table() 283 return fplus::sum(fplus::transform( in show_table() 285 fplus::zip(row, columns_width))); in show_table() 288 auto firstrow_separator = fplus::sum(fplus::transform(show_one_separator, columns_width)); in show_table() 297 auto report_pairs = fplus::map_to_pairs(report_map); in make_ordered_reports() [all …]
|