got rid of some usage of size_t because it was causing all kinds of problems