projects
/
folly.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cf05856
)
Delete operator=(std::string&&) from StringPiece
author
Christopher Dykes
<cdykes@fb.com>
Fri, 5 May 2017 01:32:45 +0000
(18:32 -0700)
committer
Facebook Github Bot
<facebook-github-bot@users.noreply.github.com>
Fri, 5 May 2017 01:35:15 +0000
(18:35 -0700)
Summary: This can only ever be used unsafely, so delete it.
Reviewed By: yfeldblum
Differential Revision:
D4951294
fbshipit-source-id:
bbc266d1550fceb48946c7c48e76af07292b4a53
folly/Range.h
patch
|
blob
|
history
diff --git
a/folly/Range.h
b/folly/Range.h
index 9c9b68b26514712568ab2d1579dbdc5e63beeee3..9e392cf42de4f20b35e610fd0cfdd846d89d2e51 100644
(file)
--- a/
folly/Range.h
+++ b/
folly/Range.h
@@
-359,6
+359,9
@@
public:
Range& operator=(const Range& rhs) & = default;
Range& operator=(Range&& rhs) & = default;
+ template <class T = Iter, typename detail::IsCharPointer<T>::const_type = 0>
+ Range& operator=(std::string&& rhs) = delete;
+
void clear() {
b_ = Iter();
e_ = Iter();