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

Fill out min and max #159

Merged
merged 1 commit into from
Jul 22, 2023
Merged

Conversation

dpgrote
Copy link
Contributor

@dpgrote dpgrote commented Jul 22, 2023

This enhances the min and max wrappers, adding keyword arguments with defaults, error checking of the input, and doc strings.

It would be nice to have this level of wrapping for all of the routines, but this would be a fair amount of work. The error checking is fairly important since wrong values can give either just bad results or seg faults.

@ax3l ax3l self-assigned this Jul 22, 2023
@ax3l ax3l added the enhancement New feature or request label Jul 22, 2023
Copy link
Member

@ax3l ax3l left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, this is great!

Some of the error checking, e.g., if used outside of hot loops, could also be done on the AMReX C++ side.

A clean throw will propagate to our level as long as we compile with RTTI enabled #76

@ax3l ax3l enabled auto-merge (squash) July 22, 2023 01:13
@ax3l ax3l merged commit b63a9e6 into AMReX-Codes:development Jul 22, 2023
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants