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

Program logic within assert statements #465

Open
kubagalecki opened this issue Nov 22, 2023 · 0 comments
Open

Program logic within assert statements #465

kubagalecki opened this issue Nov 22, 2023 · 0 comments

Comments

@kubagalecki
Copy link
Contributor

See e.g.:

#define CudaMalloc(a__,b__) assert( (*((void**)(a__)) = malloc(b__)) != NULL )

Program logic should not depend on the contents of assert statements, since they will be #ifdefed out in a release (-DNDEBUG) build. This happens in multiple places in the code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant