@@ -135,17 +135,19 @@ bool device::has_extension(const std::string &extension_name) const {
135
135
136
136
#ifdef __INTEL_PREVIEW_BREAKING_CHANGES
137
137
template <typename Param>
138
- detail::ABINeutralT_t<
139
- typename detail::is_device_info_desc<Param>::return_type>
138
+ detail::ABINeutralT_t<typename detail::is_device_info_desc<Param>::return_type>
140
139
device::get_info_impl () const {
141
- auto Info = impl->template get_info <Param>();
142
- return detail::convert_to_abi_neutral (Info);
140
+ return detail::convert_to_abi_neutral (impl->template get_info <Param>());
143
141
}
144
142
#else
145
143
template <typename Param>
146
- typename detail::is_device_info_desc<Param>::return_type
144
+ detail::ABINeutralT_t< typename detail::is_device_info_desc<Param>::return_type>
147
145
device::get_info () const {
148
- return impl->template get_info <Param>();
146
+ static_assert (
147
+ std::is_same_v<detail::ABINeutralT_t<typename detail::is_device_info_desc<
148
+ Param>::return_type>,
149
+ typename detail::is_device_info_desc<Param>::return_type>);
150
+ return detail::convert_to_abi_neutral (impl->template get_info <Param>());
149
151
}
150
152
#endif
151
153
@@ -211,11 +213,12 @@ __SYCL_EXPORT bool device::get_info<info::device::image_support>() const {
211
213
212
214
#ifdef __INTEL_PREVIEW_BREAKING_CHANGES
213
215
#define __SYCL_PARAM_TRAITS_SPEC (DescType, Desc, ReturnT, PiCode ) \
214
- template __SYCL_EXPORT detail::ABINeutralT_t<ReturnT> \
216
+ template __SYCL_EXPORT detail::ABINeutralT_t<ReturnT> \
215
217
device::get_info_impl<info::device::Desc>() const ;
216
218
#else
217
219
#define __SYCL_PARAM_TRAITS_SPEC (DescType, Desc, ReturnT, PiCode ) \
218
- template __SYCL_EXPORT ReturnT device::get_info<info::device::Desc>() const ;
220
+ template __SYCL_EXPORT detail::ABINeutralT_t<ReturnT> \
221
+ device::get_info<info::device::Desc>() const ;
219
222
#endif
220
223
221
224
#define __SYCL_PARAM_TRAITS_SPEC_SPECIALIZED (DescType, Desc, ReturnT, PiCode )
@@ -226,11 +229,11 @@ __SYCL_EXPORT bool device::get_info<info::device::image_support>() const {
226
229
227
230
#ifdef __INTEL_PREVIEW_BREAKING_CHANGES
228
231
#define __SYCL_PARAM_TRAITS_SPEC (Namespace, DescType, Desc, ReturnT, PiCode ) \
229
- template __SYCL_EXPORT detail::ABINeutralT_t<ReturnT> \
232
+ template __SYCL_EXPORT detail::ABINeutralT_t<ReturnT> \
230
233
device::get_info_impl<Namespace::info::DescType::Desc>() const ;
231
234
#else
232
235
#define __SYCL_PARAM_TRAITS_SPEC (Namespace, DescType, Desc, ReturnT, PiCode ) \
233
- template __SYCL_EXPORT ReturnT \
236
+ template __SYCL_EXPORT typename detail::ABINeutralT_t<ReturnT> \
234
237
device::get_info<Namespace::info::DescType::Desc>() const ;
235
238
#endif
236
239
0 commit comments