Use #[cfg(not(Py_LIMITED_API))] for datetime API
This commit is contained in:
parent
df3826b652
commit
dc2dbd6c19
|
@ -22,6 +22,7 @@ pub use self::codecs::*;
|
|||
pub use self::compile::*;
|
||||
pub use self::complexobject::*;
|
||||
pub use self::context::*;
|
||||
#[cfg(not(Py_LIMITED_API))]
|
||||
pub use self::datetime::*;
|
||||
pub use self::descrobject::*;
|
||||
pub use self::dictobject::*;
|
||||
|
@ -178,6 +179,7 @@ pub mod frameobject {
|
|||
opaque_struct!(PyFrameObject);
|
||||
}
|
||||
|
||||
#[cfg(not(Py_LIMITED_API))]
|
||||
pub(crate) mod datetime;
|
||||
pub(crate) mod marshal;
|
||||
|
||||
|
|
|
@ -7,9 +7,9 @@ pub use self::boolobject::PyBool;
|
|||
pub use self::bytearray::PyByteArray;
|
||||
pub use self::bytes::PyBytes;
|
||||
pub use self::complex::PyComplex;
|
||||
pub use self::datetime::PyDeltaAccess;
|
||||
#[cfg(not(Py_LIMITED_API))]
|
||||
pub use self::datetime::{
|
||||
PyDate, PyDateAccess, PyDateTime, PyDelta, PyTime, PyTimeAccess, PyTzInfo,
|
||||
PyDate, PyDateAccess, PyDateTime, PyDelta, PyDeltaAccess, PyTime, PyTimeAccess, PyTzInfo,
|
||||
};
|
||||
pub use self::dict::{IntoPyDict, PyDict};
|
||||
pub use self::floatob::PyFloat;
|
||||
|
@ -231,6 +231,7 @@ mod boolobject;
|
|||
mod bytearray;
|
||||
mod bytes;
|
||||
mod complex;
|
||||
#[cfg(not(Py_LIMITED_API))]
|
||||
mod datetime;
|
||||
mod dict;
|
||||
mod floatob;
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
#![cfg(not(Py_LIMITED_API))]
|
||||
|
||||
use pyo3::prelude::*;
|
||||
use pyo3::types::IntoPyDict;
|
||||
|
||||
|
|
Loading…
Reference in New Issue