Skip to content

Commit

Permalink
Fix clang template error.
Browse files Browse the repository at this point in the history
  • Loading branch information
Pentarctagon committed Apr 24, 2022
1 parent 59fe376 commit e977d3c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/gui/core/event/dispatcher.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -625,7 +625,8 @@ class dispatcher
} else if constexpr(cat == event_category::text_input) {
return signal_text_input_queue_;
} else {
static_assert(utils::dependent_false_v<cat>, "No matching signal queue for category");
// "No matching signal queue for category"
utils::static_no_match();
}
}
};
Expand Down
3 changes: 3 additions & 0 deletions src/utils/general.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,9 @@ inline constexpr bool decayed_is_same = std::is_same_v<std::decay_t<T1>, std::de
template<typename>
inline constexpr bool dependent_false_v = false;

template<bool flag = false>
void static_no_match() { static_assert(flag, "hi"); }

namespace detail
{
/**
Expand Down

0 comments on commit e977d3c

Please sign in to comment.