Skip to content

Commit

Permalink
tests: use properly std::move to fix macOS build
Browse files Browse the repository at this point in the history
Signed-off-by: Martin Olivier <[email protected]>
  • Loading branch information
martin-olivier committed Feb 12, 2025
1 parent 3582e38 commit d072184
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/tests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,8 @@ TEST(cpp_symbols, functions_overload_namespace) {
EXPECT_EQ(ref_format(TEST_TEXT), "ref: " TEST_TEXT);

auto mov_format = lib.get_function<std::string(std::string &&)>("tools::string::format(" STD_STRING " &&)");
EXPECT_EQ(mov_format(std::move(std::string(TEST_TEXT))), "mov: " TEST_TEXT);
auto mov_text = std::string(TEST_TEXT);
EXPECT_EQ(mov_format(std::move(mov_text)), "mov: " TEST_TEXT);

auto int_ref_println = lib.get_function<std::string(const unsigned int &)>("tools::string::format(unsigned int const &)");
EXPECT_EQ(int_ref_println(123), "ref: 123");
Expand Down

0 comments on commit d072184

Please sign in to comment.