mirror of
https://gitlab.com/camelot/kickc.git
synced 2025-04-14 10:37:36 +00:00
Fixed > & < for pointers.
This commit is contained in:
parent
b3537e3b66
commit
028fd75878
@ -88,7 +88,7 @@ public class AsmFormat {
|
||||
SymbolType operandType = SymbolTypeInference.inferType(program.getScope(), operand);
|
||||
if(SymbolType.isByte(operandType) || SymbolType.isSByte(operandType)) {
|
||||
return getAsmConstant(program, operand, outerPrecedence, codeScope);
|
||||
} else if(SymbolType.isWord(operandType) || SymbolType.isSWord(operandType)) {
|
||||
} else if(SymbolType.isWord(operandType) || SymbolType.isSWord(operandType) || operandType instanceof SymbolTypePointer) {
|
||||
return "<" + getAsmConstant(program, operand, outerPrecedence, codeScope);
|
||||
} else if(SymbolType.isDWord(operandType) || SymbolType.isSDWord(operandType)) {
|
||||
return getAsmConstant(program, operand, outerPrecedence, codeScope) + "&$ffff";
|
||||
@ -99,7 +99,7 @@ public class AsmFormat {
|
||||
SymbolType operandType = SymbolTypeInference.inferType(program.getScope(), operand);
|
||||
if(SymbolType.isByte(operandType) || SymbolType.isSByte(operandType)) {
|
||||
return getAsmConstant(program, operand, outerPrecedence, codeScope);
|
||||
} else if(SymbolType.isWord(operandType) || SymbolType.isSWord(operandType)) {
|
||||
} else if(SymbolType.isWord(operandType) || SymbolType.isSWord(operandType) || operandType instanceof SymbolTypePointer) {
|
||||
return ">" + getAsmConstant(program, operand, outerPrecedence, codeScope);
|
||||
} else if(SymbolType.isDWord(operandType) || SymbolType.isSDWord(operandType)) {
|
||||
return getAsmConstant(program, operand, outerPrecedence, codeScope) + ">>16";
|
||||
|
Loading…
x
Reference in New Issue
Block a user