Cache compiled Lua scripts in memory.

This commit is contained in:
hugo committed 2026-08-07 15:50:26 +02:00
1 parent 41d5f1c014
commit 87a161058f
3 files changed
+224 -8

No files matched your search

+6
View File
@@ -89,6 +89,12 @@ surface ScriptRuntimeSurface {
-- unrestricted host capabilities are unavailable unless explicitly
-- re-exposed by the host application.
@guarantee CompiledChunkCache
-- Validation and execution share a bounded, process-local cache of Lua
-- bytecode keyed by exact source. Cache hits still execute in a fresh
-- sandbox with the current host capabilities, limits, hooks, and globals.
-- Failed compilation is not cached; bytecode is never persisted.
@guarantee ExplicitHostCapabilities
-- Host-provided functions are exposed only through an explicit bds.*
-- capability table, never through ambient global access.