Skip to content

Commit

Permalink
fix: try to fix move error
Browse files Browse the repository at this point in the history
  • Loading branch information
MistEO committed Mar 15, 2024
1 parent 83671e5 commit 3a6bc13
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions include/common/array.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ class basic_array
template <
typename fixed_array_t,
std::enable_if_t<_utils::is_fixed_array<fixed_array_t>, bool> = true>
basic_array(fixed_array_t arr)
: _array_data(std::make_move_iterator(arr.begin()), std::make_move_iterator(arr.end()))
basic_array(const fixed_array_t& arr)
: _array_data(arr.begin(), arr.end())
{
}

Expand Down
4 changes: 2 additions & 2 deletions include/common/value.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@ class basic_value
template <
typename fixed_array_t,
std::enable_if_t<_utils::is_fixed_array<fixed_array_t>, bool> = true>
basic_value(fixed_array_t arr)
: basic_value(basic_array<string_t>(std::move(arr)))
basic_value(const fixed_array_t& arr)
: basic_value(basic_array<string_t>(arr))
{
}

Expand Down

0 comments on commit 3a6bc13

Please sign in to comment.