mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-21 15:18:12 +08:00
Upgrade to the Rust 2024 edition (#2367)
* Update to rust 2024 edition * Fixes * Clean up imports * Cargo fmt again --------- Co-authored-by: Keavon Chambers <keavon@keavon.com>
This commit is contained in:
co-authored by
Keavon Chambers
parent
927d7dd9b2
commit
beb1c6ae64
@@ -7,7 +7,7 @@ pub(crate) mod path_segment;
|
||||
use glam::DVec2;
|
||||
|
||||
#[cfg(feature = "parsing")]
|
||||
use crate::path_command::{to_absolute_commands, AbsolutePathCommand, PathCommand};
|
||||
use crate::path_command::{AbsolutePathCommand, PathCommand, to_absolute_commands};
|
||||
use crate::path_segment::PathSegment;
|
||||
|
||||
pub type Path = Vec<PathSegment>;
|
||||
@@ -107,7 +107,7 @@ where
|
||||
let start = seg.start();
|
||||
let mut commands = Vec::new();
|
||||
|
||||
if last_point.map_or(true, |lp| !start.abs_diff_eq(lp, eps)) {
|
||||
if last_point.is_none_or(|lp| !start.abs_diff_eq(lp, eps)) {
|
||||
if last_point.is_some() {
|
||||
commands.push(PathCommand::Absolute(AbsolutePathCommand::Z));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user