japheth - 2012-12-30

v2.10 will have an small syntax extension for the LABEL directive: an optional argument that will make the label an array of X elements.

Here's a sample:

;--- demonstrates syntax extension for LABEL directive,
;--- implemented in jwasm v2.10.
;--- this extension allows to define large initialized arrays
;--- that are not restricted by the line size limit.
;--- Inside the debugger, all array elements are accessible.
;--- cmdline option -Zne will disable the feature.
    .386
    .model flat, stdcall
    .DATA
ifdef __JWASM__
xarray label word [b]: size_xarray / sizeof word[/b]
else
xarray label word
endif
    dw 1,2,3,4,5,6,7,8,9,0
    dw 11,12,13,14,15,16,17,18,19,20
    dw 21,22,23,24,25,26,27,28,29,30
    dw 31,32,33,34,35,36,37,38,39,40
    dw 41,42,43,44,45,46,47,48,49,50
    dw 51,52,53,54,55,56,57,58,59,60
    dw 61,62,63,64,65,66,67,68,69,70
    dw 71,72,73,74,75,76,77,78,79,80
    dw 81,82,83,84,85,86,87,88,89,90
    dw 91,92,93,94,95,96,97,98,99,100
size_xarray equ $ - xarray
    .code
start:
    mov eax, sizeof xarray     ;SIZEOF will return the total size
    mov ecx, lengthof xarray   ;LENGTHOF will return the number of elements
    ret
    END start

The next prerelease will contain the addition.