summaryrefslogtreecommitdiff
path: root/foreign.c
diff options
context:
space:
mode:
Diffstat (limited to 'foreign.c')
-rw-r--r--foreign.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/foreign.c b/foreign.c
new file mode 100644
index 0000000..7d441be
--- /dev/null
+++ b/foreign.c
@@ -0,0 +1,13 @@
+#if COMPILE_TIME_FOREIGN_FN_SUPPORT
+static bool foreign_call(FnExpr *fn, Type *fn_type, Value *args, Location call_where) {
+ assert(fn->flags & FN_EXPR_FOREIGN);
+ /* TODO */
+ return true;
+}
+#else
+static bool foreign_call(FnExpr *fn, Type *fn_type, Value *args, Location call_where) {
+ (void)fn; (void)fn_type; (void)args;
+ err_print(call_where, "You have not compiled toc with compile time foreign function support.");
+ return false;
+}
+#endif