我正在使用 Apple LLVM 6.0 (clang-600.0.56)(基于 LLVM 3.5svn)在 OSX 上编译
具体来说,我正在尝试从 LibIIR 编译一个单一的源代码,LibIIR 是一个由 Laurence Withers在这里维护的过滤器库。
我已经看过这个答案在这里了有关同时使用<complex>,并<complex.h>在同一个文件。
我有一个iir.h像这样的文件:
#include <complex.h>
#ifdef __cplusplus
extern "C" {
#endif
...
Run Code Online (Sandbox Code Playgroud)
我有 C++ 源文件libiir++.cpp和头文件,iir++.h就像这样:
/*** libiir++.cpp ***/
// we need to include "iir.h" first, as it pulls in <complex.h>, which we need
// to take effect before "iir++.h" pulls in <complex>
#include "iir.h"
// now remove the …Run Code Online (Sandbox Code Playgroud)