Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SmallMatrix: Assert Lower Bound Index #4283

Merged
merged 1 commit into from
Jan 7, 2025

Conversation

ax3l
Copy link
Member

@ax3l ax3l commented Jan 4, 2025

Summary

With 1-based indices, it is easy to access 0 and be out-of-bounds. Add an assert for the lower bound of the index range as well.

Additional background

Follow-up to #4188

Checklist

The proposed changes:

  • fix a bug or incorrect behavior in AMReX
  • add new capabilities to AMReX
  • changes answers in the test suite to more than roundoff level
  • are likely to significantly affect the results of downstream AMReX users
  • include documentation in the code and/or rst files, if appropriate

With 1-based indices, it is easy to access `0` and be
out-of-bounds. Add an assert for the lower bound of the index
range as well.
@WeiqunZhang WeiqunZhang merged commit 3a34576 into AMReX-Codes:development Jan 7, 2025
75 checks passed
@ax3l ax3l deleted the sm-check-low-bnd branch January 8, 2025 02:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants