mirror of
https://github.com/roc-lang/roc.git
synced 2025-10-01 07:41:12 +00:00
parent
3540a048d8
commit
7520dfee06
3 changed files with 14 additions and 12 deletions
|
@ -1,4 +1,4 @@
|
|||
use crate::borrow::{ParamMap, BORROWED};
|
||||
use crate::borrow::{ParamMap, BORROWED, OWNED};
|
||||
use crate::ir::{Expr, JoinPointId, ModifyRc, Param, Proc, Stmt};
|
||||
use crate::layout::Layout;
|
||||
use bumpalo::collections::Vec;
|
||||
|
@ -471,11 +471,10 @@ impl<'a> Context<'a> {
|
|||
let mut b = Stmt::Let(z, v, l, b);
|
||||
|
||||
if !ps[1].borrow {
|
||||
// b = Stmt::Refcounting(
|
||||
// ModifyRc::Inc(arguments[2], 2),
|
||||
// self.arena.alloc(b),
|
||||
// )
|
||||
todo!();
|
||||
b = Stmt::Refcounting(
|
||||
ModifyRc::Inc(arguments[2], 2),
|
||||
self.arena.alloc(b),
|
||||
)
|
||||
}
|
||||
|
||||
&*self.arena.alloc(b)
|
||||
|
@ -800,7 +799,10 @@ impl<'a> Context<'a> {
|
|||
|
||||
use crate::ir::CallType;
|
||||
let stmt = match &call.call_type {
|
||||
CallType::LowLevel { op, .. } => {
|
||||
CallType::LowLevel {
|
||||
op,
|
||||
opt_closure_layout: _,
|
||||
} => {
|
||||
let ps = crate::borrow::lowlevel_borrow_signature(self.arena, *op);
|
||||
self.add_dec_after_lowlevel(call.arguments, ps, cont, &invoke_live_vars)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue