Fix debug info
This commit is contained in:
		
							parent
							
								
									d0e1082029
								
							
						
					
					
						commit
						61d3ea61ee
					
				| @ -635,13 +635,12 @@ impl FunctionHolder { | ||||
|             let metadata = if let Some(debug) = debug { | ||||
|                 if let Some(scope_value) = &self.debug_info { | ||||
|                     let scope_data = debug.info.get_scope_data(scope_value).unwrap(); | ||||
|                     dbg!(&debug.info.get_scope()); | ||||
| 
 | ||||
|                     let mangled_length_ptr = &mut 0; | ||||
|                     let mangled_name = LLVMGetValueName2(function_ref, mangled_length_ptr); | ||||
|                     let mangled_length = *mangled_length_ptr; | ||||
| 
 | ||||
|                     dbg!(&scope_data); | ||||
| 
 | ||||
|                     let subprogram = match scope_data.kind { | ||||
|                         DebugScopeKind::CodegenContext => panic!(), | ||||
|                         DebugScopeKind::LexicalScope => panic!(), | ||||
|  | ||||
| @ -154,7 +154,7 @@ impl DebugInformation { | ||||
|             }); | ||||
| 
 | ||||
|             let mut arr = parent.0.clone(); | ||||
|             arr.push(parent.0.len()); | ||||
|             arr.push(outer_scope.inner_scopes.len()); | ||||
|             let value = DebugScopeValue(arr); | ||||
| 
 | ||||
|             outer_scope.inner_scopes.push(DebugScopeHolder { | ||||
|  | ||||
| @ -279,7 +279,6 @@ impl mir::Module { | ||||
|                                 binop.return_type.get_type(&type_values), | ||||
|                                 vec![binop.lhs.1.get_type(&type_values), binop.rhs.1.get_type(&type_values)], | ||||
|                                 FunctionFlags { | ||||
|                                     inline: true, | ||||
|                                     is_pub: binop.exported, | ||||
|                                     is_imported: binop.exported, | ||||
|                                     ..Default::default() | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user