Added destructor for template class FoldingSetNodeWrapper.
authorTed Kremenek <kremenek@apple.com>
Mon, 28 Jan 2008 22:05:23 +0000 (22:05 +0000)
committerTed Kremenek <kremenek@apple.com>
Mon, 28 Jan 2008 22:05:23 +0000 (22:05 +0000)
Added getValue() to FoldingSetNodeWrapper.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46465 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/ADT/FoldingSet.h

index 112d86c5f647ce3335eaad2d6f0a7e8844828818..bfbf99c269b1aea8e1cd884bfad57943395677fc 100644 (file)
@@ -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; }
 };