Got rid of some unneeded typecasting of struct pa; hiding struct content is much less scary than bunch of void pointers.