alias O = Optional!int; assert(O.none.andThen!(i => some(i + 3)) == none); assert(O.some(7).andThen!(i => none) == none);
See Implementation