mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-20 02:23:35 +08:00
clang-tidy trivial cleanup
This commit is contained in:
@@ -31,7 +31,7 @@ template<typename Type>
|
||||
class AxisAngle : public Vector<Type, 3>
|
||||
{
|
||||
public:
|
||||
virtual ~AxisAngle() {};
|
||||
~AxisAngle() override = default;
|
||||
|
||||
typedef Matrix<Type, 3, 1> Matrix31;
|
||||
|
||||
|
||||
@@ -17,7 +17,6 @@
|
||||
|
||||
#include "math.hpp"
|
||||
|
||||
|
||||
namespace matrix
|
||||
{
|
||||
|
||||
@@ -30,7 +29,6 @@ class Euler;
|
||||
template<typename Type>
|
||||
class AxisAngle;
|
||||
|
||||
|
||||
/**
|
||||
* Direction cosine matrix class
|
||||
*
|
||||
|
||||
+10
-16
@@ -8,11 +8,10 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stddef.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <math.h>
|
||||
#include <cmath>
|
||||
#include <cstdio>
|
||||
#include <cstring>
|
||||
|
||||
#if defined(SUPPORT_STDIOSTREAM)
|
||||
#include <iostream>
|
||||
#include <iomanip>
|
||||
@@ -36,25 +35,20 @@ public:
|
||||
|
||||
virtual ~Matrix() {};
|
||||
|
||||
Matrix() :
|
||||
_data()
|
||||
{
|
||||
}
|
||||
// Constructors
|
||||
Matrix() : _data() {}
|
||||
|
||||
Matrix(const Type data_[][N]) :
|
||||
_data()
|
||||
Matrix(const Type data_[][N]) : _data()
|
||||
{
|
||||
memcpy(_data, data_, sizeof(_data));
|
||||
}
|
||||
|
||||
Matrix(const Type *data_) :
|
||||
_data()
|
||||
Matrix(const Type *data_) : _data()
|
||||
{
|
||||
memcpy(_data, data_, sizeof(_data));
|
||||
}
|
||||
|
||||
Matrix(const Matrix &other) :
|
||||
_data()
|
||||
Matrix(const Matrix &other) : _data()
|
||||
{
|
||||
memcpy(_data, other._data, sizeof(_data));
|
||||
}
|
||||
@@ -519,7 +513,7 @@ bool isEqualF(Type x,
|
||||
|
||||
bool equal = true;
|
||||
|
||||
if (fabsf(x - y) > eps) {
|
||||
if (fabs(x - y) > eps) {
|
||||
equal = false;
|
||||
}
|
||||
|
||||
|
||||
@@ -8,12 +8,6 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stddef.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <math.h>
|
||||
|
||||
#include "math.hpp"
|
||||
|
||||
namespace matrix
|
||||
|
||||
@@ -8,12 +8,6 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stddef.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <math.h>
|
||||
|
||||
#include "math.hpp"
|
||||
#include "helper_functions.hpp"
|
||||
|
||||
|
||||
+1
-1
@@ -22,7 +22,7 @@ template<typename Type, size_t M>
|
||||
class Vector : public Matrix<Type, M, 1>
|
||||
{
|
||||
public:
|
||||
virtual ~Vector() {};
|
||||
~Vector() override = default;
|
||||
|
||||
typedef Matrix<Type, M, 1> MatrixM1;
|
||||
|
||||
|
||||
@@ -1,14 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "math.hpp"
|
||||
|
||||
// grody hack - this should go once C++11 is supported
|
||||
// on all platforms.
|
||||
#if defined (__PX4_NUTTX) || defined (__PX4_QURT)
|
||||
#include <math.h>
|
||||
#else
|
||||
#include <cmath>
|
||||
#endif
|
||||
|
||||
namespace matrix
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user