Skip to content

Commit

Permalink
Fix unused variable in structured bindings for old GCC
Browse files Browse the repository at this point in the history
Signed-off-by: Julian Oppermann <[email protected]>
  • Loading branch information
jopperm committed Jan 16, 2025
1 parent 5c529aa commit dd081f6
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions sycl/source/detail/kernel_bundle_impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -530,8 +530,10 @@ class kernel_bundle_impl {
for (const auto &DeviceGlobalProp : RawImg->getDeviceGlobals()) {
std::string_view DeviceGlobalName{DeviceGlobalProp->Name};
assert(DeviceGlobalName.find(Prefix) == 0);
auto [It, Ins] = DeviceGlobalIDSet.emplace(DeviceGlobalName);
if (Ins) {
bool Inserted = false;
std::tie(std::ignore, Inserted) =
DeviceGlobalIDSet.emplace(DeviceGlobalName);
if (Inserted) {
DeviceGlobalIDVec.emplace_back(DeviceGlobalName);
DeviceGlobalName.remove_prefix(PrefixLen);
DeviceGlobalNames.emplace_back(DeviceGlobalName);
Expand Down

0 comments on commit dd081f6

Please sign in to comment.