assert(Optional!int.some(3).result("failure") == 3.ok); assert(Optional!int.none.result("failure") == "failure".err);
See Implementation