alias R = Result!int; assert(R.err("failure").andThen!(i => i + 3) == "failure".err); assert(R.ok(7).andThen!(i => i + 3) == 10.ok);
See Implementation