OSDN Git Service
(root)
/
android-x86
/
external-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5489d32
)
ADT: Add a range-based version of std::copy
author
David Blaikie
<dblaikie@gmail.com>
Tue, 9 Jan 2018 22:13:56 +0000
(22:13 +0000)
committer
David Blaikie
<dblaikie@gmail.com>
Tue, 9 Jan 2018 22:13:56 +0000
(22:13 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@322127
91177308
-0d34-0410-b5e6-
96231b3b80d8
include/llvm/ADT/STLExtras.h
patch
|
blob
|
history
diff --git
a/include/llvm/ADT/STLExtras.h
b/include/llvm/ADT/STLExtras.h
index
bcd992b
..
64badfd
100644
(file)
--- a/
include/llvm/ADT/STLExtras.h
+++ b/
include/llvm/ADT/STLExtras.h
@@
-861,6
+861,11
@@
OutputIt copy_if(R &&Range, OutputIt Out, UnaryPredicate P) {
return std::copy_if(adl_begin(Range), adl_end(Range), Out, P);
}
+template <typename R, typename OutputIt>
+OutputIt copy(R &&Range, OutputIt Out) {
+ return std::copy(adl_begin(Range), adl_end(Range), Out);
+}
+
/// Wrapper function around std::find to detect if an element exists
/// in a container.
template <typename R, typename E>