@@ -4,16 +4,25 @@ use rustc_codegen_ssa::traits::{DebugInfoBuilderMethods, DebugInfoMethods};
44use rustc_middle:: mir;
55use rustc_middle:: ty:: { Instance , PolyExistentialTraitRef , Ty } ;
66use rustc_span:: { SourceFile , Span , Symbol } ;
7- use rustc_target:: abi:: Size ;
87use rustc_target:: abi:: call:: FnAbi ;
8+ use rustc_target:: abi:: Size ;
9+ use std:: ops:: Range ;
910
1011use crate :: builder:: Builder ;
1112use crate :: context:: CodegenCx ;
1213
1314impl < ' a , ' gcc , ' tcx > DebugInfoBuilderMethods for Builder < ' a , ' gcc , ' tcx > {
1415 // FIXME(eddyb) find a common convention for all of the debuginfo-related
1516 // names (choose between `dbg`, `debug`, `debuginfo`, `debug_info` etc.).
16- fn dbg_var_addr ( & mut self , _dbg_var : Self :: DIVariable , _scope_metadata : Self :: DIScope , _variable_alloca : Self :: Value , _direct_offset : Size , _indirect_offsets : & [ Size ] ) {
17+ fn dbg_var_addr (
18+ & mut self ,
19+ _dbg_var : Self :: DIVariable ,
20+ _scope_metadata : Self :: DIScope ,
21+ _variable_alloca : Self :: Value ,
22+ _direct_offset : Size ,
23+ _indirect_offsets : & [ Size ] ,
24+ _fragment : Option < Range < Size > > ,
25+ ) {
1726 unimplemented ! ( ) ;
1827 }
1928
@@ -31,32 +40,64 @@ impl<'a, 'gcc, 'tcx> DebugInfoBuilderMethods for Builder<'a, 'gcc, 'tcx> {
3140}
3241
3342impl < ' gcc , ' tcx > DebugInfoMethods < ' tcx > for CodegenCx < ' gcc , ' tcx > {
34- fn create_vtable_debuginfo ( & self , _ty : Ty < ' tcx > , _trait_ref : Option < PolyExistentialTraitRef < ' tcx > > , _vtable : Self :: Value ) {
43+ fn create_vtable_debuginfo (
44+ & self ,
45+ _ty : Ty < ' tcx > ,
46+ _trait_ref : Option < PolyExistentialTraitRef < ' tcx > > ,
47+ _vtable : Self :: Value ,
48+ ) {
3549 // TODO(antoyo)
3650 }
3751
38- fn create_function_debug_context ( & self , _instance : Instance < ' tcx > , _fn_abi : & FnAbi < ' tcx , Ty < ' tcx > > , _llfn : RValue < ' gcc > , _mir : & mir:: Body < ' tcx > ) -> Option < FunctionDebugContext < Self :: DIScope , Self :: DILocation > > {
52+ fn create_function_debug_context (
53+ & self ,
54+ _instance : Instance < ' tcx > ,
55+ _fn_abi : & FnAbi < ' tcx , Ty < ' tcx > > ,
56+ _llfn : RValue < ' gcc > ,
57+ _mir : & mir:: Body < ' tcx > ,
58+ ) -> Option < FunctionDebugContext < Self :: DIScope , Self :: DILocation > > {
3959 // TODO(antoyo)
4060 None
4161 }
4262
43- fn extend_scope_to_file ( & self , _scope_metadata : Self :: DIScope , _file : & SourceFile ) -> Self :: DIScope {
63+ fn extend_scope_to_file (
64+ & self ,
65+ _scope_metadata : Self :: DIScope ,
66+ _file : & SourceFile ,
67+ ) -> Self :: DIScope {
4468 unimplemented ! ( ) ;
4569 }
4670
4771 fn debuginfo_finalize ( & self ) {
4872 // TODO(antoyo)
4973 }
5074
51- fn create_dbg_var ( & self , _variable_name : Symbol , _variable_type : Ty < ' tcx > , _scope_metadata : Self :: DIScope , _variable_kind : VariableKind , _span : Span ) -> Self :: DIVariable {
75+ fn create_dbg_var (
76+ & self ,
77+ _variable_name : Symbol ,
78+ _variable_type : Ty < ' tcx > ,
79+ _scope_metadata : Self :: DIScope ,
80+ _variable_kind : VariableKind ,
81+ _span : Span ,
82+ ) -> Self :: DIVariable {
5283 unimplemented ! ( ) ;
5384 }
5485
55- fn dbg_scope_fn ( & self , _instance : Instance < ' tcx > , _fn_abi : & FnAbi < ' tcx , Ty < ' tcx > > , _maybe_definition_llfn : Option < RValue < ' gcc > > ) -> Self :: DIScope {
86+ fn dbg_scope_fn (
87+ & self ,
88+ _instance : Instance < ' tcx > ,
89+ _fn_abi : & FnAbi < ' tcx , Ty < ' tcx > > ,
90+ _maybe_definition_llfn : Option < RValue < ' gcc > > ,
91+ ) -> Self :: DIScope {
5692 unimplemented ! ( ) ;
5793 }
5894
59- fn dbg_loc ( & self , _scope : Self :: DIScope , _inlined_at : Option < Self :: DILocation > , _span : Span ) -> Self :: DILocation {
95+ fn dbg_loc (
96+ & self ,
97+ _scope : Self :: DIScope ,
98+ _inlined_at : Option < Self :: DILocation > ,
99+ _span : Span ,
100+ ) -> Self :: DILocation {
60101 unimplemented ! ( ) ;
61102 }
62103}
0 commit comments