maziac / DeZog

Visual Studio Code Debugger for Z80/ZX Spectrum.
MIT License
210 stars 34 forks source link

Possible bug in watch structures? #95

Closed michael3m closed 1 year ago

michael3m commented 1 year ago

I'm not sure, if I doing right, but anyway. Here is following code:

     struct hms
hr      byte    0
min     byte    0
sec     byte    0
     ends

     struct timer
number      byte    0
status      byte    0
row     byte
col     byte
t0      hms
t1      hms
t2      hms
t3      hms
t4      hms
tCounter    word
     ends

timer1      timer   1,,#03,#00,,,,,,,,,,,,,,,,#40a2     ; 21 bytes
timer2      timer   2,,#03,#0b,,,,,,,,,,,,,,,,#40ad
timer3      timer   3,,#03,#16,,,,,,,,,,,,,,,,#40b8
timer4      timer   4,,#0a,#00,,,,,,,,,,,,,,,,#4882
timer5      timer   5,,#0a,#0b,,,,,,,,,,,,,,,,#488d
timer6      timer   6,,#0a,#16,,,,,,,,,,,,,,,,#4898
timer7      timer   7,,#11,#00,,,,,,,,,,,,,,,,#5062
timer8      timer   8,,#11,#0b,,,,,,,,,,,,,,,,#506d
timer9      timer   9,,#11,#16,,,,,,,,,,,,,,,,#5078

And when I adding this structure into the "watch" window by typing "timer1,timer,9" I am getting correct information only for 1st structure member (look at the screenshot). I was expected to get at place "[1] number" value of 0x02, at place "[1] tCounter" - value 0x40ad, at place "[1] row" and "[1] col" - values of 0x03 and 0x0b respectively.

Is it a some kind of bug, or I just doing this wrong?

Screenshots struct

**Version etc.:

maziac commented 1 year ago

Thanks for reporting. I can reproduce the problem. Will try to find out what is going on.

maziac commented 1 year ago

I have added dezog-2.7.3-rc1.vsix here: https://github.com/maziac/DeZog/releases/tag/v2.7.2 Could you please check if it fixes your issue.

michael3m commented 1 year ago

Yes, main problem seems to be fixed, but new one appears: str2

maziac commented 1 year ago

I hope it will work now. Please try dezog-2.7.3-rc2.vsix in https://github.com/maziac/DeZog/releases/tag/v2.7.2.

michael3m commented 1 year ago

Great job, thanks!

maziac commented 1 year ago

If you like DeZog please consider writing a review: https://marketplace.visualstudio.com/items?itemName=maziac.dezog&ssr=false#review-details