We should run clang-tidy in our Jenkins CI. In particular, the [`misc-definitions-in-headers`](https://clang.llvm.org/extra/clang-tidy/checks/misc/definitions-in-headers.html#misc-definitions-in-headers) rule should keep things like #3245 up to date over time _Originally posted by @WardBrian in https://github.com/stan-dev/math/issues/3245#issuecomment-3386018840_