Return int or string for most of the GMP functions, instead of a resource. Added tests to never expect a resource to come from these functions.