Refactor reifygenerics to return a type function instead of a type, which allows the creation of the type information to be lazier since some types have no reflection (like built-in js types)