Merge pull request #2107 from hannobraun/cleanup

Remove unnecessary `pub`s
This commit is contained in:
Hanno Braun 2023-11-23 17:49:26 +01:00 committed by GitHub
commit b95253ac4d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -90,12 +90,12 @@ impl Polygon {
true true
} }
pub fn contains_exterior_edge(&self, edge: Segment<2>) -> bool { fn contains_exterior_edge(&self, edge: Segment<2>) -> bool {
self.exterior.segments().contains(&edge) self.exterior.segments().contains(&edge)
|| self.exterior.segments().contains(&edge.reverse()) || self.exterior.segments().contains(&edge.reverse())
} }
pub fn contains_interior_edge(&self, edge: Segment<2>) -> bool { fn contains_interior_edge(&self, edge: Segment<2>) -> bool {
let mut contains = false; let mut contains = false;
for chain in &self.interiors { for chain in &self.interiors {
@ -113,7 +113,7 @@ impl Polygon {
/// This code is being duplicated by the `Contains<Point<2>>` implementation /// This code is being duplicated by the `Contains<Point<2>>` implementation
/// for `Face`. It would be nice to be able to consolidate the duplication, /// for `Face`. It would be nice to be able to consolidate the duplication,
/// but this has turned out to be difficult. /// but this has turned out to be difficult.
pub fn contains_point(&self, point: impl Into<Point<2>>) -> bool { fn contains_point(&self, point: impl Into<Point<2>>) -> bool {
let ray = HorizontalRayToTheRight { let ray = HorizontalRayToTheRight {
origin: point.into(), origin: point.into(),
}; };