File tree 2 files changed +8
-0
lines changed
2 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -552,6 +552,8 @@ pub struct Function {
552
552
pub doc : Option < String > ,
553
553
pub doc_deprecated : Option < String > ,
554
554
pub finish_func : Option < String > ,
555
+ pub async_func : Option < String > ,
556
+ pub sync_func : Option < String > ,
555
557
}
556
558
557
559
#[ derive( Debug ) ]
Original file line number Diff line number Diff line change @@ -596,6 +596,8 @@ impl Library {
596
596
doc,
597
597
doc_deprecated,
598
598
finish_func : None ,
599
+ async_func : None ,
600
+ sync_func : None ,
599
601
} )
600
602
} else {
601
603
Err ( parser. fail ( "Missing <return-value> element" ) )
@@ -1019,6 +1021,8 @@ impl Library {
1019
1021
let is_method = kind == FunctionKind :: Method ;
1020
1022
let version = self . read_version ( parser, ns_id, elem) ?;
1021
1023
let deprecated_version = self . read_deprecated_version ( parser, ns_id, elem) ?;
1024
+ let async_func = elem. attr ( "async-func" ) . map ( ToString :: to_string) ;
1025
+ let sync_func = elem. attr ( "sync-func" ) . map ( ToString :: to_string) ;
1022
1026
let finish_func = c_identifier. and_then ( |c_identifier| {
1023
1027
elem. attr ( "finish-func" ) . map ( |finish_func_name| {
1024
1028
format ! (
@@ -1092,6 +1096,8 @@ impl Library {
1092
1096
doc,
1093
1097
doc_deprecated,
1094
1098
finish_func,
1099
+ async_func,
1100
+ sync_func,
1095
1101
} )
1096
1102
} else {
1097
1103
Err ( parser. fail_with_position (
You can’t perform that action at this time.
0 commit comments