File tree Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -306,6 +306,18 @@ void java_bytecode_convert_classt::convert(const classt &c)
306
306
}
307
307
}
308
308
309
+ // now do lambda method handles (bootstrap methods)
310
+ for (const auto &lambda_entry : c.lambda_method_handle_map )
311
+ {
312
+ // if the handle is of unknown type, we still need to store it to preserve
313
+ // the correct indexing (invokedynamic instructions will retrieve
314
+ // method handles according by index)
315
+ lambda_entry.second .is_unknown_handle ()
316
+ ? class_type.add_unknown_lambda_method_handle ()
317
+ : class_type.add_lambda_method_handle (
318
+ " java::" + id2string (lambda_entry.second .lambda_method_ref ));
319
+ }
320
+
309
321
// produce class symbol
310
322
symbolt new_symbol;
311
323
new_symbol.base_name =c.name ;
Original file line number Diff line number Diff line change @@ -204,6 +204,11 @@ class java_bytecode_parse_treet
204
204
lambda_method_handle.u2_values = std::move (params);
205
205
return lambda_method_handle;
206
206
}
207
+
208
+ bool is_unknown_handle () const
209
+ {
210
+ return handle_type == method_handle_typet::UNKNOWN_HANDLE;
211
+ }
207
212
};
208
213
209
214
// TODO(tkiley): This map shouldn't be interacted with directly (instead
You can’t perform that action at this time.
0 commit comments