diff options
author | 2021-11-19 07:57:21 -0800 | |
---|---|---|
committer | 2021-11-19 07:57:21 -0800 | |
commit | 8ea3f2fc419605e65fddad2d8d024882480a009f (patch) | |
tree | ae7d7d8dc5ccf9b4d6710d449ee7b315cce64cd0 /Source/Utils/WarpXUtil.cpp | |
parent | 45ef533c39a55d05afbb9872659963d19b79f463 (diff) | |
download | WarpX-8ea3f2fc419605e65fddad2d8d024882480a009f.tar.gz WarpX-8ea3f2fc419605e65fddad2d8d024882480a009f.tar.zst WarpX-8ea3f2fc419605e65fddad2d8d024882480a009f.zip |
Bilinear Filter: Fix Warning (Vector) (#2575)
GCC warns in some versions on the access here, since it cannot figure out the runtime size of the vectors.
We can just replace `[]` with `.at()` to use a range-checked access that throws an exception instead of a segfault/UB when accessed out-of-bounds. In the preparation of the compute stencils, we don't have hot loops that benefit from non-range checked access, so that cost for improved safety is fine.
Diffstat (limited to 'Source/Utils/WarpXUtil.cpp')
0 files changed, 0 insertions, 0 deletions