[LLVMdev] LLVM 3.4: snprintf() with g++ -std=c++11: error: 'snprintf' was not declared in this scope (original) (raw)
Csaba Raduly rcsaba at gmail.com
Fri Mar 14 01:59:58 PDT 2014
- Previous message: [LLVMdev] LLVM 3.4: snprintf() with g++ -std=c++11: error: 'snprintf' was not declared in this scope
- Next message: [LLVMdev] Intrinsic instruction to switch core
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hi,
On Sun, Mar 9, 2014 at 10:41 AM, zosrothko wrote: (snip)
'snprintf' was not declared in this scope return snprintf(Buffer, BufferSize, Fmt, Val);
In the Cygwin mailing list, this thread "http://cygwin.com/ml/cygwin/2012-04/msg00140.html" explains the problem that I have reproduced fully and states it could be a bug in gcc . The proposed workarounds are 1/ use -std=gnu11 which works 2/ explicitly declare int snprintf ( char * s, sizet n, const char * format, ... );
This should now be fixed. http://clang-developers.42468.n3.nabble.com/Re-MinGW-build-does-not-compile-with-C-11-td4038387.html
Csaba
GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++ The Tao of math: The numbers you can count are not the real numbers. Life is complex, with real and imaginary parts. "Ok, it boots. Which means it must be bug-free and perfect. " -- Linus Torvalds "People disagree with me. I just ignore them." -- Linus Torvalds
- Previous message: [LLVMdev] LLVM 3.4: snprintf() with g++ -std=c++11: error: 'snprintf' was not declared in this scope
- Next message: [LLVMdev] Intrinsic instruction to switch core
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]