Skip to content

Commit

Permalink
-Wsign-compare
Browse files Browse the repository at this point in the history
  • Loading branch information
Dane Springmeyer committed Feb 11, 2014
1 parent 20ee8ff commit 12ef94a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
CXX := $(CXX)
CXXFLAGS := $(CXXFLAGS) -O3 -DNDEBUG -Wall -Wsign-conversion -Wshadow -Wunused-parameter -Wshorten-64-to-32 -pedantic -finline-functions -fvisibility-inlines-hidden -std=c++11
CXXFLAGS := $(CXXFLAGS) -O3 -DNDEBUG -Wall -Wsign-compare -Wsign-conversion -Wshadow -Wunused-parameter -Wshorten-64-to-32 -pedantic -finline-functions -fvisibility-inlines-hidden -std=c++11
LDFLAGS := $(LDFLAGS) -lboost_timer -lboost_system -lboost_chrono

OS:=$(shell uname -s)
Expand Down
6 changes: 3 additions & 3 deletions main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -76,14 +76,14 @@ int main (int argc, char** argv)
std::cerr << "Usage:" << argv[0] << " <num-runs>" << std::endl;
return 1;
}
const size_t NUM_RUNS = static_cast<size_t>(std::stol(argv[1]));
const std::size_t NUM_RUNS = static_cast<std::size_t>(std::stol(argv[1]));

#if 1
{
boost::timer::auto_cpu_timer t;
test::Holder<boost::variant<int,double,std::string>> h;
h.data.reserve(NUM_RUNS);
for (int i=0; i< NUM_RUNS;++i)
for (std::size_t i=0; i< NUM_RUNS;++i)
{
h.append_move(std::string(TEXT));
h.append_move(123);
Expand All @@ -105,7 +105,7 @@ int main (int argc, char** argv)
boost::timer::auto_cpu_timer t;
test::Holder<util::variant<int,double,std::string> > h;
h.data.reserve(NUM_RUNS);
for (int i=0; i< NUM_RUNS;++i)
for (std::size_t i=0; i< NUM_RUNS;++i)
{
h.append_move(std::string(TEXT));
h.append_move(123);
Expand Down

0 comments on commit 12ef94a

Please sign in to comment.