How can I find the actual Clang version on Mac?

后端 未结 3 1201
渐次进展
渐次进展 2021-02-19 08:07

Note: None of the answers provided at Get Apple clang version and corresponding upstream LLVM version seems to work anymore.

The download page at http://releases.llvm.or

3条回答
  •  眼角桃花
    2021-02-19 08:46

    You could try using

    echo | clang -dM -E - | grep __clang
    

    and maybe that will give you more reliable numbers. Although I'm speculating since I'm not on a Mac.

    Also, clang has had the -pedantic option for a long long time - many versions before 6.0. -pedantic is a GCC option and clang takes after GCC in its options.

提交回复
热议问题