Explicitly implement isValidX
Explicitly implement isValidX

The implementation in the base class will not work for rationals.

x.toLong == x.toInt does not guarantee that the value is within long range
for values that can become larger than a long.

Fixes #385

However, there should be some tests to make sure this does not happen again.

siddhartha-gadgil/spire,non/spire,tixxit/spire,codeaudit/spire,rklaehn/spire,guersam/spire,codeaudit/spire,tixxit/spire,rklaehn/spire,siddhartha-gadgil/spire,non/spire,guersam/spire,JackSullivan/spire,adampingel/spire,adampingel/spire,JackSullivan/spire,woparry/spire,AlecZorab/spire,kevinmeredith/spire,AlecZorab/spire,kevinmeredith/spire,woparry/spire