aiscript
aiscript copied to clipboard
範囲外の添字で配列に代入できてしまう
配列代入時の代入先存在チェックがTODOのまま実装されていないので、範囲外の添字や整数以外の添字でも代入できてしまう
let a = []
a[1] = 'v' // not error
<: a.len // 2
<: a[1] // 'v'
<: a[0] // Error: Index out of range. index: 0 max: 1
https://github.com/aiscript-dev/aiscript/blob/537fa96b3990fe55a7bebd1864f12ac87144b876/src/interpreter/index.ts#L615