(
py: Python<'p>,
expected_type_name: impl Into<String>,
received_type: PyType,
)
| 64 | |
| 65 | impl<'p> PythonObjectDowncastError<'p> { |
| 66 | pub fn new( |
| 67 | py: Python<'p>, |
| 68 | expected_type_name: impl Into<String>, |
| 69 | received_type: PyType, |
| 70 | ) -> Self { |
| 71 | let expected_type_name = expected_type_name.into(); |
| 72 | PythonObjectDowncastError { |
| 73 | py, |
| 74 | expected_type_name, |
| 75 | received_type, |
| 76 | } |
| 77 | } |
| 78 | } |
| 79 | |
| 80 | /// Trait implemented by Python object types that allow a checked downcast. |
nothing calls this directly
no outgoing calls
no test coverage detected