mirror of
https://github.com/roc-lang/roc.git
synced 2025-12-15 21:23:57 +00:00
Parameterize program solving on a FunctionKind
This new flag determines whether we should introduce a new kind to represent lambda sets, or whether lambdas should be erased. The latter is not yet implemented.
This commit is contained in:
parent
60c98ea5d5
commit
44c4797d9a
29 changed files with 126 additions and 13 deletions
|
|
@ -10,7 +10,7 @@ use roc_build::{
|
|||
},
|
||||
};
|
||||
use roc_collections::MutMap;
|
||||
use roc_load::{ExecutionMode, LoadConfig, LoadedModule, LoadingProblem, Threading};
|
||||
use roc_load::{ExecutionMode, FunctionKind, LoadConfig, LoadedModule, LoadingProblem, Threading};
|
||||
use roc_mono::ir::{generate_glue_procs, GlueProc, OptLevel};
|
||||
use roc_mono::layout::{GlobalLayoutInterner, LayoutCache, LayoutInterner};
|
||||
use roc_packaging::cache::{self, RocCacheDir};
|
||||
|
|
@ -334,6 +334,8 @@ pub fn load_types(
|
|||
ignore_errors: IgnoreErrors,
|
||||
) -> Result<Vec<Types>, io::Error> {
|
||||
let target_info = (&Triple::host()).into();
|
||||
// TODO the function kind may need to be parameterizable.
|
||||
let function_kind = FunctionKind::LambdaSet;
|
||||
let arena = &Bump::new();
|
||||
let LoadedModule {
|
||||
module_id: home,
|
||||
|
|
@ -350,6 +352,7 @@ pub fn load_types(
|
|||
RocCacheDir::Persistent(cache::roc_cache_dir().as_path()),
|
||||
LoadConfig {
|
||||
target_info,
|
||||
function_kind,
|
||||
render: RenderTarget::Generic,
|
||||
palette: DEFAULT_PALETTE,
|
||||
threading,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue