Skip to content

Releases: hazae41/result

1.1.16 — Compile-time get(), getErr()

16 Jan 10:10
Compare
Choose a tag to compare
  • BREAKING: Modified get not to be callable when used on Err<T> where T isn't never
  • Added getErr for symmetry

Summary

The behaviour of get now becomes fully compile-safe as it no longer returns error types

function f(result: Result<string, Error>) {
   return result.get() // won't compile
}
function f(result: Result<string, never>) {
  return result.get() // will compile
}

1.1.3 - .flatten()

09 Sep 19:24
Compare
Choose a tag to compare
  • Added .flatten() method in Ok and Err (Result.flatten is still available as a static function)

1.1 - Minor breaking changes

29 Aug 16:52
Compare
Choose a tag to compare

BREAKING

  • Renamed Result.catchAndWrap to Result.runAndDoubleWrap
  • Renamed Result.catchAndUnwrap to Result.runAndUnwrap
  • Removed Result.recatch
  • Moved Debug.debug to Result.debug
  • Moved Result.rethrow to Catched.throwOrErr

Others

  • Added Result.flatten
  • Added Result.runAndWrap
  • expect and unwrap now have this as cause
  • Result.assert now returns an Err<AssertError>

1.0.46 - Deps, clean

13 Jun 15:30
Compare
Choose a tag to compare
v1.0.46

1.0.46

1.0.33 - Panic

23 May 18:05
Compare
Choose a tag to compare
v1.0.33

1.0.33

1.0.26 - Unhandled result runtime check

22 May 12:40
Compare
Choose a tag to compare

1.0.20 - Added clear()/clearErr()

11 May 15:33
Compare
Choose a tag to compare

1.0.14 - Iterators

03 May 20:01
Compare
Choose a tag to compare
v1.0.14

1.0.14

1.0.6 - Added shorthands

30 Apr 20:59
Compare
Choose a tag to compare

1.0.2 - Option

23 Apr 13:31
Compare
Choose a tag to compare
v1.0.2

1.0.2