diff options
author | Ted Kremenek <kremenek@apple.com> | 2008-01-28 22:05:23 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2008-01-28 22:05:23 +0000 |
commit | 7afe973add96f7b189b018239b5b9e43fe4a8dcf (patch) | |
tree | 143c2b2851fc1561ee387670e9db445e338b7e20 | |
parent | 42f6e455de71099d12d30dc928748147bfc8f801 (diff) |
Added destructor for template class FoldingSetNodeWrapper.
Added getValue() to FoldingSetNodeWrapper.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46465 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | include/llvm/ADT/FoldingSet.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/llvm/ADT/FoldingSet.h b/include/llvm/ADT/FoldingSet.h index 112d86c5f6..bfbf99c269 100644 --- a/include/llvm/ADT/FoldingSet.h +++ b/include/llvm/ADT/FoldingSet.h @@ -329,7 +329,7 @@ class FoldingSetNodeWrapper : public FoldingSetNode { T data; public: FoldingSetNodeWrapper(const T& x) : data(x) {} - virtual ~FoldingSetNodeWrapper(); + virtual ~FoldingSetNodeWrapper() {} template<typename A1> explicit FoldingSetNodeWrapper(const A1& a1) @@ -356,6 +356,9 @@ public: void Profile(FoldingSetNodeID& ID) { FoldingSetTrait<T>::Profile(data, ID); } + T& getValue() { return data; } + const T& getValue() const { return data; } + operator T&() { return data; } operator const T&() const { return data; } }; |