mark the builtin files as such so builtin function implementations are inserted

This commit is contained in:
Folkert 2022-04-13 21:40:08 +02:00
parent 7c583b5e79
commit 493a96d85b
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
3 changed files with 21 additions and 11 deletions

View file

@ -3128,6 +3128,18 @@ fn send_header<'a>(
}
}
// make sure when we run the bulitin modules in /compiler/builtins/roc that we
// mark these modules as Builtin. Otherwise the builtin functions are not instantiated
// and we just have a bunch of definitions with runtime errors in their bodies
let extra = {
match extra {
HeaderFor::Interface if home.is_builtin() => HeaderFor::Builtin {
generates_with: &[],
},
_ => extra,
}
};
(
home,
Msg::Header(ModuleHeader {