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:
a2fa271
)
Add a trivial functor for use with unique_ptrs managing memory that needs to be freed...
author
David Blaikie
<dblaikie@gmail.com>
Fri, 29 Aug 2014 22:05:31 +0000
(22:05 +0000)
committer
David Blaikie
<dblaikie@gmail.com>
Fri, 29 Aug 2014 22:05:31 +0000
(22:05 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@216790
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
1cef393
..
f69a15b
100644
(file)
--- a/
include/llvm/ADT/STLExtras.h
+++ b/
include/llvm/ADT/STLExtras.h
@@
-530,6
+530,12
@@
make_unique(size_t n) {
#endif
+struct FreeDeleter {
+ void operator()(void* v) {
+ ::free(v);
+ }
+};
+
template<typename First, typename Second>
struct pair_hash {
size_t operator()(const std::pair<First, Second> &P) const {