return bl->function ();
 }
 
-/* Return the symbol for the function which contains a specified
-   block, described by a struct block BL.  The return value will be
-   the closest enclosing function, which might be an inline
-   function.  */
+/* See block.h.  */
 
 struct symbol *
-block_containing_function (const struct block *bl)
+block::containing_function () const
 {
+  const block *bl = this;
+
   while (bl->function () == NULL && bl->superblock () != NULL)
     bl = bl->superblock ();
 
 
 
   struct symbol *linkage_function () const;
 
+  /* Return the symbol for the function which contains a specified
+     block, described by a struct block.  The return value will be the
+     closest enclosing function, which might be an inline
+     function.  */
+
+  struct symbol *containing_function () const;
+
   /* Addresses in the executable code that are in this block.  */
 
   CORE_ADDR m_start;
   struct block *m_blocks[1];
 };
 
-extern struct symbol *block_containing_function (const struct block *);
-
 /* Return true if block A is lexically nested within block B, or if a
    and b have the same pc range.  Return false otherwise.  If
    ALLOW_NESTED is true, then block A is considered to be in block B
 
   if (bl == nullptr)
     return nullptr;
 
-  return block_containing_function (bl);
+  return bl->containing_function ();
 }
 
 /* These variables are used to cache the most recent result of
 
        if (filter[i])
          {
            struct symbol *sym = (blocks[i]
-                                 ? block_containing_function (blocks[i])
+                                 ? blocks[i]->containing_function ()
                                  : NULL);
 
            if (self->funfirstline)