pyo3/tests/ui/invalid_frozen_pyclass_borr...

24 lines
976 B
Plaintext
Raw Normal View History

error[E0271]: type mismatch resolving `<Foo as PyClass>::Frozen == False`
2023-03-09 23:41:26 +00:00
--> tests/ui/invalid_frozen_pyclass_borrow.rs:10:33
2022-11-04 04:29:23 +00:00
|
10 | let borrow = foo.as_ref(py).borrow_mut();
2023-04-21 14:22:42 +00:00
| ^^^^^^^^^^ expected `False`, found `True`
2022-11-04 04:29:23 +00:00
|
note: required by a bound in `PyCell::<T>::borrow_mut`
2022-11-04 04:29:23 +00:00
--> src/pycell.rs
|
| T: PyClass<Frozen = False>,
| ^^^^^^^^^^^^^^ required by this bound in `PyCell::<T>::borrow_mut`
error[E0271]: type mismatch resolving `<ImmutableChild as PyClass>::Frozen == False`
2023-03-09 23:41:26 +00:00
--> tests/ui/invalid_frozen_pyclass_borrow.rs:20:35
2022-11-04 04:29:23 +00:00
|
20 | let borrow = child.as_ref(py).borrow_mut();
2023-04-21 14:22:42 +00:00
| ^^^^^^^^^^ expected `False`, found `True`
2022-11-04 04:29:23 +00:00
|
note: required by a bound in `PyCell::<T>::borrow_mut`
2022-11-04 04:29:23 +00:00
--> src/pycell.rs
|
| T: PyClass<Frozen = False>,
| ^^^^^^^^^^^^^^ required by this bound in `PyCell::<T>::borrow_mut`