static <A, B> Pair<A, B> replacePairB(Pair<A, B> p, B b) { ret p == null ? null : pair(p.a, b); }