Skip to content

wrapperutils: Fix compiler warning on GCC 5.x

Philip Chimento requested to merge ptomato/gjs:253-fix-build into master

We had a cast to void* which suppressed this warning on later versions of GCC, but that doesn't work on GCC 5.x. While researching the warning I read advice to not mix static template programming with dynamic template programming. In C++17 we could solve this statically with "if constexpr", but we only require C++14, so the best option is to change the whole thing to dynamic, providing a no_type_struct() function for the template specializations that don't have a GType struct.

Closes: #253 (closed).

Merge request reports