Skip to content

Commit

Permalink
Fix doc for Arc.perimeter (#354)
Browse files Browse the repository at this point in the history
A small nit - the rustdoc for Arc.perimeter was obviously copy-pasted
from Ellipse.perimeter.
  • Loading branch information
simoncozens committed Jul 25, 2024
1 parent c9843e8 commit ce88be0
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/arc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -170,12 +170,9 @@ impl Shape for Arc {
PI * x * y
}

/// The perimeter of the ellipse.
/// The perimeter of the arc.
///
/// Note: Finding the perimeter of an ellipse is [fairly involved][wikipedia],
/// so for now we just approximate by using the bezier curve representation.
///
/// [wikipedia]: https://en.wikipedia.org/wiki/Ellipse#Circumference
/// For now we just approximate by using the bezier curve representation.
#[inline]
fn perimeter(&self, accuracy: f64) -> f64 {
self.path_segments(0.1).perimeter(accuracy)
Expand Down

0 comments on commit ce88be0

Please sign in to comment.