mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-16 03:07:55 -06:00
Avoid using auto
as type of Eigen expressions. (#8577)
According to https://eigen.tuxfamily.org/dox/TopicPitfalls.html one should just avoid using `auto` as the type of an Eigen expression. This PR fixes most of them I could found in the project. There might be cases that I missed, and I might update those later if I noticed. This should prevent issues like #7741 and hopefully fix some mysterious crashes happened inside Eigen calls.
This commit is contained in:
parent
41584cfae3
commit
51916ff058
18 changed files with 45 additions and 45 deletions
|
@ -48,8 +48,8 @@ using SplitNode = std::vector<ClipperZUtils::ZPath*>;
|
|||
static bool point_on_line(const Point& p, const Line& l)
|
||||
{
|
||||
// Check collinear
|
||||
const auto d1 = l.b - l.a;
|
||||
const auto d2 = p - l.a;
|
||||
const Vec2crd d1 = l.b - l.a;
|
||||
const Vec2crd d2 = p - l.a;
|
||||
if (d1.x() * d2.y() != d1.y() * d2.x()) {
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue