0

I have defined a const to be used as argument in KickAssembler (C64) macro. This works:

.macro MAZE(start){
  .const WALL = $E0
  MAZE_fill(WALL)
}

This does not:

.const WALL = $E0
.macro MAZE(start){
    MAZE_fill(WALL)
}

So, if symbol is defined within macro, it is recognized during assembly. But if it is global, then it is not.
My motivation is to have global symbols, so there is only one place to change them.
Is there a way to do it?

Lovro
  • 185
  • 1
  • 3
  • 12

1 Answers1

0

It was wrong to use const. When using label, this works as expected (globally).

.label WALL = $E0
.macro MAZE(start){
    MAZE_fill(WALL)
}
Lovro
  • 185
  • 1
  • 3
  • 12