fix type registry for pointers and external packages