mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-29 06:44:46 +00:00
Add FunctionPointer layout
This commit is contained in:
parent
a9e3f967a8
commit
6312d75ee0
18 changed files with 111 additions and 14 deletions
|
@ -8,7 +8,7 @@ use inkwell::values::{BasicValueEnum, FunctionValue, IntValue, PointerValue, Str
|
|||
use inkwell::{AddressSpace, FloatPredicate, IntPredicate};
|
||||
use roc_builtins::bitcode;
|
||||
use roc_builtins::bitcode::{FloatWidth, IntWidth};
|
||||
use roc_error_macros::internal_error;
|
||||
use roc_error_macros::{internal_error, todo_lambda_erasure};
|
||||
use roc_module::symbol::Symbol;
|
||||
use roc_mono::layout::{
|
||||
Builtin, InLayout, LayoutIds, LayoutInterner, LayoutRepr, STLayoutInterner, UnionLayout,
|
||||
|
@ -225,6 +225,8 @@ fn build_eq<'a, 'ctx>(
|
|||
field2_cast.into(),
|
||||
)
|
||||
}
|
||||
|
||||
LayoutRepr::FunctionPointer(_) => todo_lambda_erasure!(),
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -399,6 +401,8 @@ fn build_neq<'a, 'ctx>(
|
|||
unreachable!("recursion pointers should never be compared directly")
|
||||
}
|
||||
LayoutRepr::LambdaSet(_) => unreachable!("cannot compare closure"),
|
||||
|
||||
LayoutRepr::FunctionPointer(_) => todo_lambda_erasure!(),
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue