I think LocatableParser2 needs two parametrized types : T for the parser reference, U for the handler and the typecast of ctx.result.