Change lookup_symbol's block_index parameter type to block_enum
[external/binutils.git] / gdb / dcache.h
index 97ed536..a58ac84 100644 (file)
@@ -21,7 +21,7 @@
 #ifndef DCACHE_H
 #define DCACHE_H
 
-#include "target.h"
+#include "target.h"    /* for enum target_xfer_status */
 
 typedef struct dcache_struct DCACHE;
 
@@ -34,6 +34,15 @@ DCACHE *dcache_init (void);
 /* Free a DCACHE.  */
 void dcache_free (DCACHE *);
 
+/* A deletion adapter that calls dcache_free.  */
+struct dcache_deleter
+{
+  void operator() (DCACHE *d) const
+  {
+    dcache_free (d);
+  }
+};
+
 enum target_xfer_status
   dcache_read_memory_partial (struct target_ops *ops, DCACHE *dcache,
                              CORE_ADDR memaddr, gdb_byte *myaddr,