Files
archived-llvm/include/llvm/ADT
Jordan Rose d75c178408 Disallow StringRef assignment from temporary std::strings.
Similar to r283798, this prevents accidentally referring to temporary
storage that goes out of scope by the end of the statement:

  someStringRef = getStringByValue();
  someStringRef = (Twine("-") + otherString).str();

Note that once again the constructor still has this problem:

  StringRef someStringRef = getStringByValue();

because once again we occasionally rely on this in calls:

  takesStringRef(getStringByValue());
  takesStringRef(Twine("-") + otherString);

Still, it's a step.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286139 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-07 20:34:16 +00:00
..
2016-09-11 22:55:46 +00:00
2016-10-23 19:39:16 +00:00
2015-08-10 04:22:09 +00:00
2016-10-18 17:50:39 +00:00
2016-04-18 09:17:29 +00:00
2015-09-24 00:23:07 +00:00
2016-10-23 19:39:16 +00:00
2015-09-21 15:59:41 +00:00
2016-10-23 19:39:16 +00:00