mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-10-24 09:46:59 -06:00
Scribble: the row loop's stop compares with partial_cmp (also stops on NaN; clippy)
This commit is contained in:
@@ -189,7 +189,7 @@ pub fn scribble(path: &PathData, b: Rect, p: &Value) -> PathData {
|
||||
// would never move it.
|
||||
while row <= 2001 {
|
||||
let y = y0 + step / 2.0 + row as f64 * step;
|
||||
if !(y < y1) {
|
||||
if y.partial_cmp(&y1) != Some(std::cmp::Ordering::Less) {
|
||||
break;
|
||||
}
|
||||
let mut xs: Vec<f64> = vec![];
|
||||
|
||||
Reference in New Issue
Block a user