qwr
qwr

Reputation: 10919

Does PyPy support gmpy2?

It seems from the discussions issue #60 and issue #40 that PyPy couldn't build gmpy before. All I intend to use currently is the probable prime is_prime code which is conveniently in gmpy2. I get the impression that the more calls to gmpy2 means less efficiency for PyPy. Is using gmpy2 possible currently, or do I have to use something like GMPY_CFFI?

The error I get when using pip in PyPy is cannot open include file 'mpir.h'

Upvotes: 0

Views: 970

Answers (1)

casevh
casevh

Reputation: 11404

You should use GMPY_CFFI. gmpy and gmpy2 rely on too many internal details of CPython to be ported to PyPy.

Note: I maintain gmpy2.

Upvotes: 3

Related Questions