mirror of
https://github.com/krgamestudios/Toy.git
synced 2026-04-15 14:54:07 +10:00
Cleaned up some comments
This commit is contained in:
@@ -92,7 +92,6 @@ static void emitString(Toy_Routine** rt, Toy_String* str) {
|
||||
static void writeRoutineCode(Toy_Routine** rt, Toy_Ast* ast); //forward declare for recursion
|
||||
|
||||
static void writeInstructionValue(Toy_Routine** rt, Toy_AstValue ast) {
|
||||
//TODO: store more complex values in the data code
|
||||
EMIT_BYTE(rt, code, TOY_OPCODE_READ);
|
||||
EMIT_BYTE(rt, code, ast.value.type);
|
||||
|
||||
@@ -369,7 +368,9 @@ static void* writeRoutine(Toy_Routine* rt, Toy_Ast* ast) {
|
||||
emitInt((void**)&buffer, &capacity, &count, 0); //subs
|
||||
}
|
||||
|
||||
//append various parts to the buffer TODO: add the rest
|
||||
//append various parts to the buffer
|
||||
//TODO: param region
|
||||
|
||||
if (rt->codeCount > 0) {
|
||||
expand(&buffer, &capacity, &count, rt->codeCount);
|
||||
memcpy((buffer + count), rt->code, rt->codeCount);
|
||||
@@ -394,6 +395,8 @@ static void* writeRoutine(Toy_Routine* rt, Toy_Ast* ast) {
|
||||
count += rt->dataCount;
|
||||
}
|
||||
|
||||
//TODO: subs region
|
||||
|
||||
//finally, record the total size within the header, and return the result
|
||||
*((int*)buffer) = count;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user