CMake is forcing MSVC to use C compiler on C++ code

I am trying to compile C++ code and CMake on CLion chooses the Visual Studio C compiler to compile it.

In general this is pretty hard to do as the Visual Studio compiler and CMake both prefer C++ over C.

add_subdirectory( extern/glfw )

My initial guess it that something in glfw is somehow forcing everything to be C instead of C++.