Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/numpy/numpy
/ rational_sign
Function
rational_sign
numpy/core/src/umath/_rational_tests.c:265–268 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
263
}
264
265
static inline int
266
rational_sign(rational x) {
267
return x.n<0?-1:x.n==0?0:1;
268
}
269
270
static inline rational
271
rational_inverse(rational x) {
Callers
1
pyrational_richcompare
Function · 0.85
Calls
no outgoing calls
Tested by
no test coverage detected