[PATCH] cpp11-migrate: Add a transform that use pass-by-value in constructors

Edwin Vane edwin.vane at intel.com
Tue Aug 27 07:12:48 PDT 2013


  Don't worry about the blurb on templates now. Now that the behaviour with args that are not template args has been found to work fine no need to talk about the case that obviously shouldn't work.

  One, hopefully last, request: can you add a test where the constructor has multiple args, >1 to be transformed and >=1 that stay the same?


================
Comment at: test/cpp11-migrate/PassByValue/basic.cpp:148
@@ +147,3 @@
+template <typename T> struct P {
+  P(const Movable M) : M(M) {}
+  // CHECK: P(Movable M) : M(std::move(M)) {}
----------------
This is really weird but good that you handle it.


http://llvm-reviews.chandlerc.com/D1342

BRANCH
  pass-by-value

ARCANIST PROJECT
  clang-tools-extra



More information about the cfe-commits mailing list