1use libc::{c_char, c_double, c_int};
2
3use crate::object::PyObject;
4
5#[cfg_attr(windows, link(name = "pythonXY"))]
6extern "C" {
7 pub fn PyOS_string_to_double(
8 str: *const c_char,
9 endptr: *mut *mut c_char,
10 overflow_exception: *mut PyObject,
11 ) -> c_double;
12 pub fn PyOS_double_to_string(
13 val: c_double,
14 format_code: c_char,
15 precision: c_int,
16 flags: c_int,
17 _type: *mut c_int,
18 ) -> *mut c_char;
19}
20
21pub const Py_DTSF_SIGN: c_int = 0x01; pub const Py_DTSF_ADD_DOT_0: c_int = 0x02; pub const Py_DTSF_ALT: c_int = 0x04; pub const Py_DTST_FINITE: c_int = 0;
28pub const Py_DTST_INFINITE: c_int = 1;
29pub const Py_DTST_NAN: c_int = 2;