Add an API to load a top-level variable into a slot.

This commit is contained in:
Bob Nystrom
2015-12-26 10:53:14 -08:00
parent 15043b897f
commit 1d16e85a85
8 changed files with 112 additions and 1 deletions
+5
View File
@@ -384,4 +384,9 @@ void wrenSetSlotValue(WrenVM* vm, int slot, WrenValue* value);
// an element, use `-1` for the index.
void wrenInsertInList(WrenVM* vm, int listSlot, int index, int elementSlot);
// Looks up the top level variable with [name] in [module] and stores it in
// [slot].
void wrenGetVariable(WrenVM* vm, const char* module, const char* name,
int slot);
#endif