Skip to content

Commit f092c72

Browse files
committed
Disable unused VTK XML support, use num sub-crates
1 parent 708ca42 commit f092c72

8 files changed

Lines changed: 12 additions & 95 deletions

File tree

Cargo.lock

Lines changed: 2 additions & 86 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

splashsurf/Cargo.toml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,7 @@ splashsurf_lib = { path = "../splashsurf_lib", version = "0.9", features = ["vtk
1717
clap = { version = "4.1", features = ["derive"] }
1818
log = "0.4"
1919
fern = "0.6"
20-
chrono = "0.4"
20+
chrono = "0.4.20"
2121
anyhow = "1.0"
22-
num = "0.4"
2322
rayon = "1.6"
2423
bytemuck = "1.9"

splashsurf_lib/Cargo.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,8 @@ io = ["vtk_extras", "vtkio", "ply-rs", "nom", "serde_json", "flate2"]
3838
[dependencies]
3939
log = "0.4"
4040
nalgebra = { version = "0.32", features = ["rand", "bytemuck"] }
41-
num = "0.4"
41+
num-traits = "0.2"
42+
num-integer = "0.1"
4243
anyhow = "1.0"
4344
thiserror = "1.0"
4445
itertools = "0.10"
@@ -56,7 +57,7 @@ numeric_literals = "0.2"
5657
rstar = "0.10"
5758

5859
# IO
59-
vtkio = { version = "0.6", optional = true }
60+
vtkio = { version = "0.6", default-features = false, optional = true } # Disable moden XML format for now (hardly used)
6061
ply-rs = { version = "0.1.3", optional = true }
6162
flate2 = { version = "1.0", optional = true }
6263
nom = { version = "7.1.3", optional = true }

splashsurf_lib/src/io/bgeo_format.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ use flate2::write::GzEncoder;
88
use flate2::Compression;
99
use nalgebra::Vector3;
1010
use nom::{Finish, Parser};
11-
use num::ToPrimitive;
11+
use num_traits::ToPrimitive;
1212
use std::fs::{File, OpenOptions};
1313
use std::io;
1414
use std::io::{BufWriter, Read};

splashsurf_lib/src/reconstruction.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ use crate::{
1313
};
1414
use log::{debug, info, trace};
1515
use nalgebra::Vector3;
16-
use num::Bounded;
16+
use num_traits::Bounded;
1717
use parking_lot::Mutex;
1818

1919
/// Performs a global surface reconstruction without domain decomposition

splashsurf_lib/src/topology.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//! Helper types for cartesian coordinate system topology
22
3-
use num::{CheckedAdd, CheckedSub, One};
3+
use num_traits::{CheckedAdd, CheckedSub, One};
44
use std::ops::{Add, Sub};
55

66
/// Direction on a number line/coordinate axis or identifiers for the end points of a line

splashsurf_lib/src/traits.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@ use std::hash::Hash;
44
use bitflags::_core::ops::{AddAssign, MulAssign, SubAssign};
55
use bytemuck::Pod;
66
use nalgebra::{RealField, SVector};
7-
use num::{Bounded, CheckedAdd, CheckedMul, CheckedSub, FromPrimitive, Integer, ToPrimitive};
7+
use num_integer::Integer;
8+
use num_traits::{Bounded, CheckedAdd, CheckedMul, CheckedSub, FromPrimitive, ToPrimitive};
89

910
/// Convenience trait that combines `Send` and `Sync`
1011
pub trait ThreadSafe: Sync + Send {}

splashsurf_lib/src/uniform_grid.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use bitflags::bitflags;
66
use itertools::iproduct;
77
use log::trace;
88
use nalgebra::Vector3;
9-
use num::Bounded;
9+
use num_traits::Bounded;
1010
use std::iter::Iterator;
1111
use thiserror::Error as ThisError;
1212

0 commit comments

Comments
 (0)