Skip to content

Commit

Permalink
unique: Initialize allocator in move constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
qookei committed Jul 13, 2024
1 parent b8db328 commit cc0ff0f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/frg/unique.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ struct unique_ptr {
unique_ptr &operator=(const unique_ptr &) = delete;

unique_ptr(unique_ptr &&p)
:_ptr{nullptr} {
:_ptr{nullptr}, _allocator(p._allocator) {
swap(*this, p);
}

Expand Down

0 comments on commit cc0ff0f

Please sign in to comment.