mirror of
https://gitlab.com/camelot/kickc.git
synced 2025-04-06 15:41:05 +00:00
Added encoding information to literal chars. Working on 2/3 of #245
This commit is contained in:
parent
7f3cfd50af
commit
9e56b49a7e
@ -9,10 +9,15 @@ import dk.camelot64.kickc.model.types.SymbolType;
|
||||
*/
|
||||
public class ConstantChar implements ConstantLiteral<Character> {
|
||||
|
||||
/** The character. */
|
||||
private Character value;
|
||||
|
||||
public ConstantChar(Character value) {
|
||||
/** The encoding of the character. */
|
||||
private ConstantString.Encoding encoding;
|
||||
|
||||
public ConstantChar(Character value, ConstantString.Encoding encoding) {
|
||||
this.value = value;
|
||||
this.encoding = encoding;
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -36,10 +41,11 @@ public class ConstantChar implements ConstantLiteral<Character> {
|
||||
|
||||
@Override
|
||||
public String toString(Program program) {
|
||||
String enc = (encoding.equals(ConstantString.Encoding.SCREENCODE_MIXED))?"":encoding.suffix;
|
||||
if(program == null) {
|
||||
return "'" + value + "'";
|
||||
return "'" + value + "'"+enc;
|
||||
} else {
|
||||
return "(" + SymbolType.BYTE.getTypeName() + ") " + "'" + value + "'";
|
||||
return "(" + SymbolType.BYTE.getTypeName() + ") " + "'" + value + "'"+enc;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -13,17 +13,20 @@ public class ConstantString implements ConstantLiteral<String> {
|
||||
|
||||
/** String encoding. */
|
||||
public static enum Encoding {
|
||||
PETSCII_MIXED("petscii_mixed"),
|
||||
PETSCII_UPPER("petscii_upper"),
|
||||
SCREENCODE_MIXED("screencode_mixed"),
|
||||
SCREENCODE_UPPER("screencode_upper")
|
||||
PETSCII_MIXED("petscii_mixed", "pm"),
|
||||
PETSCII_UPPER("petscii_upper", "pu"),
|
||||
SCREENCODE_MIXED("screencode_mixed", "sm"),
|
||||
SCREENCODE_UPPER("screencode_upper", "su")
|
||||
;
|
||||
|
||||
public final String name;
|
||||
public final String suffix;
|
||||
|
||||
Encoding(String name) {
|
||||
Encoding(String name, String suffix) {
|
||||
this.name = name;
|
||||
this.suffix = suffix;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private String value;
|
||||
@ -60,11 +63,11 @@ public class ConstantString implements ConstantLiteral<String> {
|
||||
|
||||
@Override
|
||||
public String toString(Program program) {
|
||||
String enc = (encoding.equals(Encoding.SCREENCODE_MIXED))?"":encoding.toString();
|
||||
String enc = (encoding.equals(Encoding.SCREENCODE_MIXED))?"":encoding.suffix;
|
||||
if(program == null) {
|
||||
return enc + "\"" + value + "\"";
|
||||
return "\"" + value + "\""+enc;
|
||||
} else {
|
||||
return "(" + SymbolType.STRING.getTypeName() + ") "+enc + "\"" + value + "\"";
|
||||
return "(" + SymbolType.STRING.getTypeName() + ") "+"\"" + value + "\""+enc;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -136,7 +136,7 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
if(programPc != null) {
|
||||
program.setProgramPc(programPc);
|
||||
} else {
|
||||
throw new CompileError("Cannot parse #pc directive",new StatementSource(ctx));
|
||||
throw new CompileError("Cannot parse #pc directive", new StatementSource(ctx));
|
||||
}
|
||||
return null;
|
||||
}
|
||||
@ -147,7 +147,7 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
if(platform != null) {
|
||||
program.setTargetPlatform(platform);
|
||||
} else {
|
||||
throw new CompileError("Unknown target platform in #platform directive",new StatementSource(ctx));
|
||||
throw new CompileError("Unknown target platform in #platform directive", new StatementSource(ctx));
|
||||
}
|
||||
return null;
|
||||
}
|
||||
@ -546,24 +546,24 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
}
|
||||
// Add KickAsm statement
|
||||
StatementKickAsm kasm = (StatementKickAsm) this.visit(ctx.declKasm());
|
||||
if(kasm.getUses().size()>0) {
|
||||
if(kasm.getUses().size() > 0) {
|
||||
throw new CompileError("KickAsm initializers does not support 'uses' directive.", new StatementSource(ctx));
|
||||
}
|
||||
if(kasm.getLocation()!=null) {
|
||||
if(kasm.getLocation() != null) {
|
||||
throw new CompileError("KickAsm initializers does not support 'location' directive.", new StatementSource(ctx));
|
||||
}
|
||||
if(kasm.getCycles()!=null) {
|
||||
if(kasm.getCycles() != null) {
|
||||
throw new CompileError("KickAsm initializers does not support 'cycles' directive.", new StatementSource(ctx));
|
||||
}
|
||||
if(kasm.getBytes()!=null) {
|
||||
if(kasm.getBytes() != null) {
|
||||
throw new CompileError("KickAsm initializers does not support 'bytes' directive.", new StatementSource(ctx));
|
||||
}
|
||||
if(kasm.getDeclaredClobber()!=null) {
|
||||
if(kasm.getDeclaredClobber() != null) {
|
||||
throw new CompileError("KickAsm initializers does not support 'clobbers' directive.", new StatementSource(ctx));
|
||||
}
|
||||
ConstantArrayKickAsm constantArrayKickAsm = new ConstantArrayKickAsm(((SymbolTypeArray) type).getElementType(), kasm.getKickAsmCode());
|
||||
// Remove the KickAsm statement
|
||||
sequence.getStatements().remove(sequence.getStatements().size()-1);
|
||||
sequence.getStatements().remove(sequence.getStatements().size() - 1);
|
||||
// Add an initializer statement instead
|
||||
Statement stmt = new StatementAssignment(lValue.getRef(), constantArrayKickAsm, new StatementSource(ctx), ensureUnusedComments(comments));
|
||||
sequence.addStatement(stmt);
|
||||
@ -596,6 +596,7 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
|
||||
/**
|
||||
* Create a statement that initializes a variable with the default (zero) value. The statement has to be added to the program by the caller.
|
||||
*
|
||||
* @param varRef The variable to initialize
|
||||
* @param type The type of the variable
|
||||
* @param statementSource The source line
|
||||
@ -1269,8 +1270,8 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
public Object visitStructRef(KickCParser.StructRefContext ctx) {
|
||||
String structDefName = ctx.NAME().getText();
|
||||
StructDefinition structDefinition = getCurrentScope().getStructDefinition(structDefName);
|
||||
if(structDefinition==null) {
|
||||
throw new CompileError("Unknown struct type "+structDefName, new StatementSource(ctx));
|
||||
if(structDefinition == null) {
|
||||
throw new CompileError("Unknown struct type " + structDefName, new StatementSource(ctx));
|
||||
}
|
||||
return structDefinition.getType();
|
||||
}
|
||||
@ -1305,7 +1306,7 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
parentScope.add(new ConstantVar(member.getLocalName(), parentScope, SymbolType.BYTE, member.getValue()));
|
||||
}
|
||||
return SymbolType.BYTE;
|
||||
} catch (CompileError e) {
|
||||
} catch(CompileError e) {
|
||||
throw new CompileError(e.getMessage(), new StatementSource(ctx));
|
||||
}
|
||||
}
|
||||
@ -1314,10 +1315,10 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
public Object visitEnumMember(KickCParser.EnumMemberContext ctx) {
|
||||
String memberName = ctx.NAME().getText();
|
||||
ConstantValue enumValue;
|
||||
if(ctx.expr()!=null) {
|
||||
if(ctx.expr() != null) {
|
||||
RValue exprVal = (RValue) visit(ctx.expr());
|
||||
if(!(exprVal instanceof ConstantValue)) {
|
||||
throw new CompileError("Enum value not constant "+memberName, new StatementSource(ctx));
|
||||
throw new CompileError("Enum value not constant " + memberName, new StatementSource(ctx));
|
||||
}
|
||||
enumValue = (ConstantValue) exprVal;
|
||||
} else {
|
||||
@ -1326,11 +1327,11 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
if(values.isEmpty()) {
|
||||
enumValue = new ConstantInteger(0L, SymbolType.BYTE);
|
||||
} else {
|
||||
ConstantVar prevEnumMember= values.get(values.size() - 1);
|
||||
ConstantVar prevEnumMember = values.get(values.size() - 1);
|
||||
ConstantValue prevValue = prevEnumMember.getValue();
|
||||
if(prevValue instanceof ConstantInteger) {
|
||||
enumValue = new ConstantInteger(((ConstantInteger) prevValue).getInteger()+1, SymbolType.BYTE);
|
||||
} else {
|
||||
enumValue = new ConstantInteger(((ConstantInteger) prevValue).getInteger() + 1, SymbolType.BYTE);
|
||||
} else {
|
||||
enumValue = new ConstantBinary(prevValue, Operators.PLUS, new ConstantInteger(1L, SymbolType.BYTE));
|
||||
|
||||
}
|
||||
@ -1349,8 +1350,8 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
public Object visitEnumRef(KickCParser.EnumRefContext ctx) {
|
||||
String enumDefName = ctx.NAME().getText();
|
||||
EnumDefinition enumDefinition = getCurrentScope().getEnumDefinition(enumDefName);
|
||||
if(enumDefinition==null) {
|
||||
throw new CompileError("Unknown enum "+enumDefName, new StatementSource(ctx));
|
||||
if(enumDefinition == null) {
|
||||
throw new CompileError("Unknown enum " + enumDefName, new StatementSource(ctx));
|
||||
}
|
||||
return SymbolType.BYTE;
|
||||
}
|
||||
@ -1359,10 +1360,10 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
public Object visitTypeNamedRef(KickCParser.TypeNamedRefContext ctx) {
|
||||
Scope typeDefScope = program.getScope().getTypeDefScope();
|
||||
Variable typeDefVariable = typeDefScope.getVariable(ctx.getText());
|
||||
if(typeDefVariable!=null) {
|
||||
if(typeDefVariable != null) {
|
||||
return typeDefVariable.getType();
|
||||
}
|
||||
throw new CompileError("Unknown type "+ctx.getText(), new StatementSource(ctx));
|
||||
throw new CompileError("Unknown type " + ctx.getText(), new StatementSource(ctx));
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -1377,8 +1378,8 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
}
|
||||
String fullName = signedness + " " + simpleTypeName;
|
||||
SymbolType symbolType = SymbolType.get(fullName);
|
||||
if(symbolType==null) {
|
||||
throw new CompileError("Unknown type "+fullName, new StatementSource(ctx));
|
||||
if(symbolType == null) {
|
||||
throw new CompileError("Unknown type " + fullName, new StatementSource(ctx));
|
||||
}
|
||||
return symbolType;
|
||||
}
|
||||
@ -1595,43 +1596,45 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
for(TerminalNode stringNode : ctx.STRING()) {
|
||||
subText = stringNode.getText();
|
||||
String suffix = subText.substring(subText.lastIndexOf('"') + 1);
|
||||
|
||||
if(suffix.contains("pm")) {
|
||||
if(encoding != null && !encoding.equals(ConstantString.Encoding.PETSCII_MIXED))
|
||||
ConstantString.Encoding suffixEncoding = getEncodingFromSuffix(suffix);
|
||||
if(suffixEncoding!=null) {
|
||||
if(encoding != null && !encoding.equals(suffixEncoding)) {
|
||||
throw new CompileError("Cannot mix encodings in concatenated strings " + ctx.getText(), new StatementSource(ctx));
|
||||
encoding = ConstantString.Encoding.PETSCII_MIXED;
|
||||
} else if(suffix.contains("pu")) {
|
||||
if(encoding != null && !encoding.equals(ConstantString.Encoding.PETSCII_UPPER))
|
||||
throw new CompileError("Cannot mix encodings in concatenated strings " + ctx.getText(), new StatementSource(ctx));
|
||||
encoding = ConstantString.Encoding.PETSCII_UPPER;
|
||||
} else if(suffix.contains("p")) {
|
||||
if(encoding != null && !encoding.equals(ConstantString.Encoding.PETSCII_MIXED))
|
||||
throw new CompileError("Cannot mix encodings in concatenated strings " + ctx.getText(), new StatementSource(ctx));
|
||||
encoding = ConstantString.Encoding.PETSCII_MIXED;
|
||||
} else if(suffix.contains("sm")) {
|
||||
if(encoding != null && !encoding.equals(ConstantString.Encoding.SCREENCODE_MIXED))
|
||||
throw new CompileError("Cannot mix encodings in concatenated strings " + ctx.getText(), new StatementSource(ctx));
|
||||
encoding = ConstantString.Encoding.SCREENCODE_MIXED;
|
||||
} else if(suffix.contains("su")) {
|
||||
if(encoding != null && !encoding.equals(ConstantString.Encoding.SCREENCODE_UPPER))
|
||||
throw new CompileError("Cannot mix encodings in concatenated strings " + ctx.getText(), new StatementSource(ctx));
|
||||
encoding = ConstantString.Encoding.SCREENCODE_UPPER;
|
||||
} else if(suffix.contains("s")) {
|
||||
if(encoding != null && !encoding.equals(ConstantString.Encoding.SCREENCODE_MIXED))
|
||||
throw new CompileError("Cannot mix encodings in concatenated strings " + ctx.getText(), new StatementSource(ctx));
|
||||
encoding = ConstantString.Encoding.SCREENCODE_MIXED;
|
||||
}
|
||||
encoding = suffixEncoding;
|
||||
}
|
||||
|
||||
lastSuffix = suffix;
|
||||
stringValue += subText.substring(1, subText.lastIndexOf('"'));
|
||||
}
|
||||
if(!lastSuffix.contains("z")) {
|
||||
stringValue += "@";
|
||||
}
|
||||
if(encoding == null) encoding = currentEncoding;
|
||||
return new ConstantString(stringValue, encoding);
|
||||
}
|
||||
|
||||
/**
|
||||
* Examine a string suffix, and find any encoding information inside it.
|
||||
* @param suffix The string suffix
|
||||
* @return The encoding specified by the suffix. If not the current source encoding is returned.
|
||||
*/
|
||||
private ConstantString.Encoding getEncodingFromSuffix(String suffix) {
|
||||
if(suffix.contains("pm")) {
|
||||
return ConstantString.Encoding.PETSCII_MIXED;
|
||||
} else if(suffix.contains("pu")) {
|
||||
return ConstantString.Encoding.PETSCII_UPPER;
|
||||
} else if(suffix.contains("p")) {
|
||||
return ConstantString.Encoding.PETSCII_MIXED;
|
||||
} else if(suffix.contains("sm")) {
|
||||
return ConstantString.Encoding.SCREENCODE_MIXED;
|
||||
} else if(suffix.contains("su")) {
|
||||
return ConstantString.Encoding.SCREENCODE_UPPER;
|
||||
} else if(suffix.contains("s")) {
|
||||
return ConstantString.Encoding.SCREENCODE_MIXED;
|
||||
} else {
|
||||
return currentEncoding;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public RValue visitExprBool(KickCParser.ExprBoolContext ctx) {
|
||||
String bool = ctx.getText();
|
||||
@ -1640,7 +1643,7 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
|
||||
@Override
|
||||
public Object visitExprChar(KickCParser.ExprCharContext ctx) {
|
||||
return new ConstantChar(ctx.getText().charAt(1));
|
||||
return new ConstantChar(ctx.getText().charAt(1), currentEncoding);
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -1651,7 +1654,7 @@ public class Pass0GenerateStatementSequence extends KickCBaseVisitor<Object> {
|
||||
Operator operator = Operators.getBinary(op);
|
||||
if(left instanceof ConstantValue && right instanceof ConstantValue) {
|
||||
return new ConstantBinary((ConstantValue) left, (OperatorBinary) operator, (ConstantValue) right);
|
||||
} else {
|
||||
} else {
|
||||
VariableIntermediate tmpVar = getCurrentScope().addVariableIntermediate();
|
||||
VariableRef tmpVarRef = tmpVar.getRef();
|
||||
Statement stmt = new StatementAssignment(tmpVarRef, left, operator, right, new StatementSource(ctx), ensureUnusedComments(getCommentsSymbol(ctx)));
|
||||
|
@ -8,7 +8,7 @@
|
||||
@end: scope:[] from @1
|
||||
[3] phi()
|
||||
main: scope:[main] from @1
|
||||
[4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e'
|
||||
[4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e'pm
|
||||
[5] *((const byte[]) strTemp#0+(byte) 3) ← (byte) 0
|
||||
asm { ldy#0 loop: ldastrTemp,y beqdone jsr$FFD2 iny jmploop done: }
|
||||
to:main::@return
|
||||
|
@ -5,7 +5,7 @@ CONTROL FLOW GRAPH SSA
|
||||
(byte[]) strTemp#0 ← (const string) $0
|
||||
to:@1
|
||||
main: scope:[main] from @1
|
||||
*((byte[]) strTemp#0 + (number) 2) ← (byte) 'e'
|
||||
*((byte[]) strTemp#0 + (number) 2) ← (byte) 'e'pm
|
||||
*((byte[]) strTemp#0 + (number) 3) ← (number) 0
|
||||
asm { ldy#0 loop: ldastrTemp,y beqdone jsr$FFD2 iny jmploop done: }
|
||||
(signed word) main::return#0 ← (number) 0
|
||||
@ -24,7 +24,7 @@ main::@return: scope:[main] from main
|
||||
@end: scope:[] from @2
|
||||
|
||||
SYMBOL TABLE SSA
|
||||
(const string) $0 = (string) PETSCII_MIXED"v=X@"
|
||||
(const string) $0 = (string) "v=X@"pm
|
||||
(label) @1
|
||||
(label) @2
|
||||
(label) @begin
|
||||
@ -39,7 +39,7 @@ SYMBOL TABLE SSA
|
||||
(byte[]) strTemp
|
||||
(byte[]) strTemp#0
|
||||
|
||||
Adding number conversion cast (unumber) 2 in *((byte[]) strTemp#0 + (number) 2) ← (byte) 'e'
|
||||
Adding number conversion cast (unumber) 2 in *((byte[]) strTemp#0 + (number) 2) ← (byte) 'e'pm
|
||||
Adding number conversion cast (unumber) 0 in *((byte[]) strTemp#0 + (number) 3) ← (number) 0
|
||||
Adding number conversion cast (unumber) 3 in *((byte[]) strTemp#0 + (number) 3) ← ((unumber)) (number) 0
|
||||
Adding number conversion cast (snumber) 0 in (signed word) main::return#0 ← (number) 0
|
||||
@ -98,7 +98,7 @@ FINAL CONTROL FLOW GRAPH
|
||||
@end: scope:[] from @1
|
||||
[3] phi()
|
||||
main: scope:[main] from @1
|
||||
[4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e'
|
||||
[4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e'pm
|
||||
[5] *((const byte[]) strTemp#0+(byte) 3) ← (byte) 0
|
||||
asm { ldy#0 loop: ldastrTemp,y beqdone jsr$FFD2 iny jmploop done: }
|
||||
to:main::@return
|
||||
@ -139,7 +139,7 @@ bend_from_b1:
|
||||
bend:
|
||||
// main
|
||||
main: {
|
||||
// [4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e' -- _deref_pbuc1=vbuc2
|
||||
// [4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e'pm -- _deref_pbuc1=vbuc2
|
||||
lda #'e'
|
||||
sta strTemp+2
|
||||
// [5] *((const byte[]) strTemp#0+(byte) 3) ← (byte) 0 -- _deref_pbuc1=vbuc2
|
||||
@ -165,7 +165,7 @@ main: {
|
||||
strTemp: .text "v=X@"
|
||||
|
||||
REGISTER UPLIFT POTENTIAL REGISTERS
|
||||
Statement [4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e' [ ] ( main:2 [ ] ) always clobbers reg byte a
|
||||
Statement [4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e'pm [ ] ( main:2 [ ] ) always clobbers reg byte a
|
||||
Statement [5] *((const byte[]) strTemp#0+(byte) 3) ← (byte) 0 [ ] ( main:2 [ ] ) always clobbers reg byte a
|
||||
Statement asm { ldy#0 loop: ldastrTemp,y beqdone jsr$FFD2 iny jmploop done: } always clobbers reg byte a reg byte x reg byte y
|
||||
|
||||
@ -199,7 +199,7 @@ bend_from_b1:
|
||||
bend:
|
||||
// main
|
||||
main: {
|
||||
// [4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e' -- _deref_pbuc1=vbuc2
|
||||
// [4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e'pm -- _deref_pbuc1=vbuc2
|
||||
lda #'e'
|
||||
sta strTemp+2
|
||||
// [5] *((const byte[]) strTemp#0+(byte) 3) ← (byte) 0 -- _deref_pbuc1=vbuc2
|
||||
@ -251,7 +251,7 @@ FINAL SYMBOL TABLE
|
||||
(label) main::@return
|
||||
(signed word) main::return
|
||||
(byte[]) strTemp
|
||||
(const byte[]) strTemp#0 strTemp = (string) PETSCII_MIXED"v=X@"
|
||||
(const byte[]) strTemp#0 strTemp = (string) "v=X@"pm
|
||||
|
||||
|
||||
|
||||
@ -273,7 +273,7 @@ Score: 38
|
||||
// main
|
||||
main: {
|
||||
// strTemp[2] = 'e'
|
||||
// [4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e' -- _deref_pbuc1=vbuc2
|
||||
// [4] *((const byte[]) strTemp#0+(byte) 2) ← (byte) 'e'pm -- _deref_pbuc1=vbuc2
|
||||
lda #'e'
|
||||
sta strTemp+2
|
||||
// strTemp[3] = 0
|
||||
|
@ -5,5 +5,5 @@
|
||||
(label) main::@return
|
||||
(signed word) main::return
|
||||
(byte[]) strTemp
|
||||
(const byte[]) strTemp#0 strTemp = (string) PETSCII_MIXED"v=X@"
|
||||
(const byte[]) strTemp#0 strTemp = (string) "v=X@"pm
|
||||
|
||||
|
@ -46,11 +46,11 @@ main::@return: scope:[main] from main::@1
|
||||
@end: scope:[] from @2
|
||||
|
||||
SYMBOL TABLE SSA
|
||||
(const string) $0 = (string) PETSCII_MIXED"abcABC1@"
|
||||
(const string) $1 = (string) PETSCII_UPPER"abcABC2@"
|
||||
(const string) $2 = (string) PETSCII_MIXED"abcABC3@"
|
||||
(const string) $0 = (string) "abcABC1@"pm
|
||||
(const string) $1 = (string) "abcABC2@"pu
|
||||
(const string) $2 = (string) "abcABC3@"pm
|
||||
(const string) $3 = (string) "abcABC4@"
|
||||
(const string) $4 = (string) SCREENCODE_UPPER"abcABC5@"
|
||||
(const string) $4 = (string) "abcABC5@"su
|
||||
(const string) $5 = (string) "abcABC6@"
|
||||
(const string) $6 = (string) "abcABC7@"
|
||||
(label) @1
|
||||
@ -470,17 +470,17 @@ FINAL SYMBOL TABLE
|
||||
(byte) main::i#1 reg byte x 16.5
|
||||
(byte) main::i#2 reg byte x 22.0
|
||||
(byte[]) petscii_mixed
|
||||
(const byte[]) petscii_mixed#0 petscii_mixed = (string) PETSCII_MIXED"abcABC1@"
|
||||
(const byte[]) petscii_mixed#0 petscii_mixed = (string) "abcABC1@"pm
|
||||
(byte[]) petscii_standard
|
||||
(const byte[]) petscii_standard#0 petscii_standard = (string) PETSCII_MIXED"abcABC3@"
|
||||
(const byte[]) petscii_standard#0 petscii_standard = (string) "abcABC3@"pm
|
||||
(byte[]) petscii_upper
|
||||
(const byte[]) petscii_upper#0 petscii_upper = (string) PETSCII_UPPER"abcABC2@"
|
||||
(const byte[]) petscii_upper#0 petscii_upper = (string) "abcABC2@"pu
|
||||
(byte[]) screencode_mixed
|
||||
(const byte[]) screencode_mixed#0 screencode_mixed = (string) "abcABC4@"
|
||||
(byte[]) screencode_standard
|
||||
(const byte[]) screencode_standard#0 screencode_standard = (string) "abcABC6@"
|
||||
(byte[]) screencode_upper
|
||||
(const byte[]) screencode_upper#0 screencode_upper = (string) SCREENCODE_UPPER"abcABC5@"
|
||||
(const byte[]) screencode_upper#0 screencode_upper = (string) "abcABC5@"su
|
||||
(byte[]) standard
|
||||
(const byte[]) standard#0 standard = (string) "abcABC7@"
|
||||
|
||||
|
@ -10,17 +10,17 @@
|
||||
(byte) main::i#1 reg byte x 16.5
|
||||
(byte) main::i#2 reg byte x 22.0
|
||||
(byte[]) petscii_mixed
|
||||
(const byte[]) petscii_mixed#0 petscii_mixed = (string) PETSCII_MIXED"abcABC1@"
|
||||
(const byte[]) petscii_mixed#0 petscii_mixed = (string) "abcABC1@"pm
|
||||
(byte[]) petscii_standard
|
||||
(const byte[]) petscii_standard#0 petscii_standard = (string) PETSCII_MIXED"abcABC3@"
|
||||
(const byte[]) petscii_standard#0 petscii_standard = (string) "abcABC3@"pm
|
||||
(byte[]) petscii_upper
|
||||
(const byte[]) petscii_upper#0 petscii_upper = (string) PETSCII_UPPER"abcABC2@"
|
||||
(const byte[]) petscii_upper#0 petscii_upper = (string) "abcABC2@"pu
|
||||
(byte[]) screencode_mixed
|
||||
(const byte[]) screencode_mixed#0 screencode_mixed = (string) "abcABC4@"
|
||||
(byte[]) screencode_standard
|
||||
(const byte[]) screencode_standard#0 screencode_standard = (string) "abcABC6@"
|
||||
(byte[]) screencode_upper
|
||||
(const byte[]) screencode_upper#0 screencode_upper = (string) SCREENCODE_UPPER"abcABC5@"
|
||||
(const byte[]) screencode_upper#0 screencode_upper = (string) "abcABC5@"su
|
||||
(byte[]) standard
|
||||
(const byte[]) standard#0 standard = (string) "abcABC7@"
|
||||
|
||||
|
@ -44,10 +44,10 @@ main::@return: scope:[main] from main::@1
|
||||
|
||||
SYMBOL TABLE SSA
|
||||
(const string) $0 = (string) "abcABC1@"
|
||||
(const string) $1 = (string) PETSCII_MIXED"abcABC2@"
|
||||
(const string) $2 = (string) PETSCII_MIXED"abcABC3@"
|
||||
(const string) $1 = (string) "abcABC2@"pm
|
||||
(const string) $2 = (string) "abcABC3@"pm
|
||||
(const string) $3 = (string) "abcABC4@"
|
||||
(const string) $4 = (string) SCREENCODE_UPPER"abcABC5@"
|
||||
(const string) $4 = (string) "abcABC5@"su
|
||||
(const string) $5 = (string) "abcABC6@"
|
||||
(label) @1
|
||||
(label) @2
|
||||
@ -444,9 +444,9 @@ FINAL SYMBOL TABLE
|
||||
(byte) main::i#1 reg byte x 16.5
|
||||
(byte) main::i#2 reg byte x 22.000000000000004
|
||||
(byte[]) petscii_mixed1
|
||||
(const byte[]) petscii_mixed1#0 petscii_mixed1 = (string) PETSCII_MIXED"abcABC2@"
|
||||
(const byte[]) petscii_mixed1#0 petscii_mixed1 = (string) "abcABC2@"pm
|
||||
(byte[]) petscii_mixed2
|
||||
(const byte[]) petscii_mixed2#0 petscii_mixed2 = (string) PETSCII_MIXED"abcABC3@"
|
||||
(const byte[]) petscii_mixed2#0 petscii_mixed2 = (string) "abcABC3@"pm
|
||||
(byte[]) screencode_mixed1
|
||||
(const byte[]) screencode_mixed1#0 screencode_mixed1 = (string) "abcABC1@"
|
||||
(byte[]) screencode_mixed2
|
||||
@ -454,7 +454,7 @@ FINAL SYMBOL TABLE
|
||||
(byte[]) screencode_mixed3
|
||||
(const byte[]) screencode_mixed3#0 screencode_mixed3 = (string) "abcABC6@"
|
||||
(byte[]) screencode_upper
|
||||
(const byte[]) screencode_upper#0 screencode_upper = (string) SCREENCODE_UPPER"abcABC5@"
|
||||
(const byte[]) screencode_upper#0 screencode_upper = (string) "abcABC5@"su
|
||||
|
||||
reg byte x [ main::i#2 main::i#1 ]
|
||||
|
||||
|
@ -10,9 +10,9 @@
|
||||
(byte) main::i#1 reg byte x 16.5
|
||||
(byte) main::i#2 reg byte x 22.000000000000004
|
||||
(byte[]) petscii_mixed1
|
||||
(const byte[]) petscii_mixed1#0 petscii_mixed1 = (string) PETSCII_MIXED"abcABC2@"
|
||||
(const byte[]) petscii_mixed1#0 petscii_mixed1 = (string) "abcABC2@"pm
|
||||
(byte[]) petscii_mixed2
|
||||
(const byte[]) petscii_mixed2#0 petscii_mixed2 = (string) PETSCII_MIXED"abcABC3@"
|
||||
(const byte[]) petscii_mixed2#0 petscii_mixed2 = (string) "abcABC3@"pm
|
||||
(byte[]) screencode_mixed1
|
||||
(const byte[]) screencode_mixed1#0 screencode_mixed1 = (string) "abcABC1@"
|
||||
(byte[]) screencode_mixed2
|
||||
@ -20,6 +20,6 @@
|
||||
(byte[]) screencode_mixed3
|
||||
(const byte[]) screencode_mixed3#0 screencode_mixed3 = (string) "abcABC6@"
|
||||
(byte[]) screencode_upper
|
||||
(const byte[]) screencode_upper#0 screencode_upper = (string) SCREENCODE_UPPER"abcABC5@"
|
||||
(const byte[]) screencode_upper#0 screencode_upper = (string) "abcABC5@"su
|
||||
|
||||
reg byte x [ main::i#2 main::i#1 ]
|
||||
|
Loading…
x
Reference in New Issue
Block a user