spnda / fastgltf

A modern C++17 glTF 2.0 library focused on speed, correctness, and usability
https://fastgltf.readthedocs.io/v0.8.x/
MIT License
301 stars 44 forks source link

Fix: Inline deserializeComponent template specializations #47

Closed hilloftheking closed 8 months ago

hilloftheking commented 8 months ago

This allows for multiple translation units to include tools.hpp For some reason this already worked properly on GCC, but now it will work on MSVC.

spnda commented 8 months ago

After merging I noticed that perhaps some compilers will throw a warning about the function being marked as constexpr inline when FASTGLTF_CONSTEXPR_BITCAST is 1. I can only find a relevant MR from clang-tidy which shows a warning in this case: https://reviews.llvm.org/D18914

If that ever comes up from someone using -Wall or -Werror i'll fix it. Thanks though.