Avoid some duplication between SimpleCx and CodegenCx
This commit is contained in:
parent
d4379d2afd
commit
bfd88cead0
4 changed files with 96 additions and 90 deletions
|
@ -286,7 +286,7 @@ pub(crate) fn differentiate<'ll>(
|
|||
}
|
||||
|
||||
let diag_handler = cgcx.create_dcx();
|
||||
let cx = SimpleCx { llmod: module.module_llvm.llmod(), llcx: module.module_llvm.llcx };
|
||||
let cx = SimpleCx::new(module.module_llvm.llmod(), module.module_llvm.llcx);
|
||||
|
||||
// First of all, did the user try to use autodiff without using the -Zautodiff=Enable flag?
|
||||
if !diff_items.is_empty()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue