diff options
Diffstat (limited to 'src/Builtins.kt')
-rw-r--r-- | src/Builtins.kt | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/src/Builtins.kt b/src/Builtins.kt index 6ca60e9..f9bf329 100644 --- a/src/Builtins.kt +++ b/src/Builtins.kt @@ -3,17 +3,4 @@ package moe.nea.lisp object Builtins { val builtinSource = Builtins::class.java.getResourceAsStream("/builtins.lisp")!!.bufferedReader().readText() val builtinProgram = LispParser.parse("builtins.lisp", builtinSource) - fun loadBuiltins( - lispExecutionContext: LispExecutionContext, - consumer: (String, LispData) -> Unit, - ) { - val stackFrame = lispExecutionContext.genBindings() - stackFrame.setValueLocal("export", LispData.externalRawCall { context, callsite, stackFrame, args -> - args.forEach { name -> - consumer((name as LispAst.Reference).label, context.resolveValue(stackFrame, name)) - } - return@externalRawCall LispData.LispNil - }) - lispExecutionContext.executeProgram(stackFrame, builtinProgram) - } }
\ No newline at end of file |