diff --git a/src/main/java/dk/camelot64/kickc/test/callconstparamproblem.kc b/src/main/java/dk/camelot64/kickc/test/callconstparamproblem.kc new file mode 100644 index 000000000..2531ce1bc --- /dev/null +++ b/src/main/java/dk/camelot64/kickc/test/callconstparamproblem.kc @@ -0,0 +1,20 @@ +// Multiple calls with different (constant?) parameters should yield different values at runtime +// Currently the same constant parameter is passed on every call. +// Reason: Multiple versioned parameter constants x0#0, x0#1 are only output as a single constant in the ASM .const x0 = 0 + +byte* screen = $0400; + +main(); + +void main() { + line(1,2); + line(3,5); +} + +void line(byte x0, byte x1) { + for(byte x = x0; x