-
Notifications
You must be signed in to change notification settings - Fork 890
Closed
Description
π Bug Reports
This is different to issue 246.
π Environment
- Your operating system and version: 4.15.0-50-generic Add PyDict::iterΒ #54-Ubuntu SMP
- Your python version: Python 3.6.8
- How did you install python (e.g. apt or pyenv)? Did you use a virtualenv?: Anaconda 64bit
- Your rust version (
rustc --version): rustc 1.34.0-nightly (e1c6d0057 2019-02-22) - Are you using the latest pyo3 version? Have you tried using latest master (replace
version = "0.x.y"withgit = "https://github.com/PyO3/pyo3")?version: 0.7.0
π₯ Reproducing
When using a struct with lifetime as follow:
use pyo3::prelude::*;
#[pyclass]
struct MyClass<'a> {
r: &'a u32,
}results in the compiler error:
error[E0106]: missing lifetime specifier
--> pycore/src/trace.rs:114:8
|
114 | struct MyClass<'a> {
| ^^^^^^^ expected lifetime parameter
error: aborting due to previous error
Using dependency:
[dependencies]
pyo3 = {version = "0.7.0", features = ["extension-module"]}Metadata
Metadata
Assignees
Labels
No labels