Open
Description
Hey, while running in debug mode I got a panic in the astar implmentation due to overflow.
thread 'Async Compute Task Pool (0)' panicked at /Users/choc/.cargo/registry/src/index.crates.io-6f17d22bba15001f/pathfinding-4.10.0/src/directed/astar.rs:140:33:
attempt to add with overflow
pathfinding/src/directed/astar.rs
Line 140 in 2aa2326
I probably have some pathological setup, but for correctness the estimated cost should probably saturate instead of wrapping. Thoughts on using new_cost.saturating_add(h)
?