-
Notifications
You must be signed in to change notification settings - Fork 68
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 typo with "accessor::get_pointer" #549
Fix typo with "accessor::get_pointer" #549
Conversation
It appears that we introduced a typo with KhronosGroup#432 with the return type of `accessor::get_pointer`. In the synopsis, we specified it as: ``` global_ptr<DataT> get_pointer() const noexcept ``` But in the description, it seems that we made a typo and said: ``` global_ptr<access::decorated::legacy> get_pointer() const noexcept ``` I believe these are both wrong, and it should be: ``` global_ptr<value_type> get_pointer() const noexcept ``` Using `value_type` is better than `DataT` because `value_type` is const when the accessor is read-only.
Deprecated a few APIs which are not in SYCL 2020 spec: - `accessor::get_multi_ptr()` should be available only when `AccessTarget == target::device`. - `marray<DataT, N>::operator++/--`should be available only when `DataT != bool`. Updated `multi_ptr::get_pointer()` to use correct type alias in accordance with KhronosGroup/SYCL-Docs#549 --------- Signed-off-by: Hu, Peisen <peisen.hu@intel.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checking to see if a non-member can approve a PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks.
I have the feeling that https://github.com/KhronosGroup/SYCL-Docs/pull/432/files#diff-498c175f1b8454ffa58e5f5d9db2c295f04199f9833a50e48159b9534a4cb496R68 looks weird too. |
Actually, that is not wrong because |
Fix typo with "accessor::get_pointer"
Fix typo with "accessor::get_pointer" (cherry picked from commit 1b8c0c0)
Fix typo with "accessor::get_pointer" (cherry picked from commit 1b8c0c0)
It appears that we introduced a typo with #432 with the return type of
accessor::get_pointer
. In the synopsis, we specified it as:But in the description, it seems that we made a typo and said:
I believe these are both wrong, and it should be:
Using
value_type
is better thanDataT
becausevalue_type
is const when the accessor is read-only.