Add support for marshalling custom smart pointer types in and out of parameters.