Saturday 25 April 2015

The Rest Will Follow

The LLVM + Clang compiler toolchain 3.6 release can be downloaded as prebuilt executables for Windows. So far, so good, so what? The interesting and practical part of this is the source and ABI compatability with Microsoft Visual C++ and the integration with Visual Studio. This means that choosing to use the Clang front end and LLVM backend is as simple as choosing the relevant toolchain in the VS properties (ideally, at the configure step of using CMake to generate the VS project!). This painless process means it is trivial to try out Clang without needing to be steeped in Linux, or owner of the expensive dongle for OSX aka some sort of Mac computer hardware.

Reality is, of course, that this does not yet provide an actual satisfactory outcome. Clang + LLVM on Windows for the VS ABI is still a work in process, with respect to not handling all of the extensions to C++ present in the Windows SDK and MFC headers, and the lack as yet of any support for C++ exceptions.

None the less, the compiler functions as a useful and valuable linter of C++ code previously restricted to building with MSVC due to heavy usage of MFC and Windows headers. 

No comments: