Skip to content

Commit

Permalink
Use 'crate::' to refer to pyo3
Browse files Browse the repository at this point in the history
Fixes: #1811
Signed-off-by: Christian Heimes <[email protected]>
  • Loading branch information
tiran committed Aug 18, 2021
1 parent 78b924d commit f305b8a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
[#1799](https://github.com/PyO3/pyo3/pull/1799)
- Add missing `Py_DECREF` to `Python::run_code` which fixes a memory leak when
calling Python from Rust. [#1806](https://github.com/PyO3/pyo3/pull/1806)
- Use crate:: syntax to refer to current crate in pyo3::types::datetime
[#1811](https://github.com/PyO3/pyo3/issues/1811)

## [0.14.2] - 2021-08-09

Expand Down
4 changes: 2 additions & 2 deletions src/types/datetime.rs
Original file line number Diff line number Diff line change
Expand Up @@ -465,8 +465,8 @@ mod tests {
#[cfg(not(PyPy))]
#[test]
fn test_new_with_fold() {
pyo3::Python::with_gil(|py| {
use pyo3::types::{PyDateTime, PyTimeAccess};
crate::Python::with_gil(|py| {
use crate::types::{PyDateTime, PyTimeAccess};

let a = PyDateTime::new_with_fold(py, 2021, 1, 23, 20, 32, 40, 341516, None, false);
let b = PyDateTime::new_with_fold(py, 2021, 1, 23, 20, 32, 40, 341516, None, true);
Expand Down

0 comments on commit f305b8a

Please sign in to comment.