Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace std::vector for better speed; also fix clang C++11 #25

Open
wants to merge 1 commit into
base: 2.x.y
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ COMPATIBILITY

This library is compatible with C++98, but if you give compile it with C++11 or later, this library uses `std::move()` instead of value copy and thus you can sort move-only types (see [#9](https://github.com/gfx/cpp-TimSort/pull/9) for details).

You can disable use of `std::move()` by passing the macro '-DDISABLE_STD_MOVE'.
You can disable use of `std::move()` by passing the macro '-DGFX_TIMSORT_USE_CXX11=0'

SEE ALSO
==================
Expand Down
2 changes: 1 addition & 1 deletion test/test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

#include "timsort.hpp"

#if ENABLE_STD_MOVE
#if GFX_TIMSORT_USE_CXX11
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ENABLE_STD_MOVE macro was actually removed by the e39ca95 change in 2017, so this #warning was erroneously always printing "disabled"

I think the cleanest thing to do is to just let the GFX_TIMSORT_USE_CXX11 define leak out of timsort.hpp (i.e. it's not #undefed like the other macros) so it can be tested here.

#warning std::move() enabled
#else
#warning std::move() disabled
Expand Down
Loading