paramter ownership is not important for codegen

This commit is contained in:
Folkert 2023-02-12 02:06:20 +01:00
parent 78000b3f19
commit 4b31c77b37
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C

View file

@ -9,7 +9,6 @@ use roc_collections::all::{MutMap, MutSet};
use roc_error_macros::internal_error;
use roc_module::symbol::Symbol;
use roc_mono::{
borrow::Ownership,
ir::{JoinPointId, Param},
layout::{
Builtin, InLayout, Layout, LayoutInterner, STLayoutInterner, TagIdIntType, UnionLayout,
@ -1083,15 +1082,10 @@ impl<
param_storage.reserve(params.len());
for Param {
symbol,
ownership,
ownership: _,
layout,
} in params
{
if *ownership == Ownership::Borrowed {
// These probably need to be passed by pointer/reference?
// Otherwise, we probably need to copy back to the param at the end of the joinpoint.
todo!("joinpoints with borrowed parameters");
}
// Claim a location for every join point parameter to be loaded at.
// Put everything on the stack for simplicity.
match *layout {