File tree Expand file tree Collapse file tree 1 file changed +13
-5
lines changed Expand file tree Collapse file tree 1 file changed +13
-5
lines changed Original file line number Diff line number Diff line change @@ -785,18 +785,26 @@ let crate_exports (sem:Semant.ctxt) : pe_export array =
785
785
in
786
786
787
787
(* Make some fake symbol table entries to aid in debugging. *)
788
- let export_stab (node_id , fixup ) =
789
- let name = Hashtbl. find sem.Semant. ctxt_all_item_names node_id in
788
+ let export_stab name fixup =
790
789
{
791
790
pe_export_name_fixup = new_fixup " export name fixup" ;
792
- pe_export_name = " rust$" ^ ( Ast. sprintf_name () name) ;
791
+ pe_export_name = " rust$" ^ name;
793
792
pe_export_address_fixup = fixup
794
793
}
795
794
in
795
+ let export_stab_of_fn (node_id , fixup ) =
796
+ let name = Hashtbl. find sem.Semant. ctxt_all_item_names node_id in
797
+ export_stab (" fn$" ^ (Semant. string_of_name name)) fixup
798
+ in
799
+ let export_stab_of_glue (glue , code ) =
800
+ export_stab (Semant. glue_str sem glue) code.Semant. code_fixup
801
+ in
796
802
797
803
let stabs =
798
- let pairs = htab_pairs sem.Semant. ctxt_fn_fixups in
799
- Array. of_list (List. map export_stab pairs)
804
+ Array. of_list (List. concat [
805
+ (List. map export_stab_of_fn (htab_pairs sem.Semant. ctxt_fn_fixups));
806
+ (List. map export_stab_of_glue (htab_pairs sem.Semant. ctxt_glue_code))
807
+ ])
800
808
in
801
809
802
810
Array. concat
You can’t perform that action at this time.
0 commit comments