pyo3/tests/ui/invalid_pyclass_args.rs

28 lines
488 B
Rust
Raw Normal View History

use pyo3::prelude::*;
#[pyclass(extend=pyo3::types::PyDict)]
struct TypoIntheKey {}
#[pyclass(extends = "PyDict")]
struct InvalidExtends {}
#[pyclass(name = m::MyClass)]
struct InvalidName {}
2020-12-12 09:50:25 +00:00
#[pyclass(name = "Custom Name")]
struct InvalidName2 {}
#[pyclass(name = CustomName)]
struct DeprecatedName {}
#[pyclass(module = my_module)]
struct InvalidModule {}
#[pyclass(weakrev)]
struct InvalidArg {}
#[pyclass(mapping, sequence)]
struct CannotBeMappingAndSequence {}
fn main() {}