mirror of
https://github.com/ceres-solver/ceres-solver.git
synced 2026-08-29 08:34:37 +08:00
Fix warning C4373 in Visual Studio
The warning occurs because an overridden function added a const to one argument. Change-Id: Idd24f7c6ab60064747104bfc75ae9bf112f61b3e
This commit is contained in:
@@ -112,7 +112,7 @@ void LineSearchFunction::Init(const Vector& position,
|
||||
direction_ = direction;
|
||||
}
|
||||
|
||||
bool LineSearchFunction::Evaluate(const double x, double* f, double* g) {
|
||||
bool LineSearchFunction::Evaluate(double x, double* f, double* g) {
|
||||
scaled_direction_ = x * direction_;
|
||||
if (!evaluator_->Plus(position_.data(),
|
||||
scaled_direction_.data(),
|
||||
|
||||
@@ -231,7 +231,7 @@ class LineSearchFunction : public LineSearch::Function {
|
||||
explicit LineSearchFunction(Evaluator* evaluator);
|
||||
virtual ~LineSearchFunction() {}
|
||||
void Init(const Vector& position, const Vector& direction);
|
||||
virtual bool Evaluate(const double x, double* f, double* g);
|
||||
virtual bool Evaluate(double x, double* f, double* g);
|
||||
double DirectionInfinityNorm() const;
|
||||
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user