Skip to content

Commit

Permalink
Ran cargo fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
ManeraKai committed Apr 30, 2024
1 parent d6fb1e8 commit fb37847
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 16 deletions.
5 changes: 1 addition & 4 deletions src/context_handle.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,7 @@ macro_rules! set_callbacks {
#[allow(clippy::needless_lifetimes)]
fn $kind(ptr: GEOSContextHandle_t, nf: *mut InnerContext) {
#[allow(clippy::extra_unused_lifetimes)]
unsafe extern "C" fn message_handler_func(
message: *const c_char,
data: *mut c_void,
) {
unsafe extern "C" fn message_handler_func(message: *const c_char, data: *mut c_void) {
let inner_context: &InnerContext = &*(data as *mut _);

if let Ok(callback) = inner_context.$callback_name.lock() {
Expand Down
8 changes: 2 additions & 6 deletions src/from_geo.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
use crate::error::Error;
use crate::{CoordDimensions, CoordSeq, Geometry as GGeometry};
use geo_types::{
Coord, LineString, MultiLineString, MultiPoint, MultiPolygon, Point, Polygon,
};
use geo_types::{Coord, LineString, MultiLineString, MultiPoint, MultiPolygon, Point, Polygon};

use std;
use std::borrow::Borrow;
Expand Down Expand Up @@ -206,9 +204,7 @@ impl TryFrom<MultiPolygon<f64>> for GGeometry {
mod test {
use super::LineRing;
use crate::{Geom, Geometry as GGeometry};
use geo_types::{
Coord, LineString, MultiLineString, MultiPoint, MultiPolygon, Point, Polygon,
};
use geo_types::{Coord, LineString, MultiLineString, MultiPoint, MultiPolygon, Point, Polygon};
use std::convert::TryInto;

fn coords(tuples: Vec<(f64, f64)>) -> Vec<Coord<f64>> {
Expand Down
8 changes: 2 additions & 6 deletions src/geometry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -823,11 +823,7 @@ pub trait Geom:
/// assert_eq!(geom1.hausdorff_distance_densify(&geom2, 1.).map(|x| format!("{:.2}", x))
/// .unwrap(), "1.00");
/// ```
fn hausdorff_distance_densify<G: Geom>(
&self,
other: &G,
distance_frac: f64,
) -> GResult<f64>;
fn hausdorff_distance_densify<G: Geom>(&self, other: &G, distance_frac: f64) -> GResult<f64>;
/// Returns the frechet distance between `self` and `other`. The unit depends of the SRID.
///
/// Available using the `v3_7_0` feature.
Expand Down Expand Up @@ -1405,7 +1401,7 @@ pub trait Geom:
/// 0.0000000000000000 6.0000000000000000, \
/// 0.0000000000000000 0.0000000000000000)");
/// ```
fn get_exterior_ring(& self) -> GResult<ConstGeometry>;
fn get_exterior_ring(&self) -> GResult<ConstGeometry>;
}

macro_rules! impl_geom {
Expand Down

0 comments on commit fb37847

Please sign in to comment.