mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-28 14:24:45 +00:00
Formatting & comments
This commit is contained in:
parent
ebc1fd6880
commit
38e3386b80
2 changed files with 6 additions and 2 deletions
|
@ -107,13 +107,17 @@ pub fn build_module_help<'a>(
|
|||
// The RefcountProcGenerator has now built up a vector of extra procs to generate.
|
||||
// But we need to move that vector to be able to safely loop over it.
|
||||
let mut procs_to_generate = Vec::with_capacity_in(0, env.arena);
|
||||
std::mem::swap(&mut backend.refcount_proc_gen.procs_to_generate, &mut procs_to_generate);
|
||||
std::mem::swap(
|
||||
&mut backend.refcount_proc_gen.procs_to_generate,
|
||||
&mut procs_to_generate,
|
||||
);
|
||||
|
||||
// Generate the refcount helper procedures
|
||||
for (layout, op, symbol) in procs_to_generate.drain(0..) {
|
||||
let proc = backend
|
||||
.refcount_proc_gen
|
||||
.generate_refcount_proc(layout, op, symbol);
|
||||
|
||||
backend.build_proc(proc, symbol)?;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue