17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-10-18 07:59:19 +02:00

Fix the GCC 13 and MSVC builds: no brace-initialised reference from reference_wrapper, no near/far names

This commit is contained in:
maj00r
2026-10-04 02:49:05 +02:00
parent ac82db8178
commit 9bd8226c51
4 changed files with 10 additions and 10 deletions

View File

@@ -3330,9 +3330,9 @@ bool editor_mode::start_curve_fit(editor_track::straight const &Line)
return false;
if (state.fit_before.reversals != 0 || state.fit_after.reversals != 0)
return false;
auto const far = [](editor_track::curve const &Curve, glm::dvec3 const &Joint) { return editor_track::touches(*Curve.from, Joint) ? Curve.to : Curve.from; };
m_route.from = far(state.fit_before, Line.start);
m_route.to = far(state.fit_after, Line.end);
auto const other_end = [](editor_track::curve const &Curve, glm::dvec3 const &Joint) { return editor_track::touches(*Curve.from, Joint) ? Curve.to : Curve.from; };
m_route.from = other_end(state.fit_before, Line.start);
m_route.to = other_end(state.fit_after, Line.end);
route_reset();
if (m_route.chain.tracks.empty())
return false;