NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
pub.dev · #3015 most downloaded on pub.dev
Definitions of Rust-like types, Option and Result, to promote safer programming.
Last release 2 years ago
no release in 18 months
Release timing varies
gaps range from 9 days to 12 months
Nearly every release is documented
notes for 16 of 16 stable releases
Nothing withdrawn
no release was ever pulled
7 years old
16 releases · first in 2020
One column per quarter.
JonasWanke: allow nullable values in Some and Ok
Some and Okamaxcz: add matchOk() , matchErr() , and unwrapOrNull() functions to Result
matchOk(), matchErr(), and unwrapOrNull() functions to Resultunwrap() function now contains the original error messageBREAKING CHANGE : Both Option and Result are now sealed classes which allows for the use of exhaustive pattern matching.
Option and Result are now sealed classessealed class change to Option and Result.kranfix: Replaced pedantic (deprecated) by very_goog_analysis .
pedantic (deprecated) by very_goog_analysis.Option into many mixins.Option async methods.Ok.unit and Err.unit static methodsrlch: Added async methods to Option<T> and Result<T, E> .
Option<T> and Result<T, E>.Option<T> and Result<T, E>.OptionFutureRedirector util to redirect methods called on Future<Option<T>>.ResultFutureRedirector util to redirect methods called on Future<Result<T, E>>.Option<T> and Result<T, E>.Option<T> and Result<T, E>.OptionFutureRedirector util to redirect methods called on Future<Option<T>>.ResultFutureRedirector util to redirect methods called on Future<Result<T, E>>.kranfix: Option<Result<T, E>>.transpose() returns a Result<Option<T>, E> .
Option<Result<T, E>>.transpose() returns a Result<Option<T>, E>.Option<Option<T>>.flatten() returns an Option<T>.Result<Option<T>, E>.transpose() returns an Option<Result<T, E>>.Result<Result<T, E>, E>.flatten() returns a Result<T, E>.Option<Result<T, E>>.transpose() returns a Result<Option<T>, E>.Option<Option<T>>.flatten() returns an Option<T>.Result<Option<T>, E>.transpose() returns an Option<Result<T, E>>.Result<Result<T, E>, E>.flatten() returns a Result<T, E>.kranfix: Fixed equality operator for Option and Result .
Option and Result.BREAKING CHANGE: can no longer pass null to Result . The rectifies the inconsistent handling of null values with regards to Option and Result .
null to Result. The rectifies the inconsistent handling of null values with regards to Option and Result.Option<T extends Object> to fix Result<int?, Exception>.ok(null).ok()Result<T extends Object, E extends Object> to fix Result<int?, Exception>.ok(null)null to Result. The rectifies the
inconsistent handling of null values with regards to Option and Result.Option<T extends Object> to fix Result<int?, Exception>.ok(null).ok()Result<T extends Object, E extends Object> to fix Result<int?, Exception>.ok(null)lemunozm: added isSome() , isNone() to Option .
isSome(), isNone() to Option.isOk(), isErr() to Result.Option.from() and Option.toNullable() to make easy conversions with nullable values.Unit type that is similar to Rust's () type.BREAKING CHANGE: migrated to null safety and Dart SDK 2.12.
match(), when() in Result, Option.Forgot to push 4.0 to GitHub, but those commits are now ahead of the changes made more recently for 4.1, so as a result there is no 4.0 release on GitHub.
BREAKING CHANGE: migrated to null safety and Dart SDK 2.12.
Add fold() function on Result that combines map() and mapErr().
fold() function on Result that combines map() and mapErr().Fix the package description and code formatting.
BREAKING CHANGES: see below for the details.
Result "ok" and "error" values are full-fledged classes now.Option "some" and "none" values are full-fledged classes now.Option.isSome() and Option.isNone() are gone, use is Some and is None.Result.isOk() and Result.isErr() are gone, use is Ok and is Err.Result constructor has been renamed to of() instead.null to the Option.some() factory constructor will yield a None.Ok and Err subclasses of Result allow for null arguments.BREAKING CHANGE: the various is methods are now getters.
simple_result, added when() as an alternative to match().is methods are now getters.Equatable in both Option and Result.==) in both Option and Result.### Added - Initial version
Your coding agent can read these notes before it upgrades. Set up the MCP server →