Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #4: make buildable on Mac OS / with Clang #5

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions include/okapi/api/units/RQuantityName.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#include "okapi/api/units/QLength.hpp"
#include "okapi/api/units/QSpeed.hpp"
#include <stdexcept>
#include <string>
#include <typeindex>
#include <unordered_map>

Expand Down
2 changes: 1 addition & 1 deletion include/test/tests/api/implMocks.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ class MockTimer : public AbstractTimer {

QTime millis() const override;

std::chrono::system_clock::time_point epoch = std::chrono::high_resolution_clock::from_time_t(0);
std::chrono::system_clock::time_point epoch = std::chrono::system_clock::from_time_t(0);
};

/**
Expand Down
4 changes: 3 additions & 1 deletion src/api/chassis/controller/defaultOdomChassisController.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@ void DefaultOdomChassisController::driveToPoint(const Point &ipoint,
const QLength &ioffset) {
waitForOdomTask();

auto [length, angle] = OdomMath::computeDistanceAndAngleToPoint(
QLength length;
QAngle angle;
std::tie<QLength, QAngle>(length, angle) = OdomMath::computeDistanceAndAngleToPoint(
ipoint.inFT(defaultStateMode), odom->getState(StateMode::FRAME_TRANSFORMATION));

if (ibackwards) {
Expand Down
2 changes: 1 addition & 1 deletion test/implMocks.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ MockTimer::MockTimer() : AbstractTimer(millis()) {

QTime MockTimer::millis() const {
return std::chrono::duration_cast<std::chrono::milliseconds>(
std::chrono::high_resolution_clock::now() - epoch)
std::chrono::system_clock::now() - epoch)
.count() *
millisecond;
}
Expand Down