Description:
Discussion about C++ language, library, standards. (Moderated)
|
|
|
What's wrong with this picture?
   
|
| |
Below is a copy of reference implementation from "Improved min/max" proposal for upcoming C++0x standard library ([link] JTC1/SC22/WG21/docs/papers/200 7/n2199.html). Anyone else thinks that something must be wrong with a language if this is how min/max has to be implemented? namespace detail... more »
|
|
comp.std.c++ report for Tue Jan 1 00:05:01 EST 2008
|
| |
...Newsgroups: comp.std.c++ ...This is an automated report about activity of our newsgroup comp.std.c++. It covers period between the previous report and the current one, ending on Tue Jan 1 00:05:01 EST 2008. Reports are normally issued monthly. Approved: 276 messages (of them, 0 automatically)... more »
|
|
Missing ";" in the for statement Grammar
|
| |
In ISO/IEC 14882:2003, 6.5/1 iteration-statement: while ( condition ) statement do statement while ( expression ) ; for ( for-init-statement _;_ conditionopt ; expressionopt ) statement ^^^ I found out it remained repaired in N2369. --- [ comp.std.c++ is moderated. To submit articles, try just posting with ]... more »
|
|
Typos in [atomics]?
|
| |
Hi Everybody, in the latest publicly available draft, paper N2641, in section [atomics.types.generic], the following specialization of the template atomic<> is provided for pointers: template <class T> struct atomic<T*> : atomic_address { T* fetch_add(ptrdiff_t, memory_order = memory_order_seq_cst) volatile;... more »
|
|
Formal proposal: forward declaration of enumerations
   
|
| |
HI Everybody, after some positive feedback on the subject, I have prepared a formal proposal to add the possibility to forward declare (aka declare but not define) an enumeration when the underlying type is specified. This is obtained by extending the syntax already introduced by paper N2347 (Strongly typed enums). You can find the proposal here:... more »
|
|
Extension methods c++0x
|
| |
Hello. I've been reading c++0x proposals and I'd like to see a proposal for c#-like extension methods. Extension methods let programmers write new methods and use it as if they were class methods from outside the class. I know it's sintactic sugar, but it makes code far more readable. As an example:... more »
|
|
why is operator+=() allowed to be non-member function also ?
|
| |
I am asking this question for learning purpose only. I will not use operator+=() as non-member. Consider the following program: ...using namespace std; class Test { public: Test(int arg = 10); int val; ...Test::Test(int arg) : val(arg) { cout << "one arg ctor called" << endl; ...Test operator+=(Test lhs, Test rhs)... more »
|
|
std::Range in STL algorithms
|
| |
Hi, Is C++0x going to provide STL algorithm overloads for std::Range concept? &rzej --- [ comp.std.c++ is moderated. To submit articles, try just posting with ] [ your news-reader. If that fails, use mailto:std-...@ncar.ucar.edu ] [ --- Please see the FAQ before posting. --- ]... more »
|
|
|