• Nathan Collins's avatar
    Make shortest-path functions safer. · 70d362f3
    Nathan Collins authored
    Namely:
    
    - return `Nothing` instead of failing with the dreaded `*** Exception:
      Prelude.head: empty list` (for `spLength`) or returning
      non-sense (for `sp`) when the source is not connected to the
      destination.
    
    - mention in the docs that negative edge weights will not produce the
      right answer.
    
    - add tests that check that `Nothing` and `Just` are returned when
      they should be for shortest-path operations.
    70d362f3
Name
Last commit
Last update
..
Graph Loading commit data...
Query Loading commit data...
Proxy.hs Loading commit data...