I'm trying Kaitai Struct to decode some data. I need to pass an array parameter, but ksc gives an error. Follow is an example code:
meta:
id: cat_34
seq:
- id: test1
type: fixed([0,1,2])
types:
fixed:
params:
- id: f_size
#no type is just an array
seq:
- id: val
type: u1
repeat: expr
repeat-expr: f_size[1] #trying to use second value of array.
It gives the following error: cat_34: /types/fixed/seq/0/repeat-expr: unable to apply operation [] to CalcBytesType