1
0
mirror of https://gitlab.com/camelot/kickc.git synced 2024-11-20 02:32:36 +00:00

Working on fixing test errors - 198/350 working.

This commit is contained in:
jespergravgaard 2019-05-07 22:08:59 +02:00
parent 44e9cff722
commit cab95b6ba5
5 changed files with 24 additions and 4 deletions

View File

@ -0,0 +1,5 @@
sta {z1}
lda #0
sta {z1}+1
sta {z1}+2
sta {z1}+3

View File

@ -0,0 +1,13 @@
lda {z2}
clc
adc #<{c1}
sta {z1}
lda {z2}+1
adc #>{c1}
sta {z1}+1
lda {z2}+2
adc #0
sta {z1}+2
lda {z2}+3
adc #0
sta {z1}+3

View File

@ -10,5 +10,4 @@ adc {z2}+2
sta {z1}+2
lda {z1}+3
adc {z2}+3
sta {z1}+3
sta {z1}+3

View File

@ -10,5 +10,4 @@ adc #0
sta {z1}+2
lda {z2}+3
adc #0
sta {z1}+3
sta {z1}+3

View File

@ -98,7 +98,9 @@ public interface ProgramExpressionBinary extends ProgramExpression {
tmpVar.setType(toType);
StatementAssignment newAssignment = new StatementAssignment(tmpVar.getRef(), Operators.getCastUnary(toType), assignment.getrValue1(), assignment.getSource(), Comment.NO_COMMENTS);
assignment.setrValue1(tmpVar.getRef());
stmtIt.previous();
stmtIt.add(newAssignment);
stmtIt.next();
}
}
@ -112,7 +114,9 @@ public interface ProgramExpressionBinary extends ProgramExpression {
tmpVar.setType(toType);
StatementAssignment newAssignment = new StatementAssignment(tmpVar.getRef(), Operators.getCastUnary(toType), assignment.getrValue2(), assignment.getSource(), Comment.NO_COMMENTS);
assignment.setrValue2(tmpVar.getRef());
stmtIt.previous();
stmtIt.add(newAssignment);
stmtIt.next();
}
}
}