Skip to content

Commit

Permalink
Rename to_composite to composite_to.
Browse files Browse the repository at this point in the history
As per discussion in #355.
  • Loading branch information
jtv committed Sep 15, 2020
1 parent d020e6b commit 5015f8a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion include/pqxx/field.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ public:
* Returns whether the field was null. If it was, it will not touch the
* values in @c fields.
*/
template<typename... T> bool to_composite(T &... fields) const
template<typename... T> bool composite_to(T &... fields) const
{
if (is_null())
{
Expand Down
2 changes: 1 addition & 1 deletion test/unit/test_composite.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ void test_composite_renders_to_string()

int a;
std::string b, c;
bool const nonnull{r[0].to_composite(a, b, c)};
bool const nonnull{r[0].composite_to(a, b, c)};
PQXX_CHECK(nonnull, "Mistaken nullness.");
PQXX_CHECK_EQUAL(a, 355, "Int came back wrong.");
PQXX_CHECK_EQUAL(b, "foo", "Simple string came back wrong.");
Expand Down

0 comments on commit 5015f8a

Please sign in to comment.