From a6d13763a6728d218f4b0eba4a4efdddab801fce Mon Sep 17 00:00:00 2001 From: Varun Agrawal Date: Fri, 10 Mar 2023 15:34:50 -0500 Subject: [PATCH 1/3] replaced concept check no op with alternate that doesn't cause a segfault --- gtsam/base/concepts.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gtsam/base/concepts.h b/gtsam/base/concepts.h index f951329a7..c9f76ca9f 100644 --- a/gtsam/base/concepts.h +++ b/gtsam/base/concepts.h @@ -19,7 +19,7 @@ // This does something sensible: #define BOOST_CONCEPT_USAGE(concept) void check##concept() // These just ignore the concept checking for now: -#define GTSAM_CONCEPT_ASSERT(concept) void*(concept) +#define GTSAM_CONCEPT_ASSERT(concept) static_assert(true, "") #define GTSAM_CONCEPT_REQUIRES(concept, return_type) return_type #endif From e5bf78e688f25d30d5d95ca506e3352cc0272cd9 Mon Sep 17 00:00:00 2001 From: Varun Agrawal Date: Fri, 10 Mar 2023 15:36:46 -0500 Subject: [PATCH 2/3] remove extra semicolons --- CppUnitLite/Test.h | 2 +- gtsam_unstable/nonlinear/ConcurrentBatchSmoother.h | 6 +++--- gtsam_unstable/nonlinear/ConcurrentIncrementalFilter.h | 6 +++--- gtsam_unstable/nonlinear/ConcurrentIncrementalSmoother.h | 6 +++--- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/CppUnitLite/Test.h b/CppUnitLite/Test.h index 040b812de..691068148 100644 --- a/CppUnitLite/Test.h +++ b/CppUnitLite/Test.h @@ -80,7 +80,7 @@ protected: #define TEST_UNSAFE(testGroup, testName)\ class testGroup##testName##Test : public Test \ { public: testGroup##testName##Test () : Test (#testName "Test", __FILE__, __LINE__, false) {} \ - virtual ~testGroup##testName##Test () {};\ + virtual ~testGroup##testName##Test () {} \ void run (TestResult& result_) override;} \ testGroup##testName##Instance; \ void testGroup##testName##Test::run (TestResult& result_) diff --git a/gtsam_unstable/nonlinear/ConcurrentBatchSmoother.h b/gtsam_unstable/nonlinear/ConcurrentBatchSmoother.h index 2afe78854..4b2d3ab1a 100644 --- a/gtsam_unstable/nonlinear/ConcurrentBatchSmoother.h +++ b/gtsam_unstable/nonlinear/ConcurrentBatchSmoother.h @@ -43,7 +43,7 @@ public: double error; ///< The final factor graph error /// Constructor - Result() : iterations(0), lambdas(0), nonlinearVariables(0), linearVariables(0), error(0) {}; + Result() : iterations(0), lambdas(0), nonlinearVariables(0), linearVariables(0), error(0) {} /// Getter methods size_t getIterations() const { return iterations; } @@ -54,10 +54,10 @@ public: }; /** Default constructor */ - ConcurrentBatchSmoother(const LevenbergMarquardtParams& parameters = LevenbergMarquardtParams()) : parameters_(parameters) {}; + ConcurrentBatchSmoother(const LevenbergMarquardtParams& parameters = LevenbergMarquardtParams()) : parameters_(parameters) {} /** Default destructor */ - ~ConcurrentBatchSmoother() override {}; + ~ConcurrentBatchSmoother() override {} /** Implement a GTSAM standard 'print' function */ void print(const std::string& s = "Concurrent Batch Smoother:\n", const KeyFormatter& keyFormatter = DefaultKeyFormatter) const override; diff --git a/gtsam_unstable/nonlinear/ConcurrentIncrementalFilter.h b/gtsam_unstable/nonlinear/ConcurrentIncrementalFilter.h index ae7f09096..9408b1b77 100644 --- a/gtsam_unstable/nonlinear/ConcurrentIncrementalFilter.h +++ b/gtsam_unstable/nonlinear/ConcurrentIncrementalFilter.h @@ -51,7 +51,7 @@ public: double error; ///< The final factor graph error /// Constructor - Result() : iterations(0), nonlinearVariables(0), linearVariables(0), error(0) {}; + Result() : iterations(0), nonlinearVariables(0), linearVariables(0), error(0) {} /// Getter methods size_t getIterations() const { return iterations; } @@ -61,10 +61,10 @@ public: }; /** Default constructor */ - ConcurrentIncrementalFilter(const ISAM2Params& parameters = ISAM2Params()) : isam2_(parameters) {}; + ConcurrentIncrementalFilter(const ISAM2Params& parameters = ISAM2Params()) : isam2_(parameters) {} /** Default destructor */ - ~ConcurrentIncrementalFilter() override {}; + ~ConcurrentIncrementalFilter() override {} /** Implement a GTSAM standard 'print' function */ void print(const std::string& s = "Concurrent Incremental Filter:\n", const KeyFormatter& keyFormatter = DefaultKeyFormatter) const override; diff --git a/gtsam_unstable/nonlinear/ConcurrentIncrementalSmoother.h b/gtsam_unstable/nonlinear/ConcurrentIncrementalSmoother.h index 334197fc6..8cf792f44 100644 --- a/gtsam_unstable/nonlinear/ConcurrentIncrementalSmoother.h +++ b/gtsam_unstable/nonlinear/ConcurrentIncrementalSmoother.h @@ -41,7 +41,7 @@ public: double error; ///< The final factor graph error /// Constructor - Result() : iterations(0), nonlinearVariables(0), linearVariables(0), error(0) {}; + Result() : iterations(0), nonlinearVariables(0), linearVariables(0), error(0) {} /// Getter methods size_t getIterations() const { return iterations; } @@ -51,10 +51,10 @@ public: }; /** Default constructor */ - ConcurrentIncrementalSmoother(const ISAM2Params& parameters = ISAM2Params()) : isam2_(parameters) {}; + ConcurrentIncrementalSmoother(const ISAM2Params& parameters = ISAM2Params()) : isam2_(parameters) {} /** Default destructor */ - ~ConcurrentIncrementalSmoother() override {}; + ~ConcurrentIncrementalSmoother() override {} /** Implement a GTSAM standard 'print' function */ void print(const std::string& s = "Concurrent Incremental Smoother:\n", const KeyFormatter& keyFormatter = DefaultKeyFormatter) const override; From 16e2ee8ae66a3b179f6af84e0191a124a7249497 Mon Sep 17 00:00:00 2001 From: Varun Agrawal Date: Fri, 10 Mar 2023 16:05:01 -0500 Subject: [PATCH 3/3] remove unnecessary header that needs boost --- gtsam/navigation/PreintegrationCombinedParams.h | 1 - 1 file changed, 1 deletion(-) diff --git a/gtsam/navigation/PreintegrationCombinedParams.h b/gtsam/navigation/PreintegrationCombinedParams.h index 151f554f7..7d775d9e4 100644 --- a/gtsam/navigation/PreintegrationCombinedParams.h +++ b/gtsam/navigation/PreintegrationCombinedParams.h @@ -24,7 +24,6 @@ /* GTSAM includes */ #include -#include #include #include #include