Dotneteer / spectnetide

ZX Spectrum IDE with Visual Studio 2017 and 2019 integration
MIT License
205 stars 27 forks source link

[Z80 Assembly feature] Allow temporary labels (starting with a backtick, ` ) #119

Closed Dotneteer closed 5 years ago

Dotneteer commented 5 years ago

Temporary labels have a limited scope, only between persistent labels:

SetPixels:        ; Persistent label
  ld hl, #4000
  ld a,#AA
  ld b,#20
`loop:            ; Temporary label (scope #1)
  ld (hl),a
  inc hl
  djnz `loop
SetAttr:          ; Persistent label, scope #1 disposed here
  ld hl,#5800
  ld a,#32
  ld b,#20
`loop:            ; Temporary label (scope #2)
  ld (hl),a
  inc hl
  djnz `loop
  ret

; scope #2 still lives here
; ...
Another: ; Persistent label, scope #2 disposed here
  ld a,b
Dotneteer commented 5 years ago

Implemented, will be released soon.

Dotneteer commented 5 years ago

Released in v1.17.0