Skip to content

Commit

Permalink
Don't calculate radii again
Browse files Browse the repository at this point in the history
  • Loading branch information
tomcur committed Oct 29, 2024
1 parent d0eb63d commit 886f6a4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ellipse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ impl Shape for Ellipse {
// Note: the radii are calculated from an inner affine map (`self.inner`), and may be NaN.
// Currently, constructing an ellipse with infinite radii will produce an ellipse whose
// calculated radii are NaN.
if !self.radii().is_finite() {
if !radii.is_finite() {
return f64::NAN;
}

Expand Down

0 comments on commit 886f6a4

Please sign in to comment.