mirror of
https://github.com/opencv/opencv.git
synced 2024-11-24 19:20:28 +08:00
gapi: fix build with Intel Compiler 2019
This commit is contained in:
parent
8c25a8eb7b
commit
f75152a597
@ -328,7 +328,8 @@ namespace util
|
||||
util::type_list_index<T, Types...>::value;
|
||||
|
||||
if (v.index() == t_index)
|
||||
return reinterpret_cast<T&>(v.memory);
|
||||
return *(T*)(&v.memory); // workaround for ICC 2019
|
||||
// original code: return reinterpret_cast<T&>(v.memory);
|
||||
else
|
||||
throw_error(bad_variant_access());
|
||||
}
|
||||
@ -340,7 +341,8 @@ namespace util
|
||||
util::type_list_index<T, Types...>::value;
|
||||
|
||||
if (v.index() == t_index)
|
||||
return reinterpret_cast<const T&>(v.memory);
|
||||
return *(const T*)(&v.memory); // workaround for ICC 2019
|
||||
// original code: return reinterpret_cast<const T&>(v.memory);
|
||||
else
|
||||
throw_error(bad_variant_access());
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user