| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Jenkins Console Log Machine information No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 20.04.3 LTS Release: 20.04 Codename: focal CPU: G++: Clang: |
Sorry, something went wrong.
There was a problem hiding this comment.
Looks good -- if you're on a consistency kick, apply_vector_unary is also "backwards"
Sorry, something went wrong.
| inline auto apply_scalar_binary(F&& f, T1&& x, T2&& y) { | ||
| check_matching_sizes("Binary function", "x", x, "y", y); | ||
| return make_holder( | ||
| [](auto& f_inner, auto& x_inner, auto& y_inner) { |
There was a problem hiding this comment.
(side note / different PR) these could be auto&& and when you call f and then you can do std::forward<decltype(x_inner)>(x_inner) etc
Sorry, something went wrong.
There was a problem hiding this comment.
Oh good shout, will work up a PR
Sorry, something went wrong.
Classic past-me making more work for future-me. Thanks will sort! |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Summary
The signature for apply_scalar_binary currently takes the functor as its last argument (i.e., apply_scalar_binary(x, y, f)) which is a bit of a non-standard pattern and isn't consistent with apply_scalar_ternary
This PR updates the signatures and function usage for apply_scalar_binary to take the binary functor as its first argument
Tests
N/A - Current tests should still pass
Side Effects
N/A
Release notes
Updated signature for apply_scalar_binary to take the functor as its first argument, instead of the last
Checklist
Copyright holder: Andrew Johnson
The copyright holder is typically you or your assignee, such as a university or company. By submitting this pull request, the copyright holder is agreeing to the license the submitted work under the following licenses:
- Code: BSD 3-clause (https://opensource.org/licenses/BSD-3-Clause)
- Documentation: CC-BY 4.0 (https://creativecommons.org/licenses/by/4.0/)
the basic tests are passing
the code is written in idiomatic C++ and changes are documented in the doxygen
the new changes are tested