#![allow(dead_code)]
use py_rs::PY;
#[derive(PY)]
#[py(export, export_to = "lifetimes/")]
struct S<'a> {
s: &'a str,
}
#[derive(PY)]
#[py(export, export_to = "lifetimes/")]
struct B<'a, T: 'a> {
a: &'a T,
}
#[derive(PY)]
#[py(export, export_to = "lifetimes/")]
struct A<'a> {
a: &'a &'a &'a Vec<u32>, b: &'a Vec<B<'a, u32>>, c: &'a std::collections::HashMap<String, bool>, }
#[test]
fn contains_borrow() {
assert_eq!(S::decl(), "type S = { s: string, };")
}
#[test]
fn contains_borrow_type_args() {
assert_eq!(
A::decl(),
"type A = { a: Array<number>, b: Array<B<number>>, c: { [key in string]?: boolean }, };"
);
}