This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [profile-stdlib] PATCH: Add three diagnostics and implement cost factor parameterization


Hi Changee,

Some initial comments, I'll take another look later.

I noticed a few formatting issues in
libstdc++-v3/include/profile/iterator_tracker.h - overlong lines, and
"public:" indented incorrectly.

The doxygen comment for profile/algorithm says:
/** @file parallel/algorithm

This include guard is not in the correct format:
#ifndef PROFCXX_PROFILER_LIST_TO_SLIST_H
That could clash with a user header (I don't like the format used by
the other profile headers, with two trailing underscores, but that
seems to be the form used consistently.)

This is wrong:
+#ifdef __GXX_EXPERIMENTAL_CXX0X__
+      swap(vector&& __x)
+#else
       swap(vector& __x)
+#endif

vector::swap() does not work with rvalues now, the same goes for

+#ifdef __GXX_EXPERIMENTAL_CXX0X__
+  template<typename _Tp, typename _Alloc>
+    inline void
+    swap(vector<_Tp, _Alloc>&& __lhs, vector<_Tp, _Alloc>& __rhs)
+    { __lhs.swap(__rhs); }
+
+  template<typename _Tp, typename _Alloc>
+    inline void
+    swap(vector<_Tp, _Alloc>& __lhs, vector<_Tp, _Alloc>&& __rhs)
+    { __lhs.swap(__rhs); }
+#endif

Regards,
Jonathan


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]