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

Fix error behavior for initialize_to_identity #651

Merged
merged 1 commit into from
Nov 7, 2024

Conversation

Pennycook
Copy link
Contributor

Previously, the specification said that a compiler must issue a diagnostic if the initialize_to_identity property was used without a known identity value. This requirement cannot be satisfied, because the presence of the initialize_to_identity value in a property_list cannot be proven until run-time.

This change replaces the compile-time diagnostic with a run-time exception.

Previously, the specification said that a compiler must issue a diagnostic if
the initialize_to_identity property was used without a known identity value.
This requirement cannot be satisfied, because the presence of the
initialize_to_identity value in a property_list cannot be proven until
run-time.

This change replaces the compile-time diagnostic with a run-time exception.
@TApplencourt
Copy link
Contributor

TApplencourt commented Oct 28, 2024

Good catch.

I guess we can put this kind of stuff back when we have "compile-time properties".

BTW, do we have a test on the CTS that we need to adjust? (aka compile time versus runtime error)

@Pennycook
Copy link
Contributor Author

I guess we can put this kind of stuff back when we have "compile-time properties".

Agreed.

BTW, do we have a test on the CTS that we need to adjust? (aka compile time versus runtime error)

I think so. I'm not very good at reading the CTS tests, but it looks to me like we only test valid uses of initialize_to_identity.

@tomdeakin
Copy link
Contributor

WG approved to merge

@tomdeakin tomdeakin merged commit 8424248 into KhronosGroup:main Nov 7, 2024
2 checks passed
gmlueck pushed a commit to gmlueck/SYCL-Docs that referenced this pull request Nov 7, 2024
Cherry pick KhronosGroup#651 from main
(cherry picked from commit 8424248)
gmlueck pushed a commit that referenced this pull request Nov 7, 2024
Fix error behavior for initialize_to_identity

(cherry picked from commit 8424248)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants