c++11
Gnu C++ macro __cplusplus standard conform?
The Gnu C++ compiler seems to define __cplusplus to be 1 #include <iostream> int main() { std::cout << __cplusplus << std::endl;[详细]
2023-04-08 11:35 分类:问答Question on object lifetime : N3242 Draft
A point from C++11 n3242 \"Duration of subobjects, object lifetime\", 3.8/1: The lifetime of an object is a runtime property of the object. An object is said[详细]
2023-04-08 10:38 分类:问答What does `<cuchar>` provide, and where is it documented?
The new C++11 standard mentions a header <cuchar>, presumably in analogy to C99\'s <uchar.h>.[详细]
2023-04-08 09:20 分类:问答c++11 foreach syntax and custom iterator
I am writing an iterator for a container which is being used in place of a STL container. Currently the STL container is being used in many places with the c++11 foreach syntax eg: for(auto &x: C)[详细]
2023-04-08 09:14 分类:问答Is string::c_str() no longer null terminated in C++11?
In C++11 basic_string::c_str is defined to be exactly the same as basic_string::data, which is in turn defined to be exactly the same as *(begin() + n) and *(&*begin() +开发者_如何转开发 n) (when[详细]
2023-04-08 06:42 分类:问答How to get the argument for promise::set_exception(x)?
I found in several places on how a promise should be used references to copy_exception, but I can not find it in the current FDIS. Is there an alternative way on how to use set_exception() since those[详细]
2023-04-08 01:30 分类:问答Gluing a variadic template to a variadic function
In an attempt to bypass GCC\'s unimplemented always-inlining variadic functions in libc++, I thought I could maybe wrap the variadic functions (like snprintf, more precisely, the *_l variant) in a var[详细]
2023-04-07 15:41 分类:问答Move constructor for std::mutex
Many classes in the c++ standard library now ha开发者_运维知识库ve move constructors, for example -[详细]
2023-04-07 09:57 分类:问答accessing first n variadic function arguments
I have the following code : template<size_t sz,typename T=float> class Vec{ T v[sz]; Vec(const T& val,const T&... nv){[详细]
2023-04-07 07:46 分类:问答point from n3290 :alignment
A point from ISO standard n3290 draft ,Section 3.11:Alignment : 1st point Object types have alignment requirements (3.9.1, 3.9.2) which place restrictions on[详细]
2023-04-07 06:05 分类:问答