Skip to content

Commit

Permalink
fix compile warning with gcc 9.1.0 including simplestl.h file (#4274)
Browse files Browse the repository at this point in the history
* fix compile warning with gcc 9.1.0 including simplestl.h file

* apply code-format changes

Co-authored-by: veahow <veahow@users.noreply.github.com>
  • Loading branch information
veahow and veahow committed Oct 14, 2022
1 parent b13c2a1 commit f80c274
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/simplestl.h
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,7 @@ struct vector
{
capacity_ = new_size * 2;
T* new_data = (T*)new char[capacity_ * sizeof(T)];
memset(new_data, 0, capacity_ * sizeof(T));
memset(static_cast<void*>(new_data), 0, capacity_ * sizeof(T));
if (data_)
{
memmove(new_data, data_, sizeof(T) * size_);
Expand Down

0 comments on commit f80c274

Please sign in to comment.