mirror of
https://github.com/krgamestudios/Toy.git
synced 2026-04-15 06:44:07 +10:00
10 lines
297 B
C
10 lines
297 B
C
#include "toy_function.h"
|
|
|
|
Toy_Function* Toy_createFunctionFromBytecode(Toy_Bucket** bucketHandle, unsigned char* bytecode) {
|
|
Toy_Function* fn = (Toy_Function*)Toy_partitionBucket(bucketHandle, sizeof(Toy_Function));
|
|
|
|
fn->type = TOY_FUNCTION_CUSTOM;
|
|
fn->bytecode.code = bytecode;
|
|
|
|
return fn;
|
|
} |