Remove deduction guides for alias templates to support C++20 - #15
Open
benvanwerkhoven wants to merge 1 commit into
Open
benvanwerkhoven wants to merge 1 commit into
benvanwerkhoven wants to merge 1 commit into
Conversation
The deduction guides for vec, vec_ptr, kscalar, kvec and kconstant were enabled only for `__cpp_deduction_guides >= 201907L`, i.e. C++20. Compilers reject guides that name an alias template, so kernel_float.h could not be included in C++20 builds. From C++20, the compiler derives deduction guides for alias templates from the class template's own guides, so these can be removed. Adds tests/deduction.cu with compile-time checks of class template argument deduction.
Member
|
Thanks. Looks good to me! The HIP test seem to be failing, I'l look into this: |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The deduction guides for vec, vec_ptr, kscalar, kvec and kconstant were enabled only for
__cpp_deduction_guides >= 201907L, i.e. C++20. Compilers reject guides that name an alias template, so kernel_float.h could not be included in C++20 builds. From C++20, the compiler derives deduction guides for alias templates from the class template's own guides, so these can be removed. Adds tests/deduction.cu with compile-time checks of class template argument deduction.Perhaps the CI should also test with C++20.