Skip to content

Commit

Permalink
interface: Improve error message if lookup in data layout fails.
Browse files Browse the repository at this point in the history
  • Loading branch information
lkorenc authored and xlauko committed Oct 24, 2023
1 parent 061485e commit f081f37
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions include/vast/Interfaces/DefaultDataLayoutTypeInterface.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,16 @@ namespace vast
*out, current, entries.size());
};

auto casted_self = static_cast< const ConcreteType & >(self);
for (const auto &entry : entries)
{
auto raw = dl::DLEntry(entry);
auto casted_self = static_cast< const ConcreteType & >(self);
if (casted_self == raw.type)
handle_entry(raw);
}

VAST_CHECK(out.has_value(), "Data layout query did not produce a value!");
VAST_CHECK(out.has_value(), "Data layout query of {0} did not produce a value!",
casted_self);
return *out;
}

Expand Down

0 comments on commit f081f37

Please sign in to comment.