summaryrefslogtreecommitdiff
path: root/editor/icons/Camera2D.svg
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2022-01-10 13:56:55 +0100
committerRémi Verschelde <rverschelde@gmail.com>2022-01-10 22:42:03 +0100
commitc6cefb1b79d207af1bc78ce20c01b5788e806252 (patch)
treeca713ba3bf904b57a7408ec50029c9fbcc275d40 /editor/icons/Camera2D.svg
parent4acc819f9bafacf5f912caf5ba2ebc15f70e3dbb (diff)
`Array`: Relax `slice` bound checks to properly handle negative indices
The same is done for `Vector` (and thus `Packed*Array`). `begin` and `end` can now take any value and will be clamped to `[-size(), size()]`. Negative values are a shorthand for indexing the array from the last element upward. `end` is given a default `INT_MAX` value (which will be clamped to `size()`) so that the `end` parameter can be omitted to go from `begin` to the max size of the array. This makes `slice` works similarly to numpy's and JavaScript's.
Diffstat (limited to 'editor/icons/Camera2D.svg')
0 files changed, 0 insertions, 0 deletions