Skip to content

Commit 1aef5a4

Browse files
committed
small tweaks to satify the latest linting
1 parent 80a1f0d commit 1aef5a4

File tree

2 files changed

+9
-12
lines changed

2 files changed

+9
-12
lines changed

generators/java-oo-bindgen/src/java/mod.rs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -189,12 +189,10 @@ fn generate_native_func_class(lib: &Library, config: &JavaBindgenConfig) -> Form
189189
}
190190
}
191191
}
192-
if let ReturnType::Type(return_type, _) = &handle.return_type {
193-
if let Type::ClassRef(class_handle) = &return_type {
194-
// We don't want to generate the `create` method of collections
195-
if lib.find_collection(&class_handle.name).is_some() {
196-
continue;
197-
}
192+
if let ReturnType::Type(Type::ClassRef(class_handle), _) = &handle.return_type {
193+
// We don't want to generate the `create` method of collections
194+
if lib.find_collection(&class_handle.name).is_some() {
195+
continue;
198196
}
199197
}
200198

generators/java-oo-bindgen/src/rust/mod.rs

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -201,12 +201,11 @@ fn generate_functions(
201201
}
202202
}
203203
}
204-
if let ReturnType::Type(return_type, _) = &handle.return_type {
205-
if let Type::ClassRef(class_handle) = &return_type {
206-
// We don't want to generate the `create` method of collections
207-
if lib.find_collection(&class_handle.name).is_some() {
208-
continue;
209-
}
204+
205+
if let ReturnType::Type(Type::ClassRef(class_handle), _) = &handle.return_type {
206+
// We don't want to generate the `create` method of collections
207+
if lib.find_collection(&class_handle.name).is_some() {
208+
continue;
210209
}
211210
}
212211

0 commit comments

Comments
 (0)