From 0ef1156801165f50037165350be565209b805d89 Mon Sep 17 00:00:00 2001 From: Matt Corallo Date: Mon, 19 Sep 2022 12:51:02 +0000 Subject: [PATCH] Allow liftime bounds on generic bounds While liftime bounds require bindings users to ensure liftime requirements are met, they're important for allowing us to export lock wrappers. Thus, we relax the simple-bounds assertions checks here. --- c-bindings-gen/src/types.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/c-bindings-gen/src/types.rs b/c-bindings-gen/src/types.rs index c35b7ae..5fd874d 100644 --- a/c-bindings-gen/src/types.rs +++ b/c-bindings-gen/src/types.rs @@ -147,7 +147,7 @@ pub fn export_status(attrs: &[syn::Attribute]) -> ExportStatus { } pub fn assert_simple_bound(bound: &syn::TraitBound) { - if bound.paren_token.is_some() || bound.lifetimes.is_some() { unimplemented!(); } + if bound.paren_token.is_some() { unimplemented!(); } if let syn::TraitBoundModifier::Maybe(_) = bound.modifier { unimplemented!(); } } -- 2.39.5