Fixed a bug to correct the location of symbols in the heap.
This commit is contained in:
+2
-2
@@ -106,13 +106,13 @@ void HandleAssemblerDirective(void) {
|
||||
exit(1);
|
||||
}
|
||||
|
||||
AddSymbol(identifier, ProgramCounter);
|
||||
AddSymbol(identifier, HeapTop);
|
||||
|
||||
identifier = PeekToken();
|
||||
|
||||
switch(identifier->type) {
|
||||
case STRING:
|
||||
printf("[INFO] %s = '%s' (%#04X)\n", identifier->lexeme, identifier->lexeme, ProgramCounter);
|
||||
printf("[INFO] %s = '%s' (%#04X)\n", identifier->lexeme, identifier->lexeme, HeapTop);
|
||||
|
||||
for(int i = 0; i < strlen(identifier->lexeme); i++) {
|
||||
//Memory[ProgramCounter + i] = PeekToken()->lexeme[i];
|
||||
|
||||
Reference in New Issue
Block a user