clang

uchar.h file not found on OS X 10.9

一世执手 提交于 2020-12-29 03:04:43
问题 I'm under the impression my C compiler supports C11 since it accepts the -std=c11 flag, $ cc --version Apple LLVM version 5.1 (clang-503.0.40) (based on LLVM 3.4svn) Target: x86_64-apple-darwin13.3.0 Thread model: posix and uchar.h is part of the C11 standard, so I'd expect this program to compile, $ cat /tmp/esc.c #include <uchar.h> int main(void) {} But $ cc /tmp/esc.c /tmp/esc.c:1:10: fatal error: 'uchar.h' file not found #include <uchar.h> ^ 1 error generated. I tried locating the uchar.h

uchar.h file not found on OS X 10.9

无人久伴 提交于 2020-12-29 03:01:14
问题 I'm under the impression my C compiler supports C11 since it accepts the -std=c11 flag, $ cc --version Apple LLVM version 5.1 (clang-503.0.40) (based on LLVM 3.4svn) Target: x86_64-apple-darwin13.3.0 Thread model: posix and uchar.h is part of the C11 standard, so I'd expect this program to compile, $ cat /tmp/esc.c #include <uchar.h> int main(void) {} But $ cc /tmp/esc.c /tmp/esc.c:1:10: fatal error: 'uchar.h' file not found #include <uchar.h> ^ 1 error generated. I tried locating the uchar.h

uchar.h file not found on OS X 10.9

青春壹個敷衍的年華 提交于 2020-12-29 03:00:38
问题 I'm under the impression my C compiler supports C11 since it accepts the -std=c11 flag, $ cc --version Apple LLVM version 5.1 (clang-503.0.40) (based on LLVM 3.4svn) Target: x86_64-apple-darwin13.3.0 Thread model: posix and uchar.h is part of the C11 standard, so I'd expect this program to compile, $ cat /tmp/esc.c #include <uchar.h> int main(void) {} But $ cc /tmp/esc.c /tmp/esc.c:1:10: fatal error: 'uchar.h' file not found #include <uchar.h> ^ 1 error generated. I tried locating the uchar.h

LLVM & Clang can't compile for a supported arch

爱⌒轻易说出口 提交于 2020-12-24 12:32:10
问题 Under Ubuntu 64 bit I got llc --version LLVM (http://llvm.org/): LLVM version 3.1 Optimized build with assertions. Built Oct 15 2012 (18:15:59). Default target: x86_64-pc-linux-gnu Host CPU: btver1 Registered Targets: arm - ARM mips - Mips mips64 - Mips64 [experimental] mips64el - Mips64el [experimental] mipsel - Mipsel thumb - Thumb x86 - 32-bit X86: Pentium-Pro and above x86-64 - 64-bit X86: EM64T and AMD64 I can't do this clang -march=arm -x c++ /tmp/cpp.cpp error: unknown target CPU 'arm'

LLVM & Clang can't compile for a supported arch

牧云@^-^@ 提交于 2020-12-24 12:29:51
问题 Under Ubuntu 64 bit I got llc --version LLVM (http://llvm.org/): LLVM version 3.1 Optimized build with assertions. Built Oct 15 2012 (18:15:59). Default target: x86_64-pc-linux-gnu Host CPU: btver1 Registered Targets: arm - ARM mips - Mips mips64 - Mips64 [experimental] mips64el - Mips64el [experimental] mipsel - Mipsel thumb - Thumb x86 - 32-bit X86: Pentium-Pro and above x86-64 - 64-bit X86: EM64T and AMD64 I can't do this clang -march=arm -x c++ /tmp/cpp.cpp error: unknown target CPU 'arm'

Why does gcc warn about calling a non-trivial move assignment operator with std::tuple and virtual inheritance?

扶醉桌前 提交于 2020-12-23 03:31:44
问题 In the following example gcc 7 gives a warning: defaulted move assignment for 'B' calls a non-trivial move assignment operator for virtual base 'A' [-Wvirtual-move-assign] if I create an std::tuple<B> object. Clang 5 doesn't report any problems. Also the problem goes away if vector is removed from Base . Example. #include <tuple> #include <vector> class Base { public: virtual ~Base(); std::vector<int> v; }; class A : public Base { }; class B : public virtual A { }; int main() { B *b = new B;

Why does gcc warn about calling a non-trivial move assignment operator with std::tuple and virtual inheritance?

徘徊边缘 提交于 2020-12-23 03:29:48
问题 In the following example gcc 7 gives a warning: defaulted move assignment for 'B' calls a non-trivial move assignment operator for virtual base 'A' [-Wvirtual-move-assign] if I create an std::tuple<B> object. Clang 5 doesn't report any problems. Also the problem goes away if vector is removed from Base . Example. #include <tuple> #include <vector> class Base { public: virtual ~Base(); std::vector<int> v; }; class A : public Base { }; class B : public virtual A { }; int main() { B *b = new B;

Why does gcc warn about calling a non-trivial move assignment operator with std::tuple and virtual inheritance?

蹲街弑〆低调 提交于 2020-12-23 03:27:01
问题 In the following example gcc 7 gives a warning: defaulted move assignment for 'B' calls a non-trivial move assignment operator for virtual base 'A' [-Wvirtual-move-assign] if I create an std::tuple<B> object. Clang 5 doesn't report any problems. Also the problem goes away if vector is removed from Base . Example. #include <tuple> #include <vector> class Base { public: virtual ~Base(); std::vector<int> v; }; class A : public Base { }; class B : public virtual A { }; int main() { B *b = new B;

clang-7: error: linker command failed with exit code 1 for macOS Big Sur

自作多情 提交于 2020-12-22 19:24:31
问题 Installing R packages that need compiling in macOS is broken since Big Sur. Here is such an example. > install.packages('nlme') There is a binary version available but the source version is later: binary source needs_compilation nlme 3.1-150 3.1-151 TRUE Do you want to install from sources the package which needs compilation? (Yes/no/cancel) Yes installing the source package ‘nlme’ trying URL 'https://cran.rstudio.com/src/contrib/nlme_3.1-151.tar.gz' Content type 'application/x-gzip' length

clang-7: error: linker command failed with exit code 1 for macOS Big Sur

大憨熊 提交于 2020-12-22 19:13:49
问题 Installing R packages that need compiling in macOS is broken since Big Sur. Here is such an example. > install.packages('nlme') There is a binary version available but the source version is later: binary source needs_compilation nlme 3.1-150 3.1-151 TRUE Do you want to install from sources the package which needs compilation? (Yes/no/cancel) Yes installing the source package ‘nlme’ trying URL 'https://cran.rstudio.com/src/contrib/nlme_3.1-151.tar.gz' Content type 'application/x-gzip' length