@@ -25,6 +25,7 @@ use syn::{Attribute, Ident, ReturnType, Type, TypePath};
2525
2626static GLOBAL_COUNTER_FOR_UNIQUE_NAMES : AtomicUsize = AtomicUsize :: new ( 0 ) ;
2727
28+ #[ allow( clippy:: too_many_arguments) ]
2829pub fn module_introspection_code < ' a > (
2930 pyo3_crate_path : & PyO3CratePath ,
3031 name : & str ,
@@ -33,6 +34,7 @@ pub fn module_introspection_code<'a>(
3334 consts : impl IntoIterator < Item = & ' a Ident > ,
3435 consts_values : impl IntoIterator < Item = & ' a String > ,
3536 consts_cfg_attrs : impl IntoIterator < Item = & ' a Vec < Attribute > > ,
37+ incomplete : bool ,
3638) -> TokenStream {
3739 IntrospectionNode :: Map (
3840 [
@@ -74,6 +76,7 @@ pub fn module_introspection_code<'a>(
7476 . collect ( ) ,
7577 ) ,
7678 ) ,
79+ ( "incomplete" , IntrospectionNode :: Bool ( incomplete) ) ,
7780 ]
7881 . into ( ) ,
7982 )
@@ -309,6 +312,7 @@ fn argument_introspection_data<'a>(
309312
310313enum IntrospectionNode < ' a > {
311314 String ( Cow < ' a , str > ) ,
315+ Bool ( bool ) ,
312316 IntrospectionId ( Option < Cow < ' a , Type > > ) ,
313317 InputType { rust_type : Type , nullable : bool } ,
314318 OutputType { rust_type : Type } ,
@@ -342,6 +346,7 @@ impl IntrospectionNode<'_> {
342346 Self :: String ( string) => {
343347 content. push_str_to_escape ( & string) ;
344348 }
349+ Self :: Bool ( value) => content. push_str ( if value { "true" } else { "false" } ) ,
345350 Self :: IntrospectionId ( ident) => {
346351 content. push_str ( "\" " ) ;
347352 content. push_tokens ( if let Some ( ident) = ident {
0 commit comments