From 9944fef40dcdd6e8904ccec4af5dd867e3e1ac17 Mon Sep 17 00:00:00 2001 From: Matteo Cypriani Date: Thu, 16 May 2013 17:42:37 -0400 Subject: [PATCH] [Positioner] Switch to C++11 This is a very basic switch, we don't use any of the C++11 features yet. --- owlps-positioner/Makefile | 3 +++ owlps-positioner/src/minmax.hh | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/owlps-positioner/Makefile b/owlps-positioner/Makefile index 8dd4642..232f4d3 100644 --- a/owlps-positioner/Makefile +++ b/owlps-positioner/Makefile @@ -15,6 +15,9 @@ DOXYGEN = OWLPS_VERSION=$(OWLPS_VERSION) doxygen >/dev/null # Flags for the tests TESTSCXXFLAGS = -I$(TESTS_DIR) -I$(SRC_DIR) -I. +# Compiler flags +CXXFLAGS += -std=c++11 + ## Additional libraries ## LDFLAGS += -lstdc++ -lm -lboost_program_options -pthread -lowlps diff --git a/owlps-positioner/src/minmax.hh b/owlps-positioner/src/minmax.hh index fe4059f..0c676ff 100644 --- a/owlps-positioner/src/minmax.hh +++ b/owlps-positioner/src/minmax.hh @@ -59,8 +59,8 @@ protected: const Point3D stop ; float step ; - static const float MINMAX_DEFAULT_STEP = 0.5 ; - static const float INFINITE = 1000000 ; + static constexpr float MINMAX_DEFAULT_STEP = 0.5 ; + static constexpr float INFINITE = 1000000 ; public: MinMax(const Point3D &_start,