Revert "Revert "Fix relocation to look for symbols in local group""

This reverts commit 00dce525530c5d26c20750863f3e9890b468787a.
diff --git a/linker/linked_list.h b/linker/linked_list.h
index 4e62e20..72a32b4 100644
--- a/linker/linked_list.h
+++ b/linker/linked_list.h
@@ -86,7 +86,7 @@
   }
 
   template<typename F>
-  void for_each(F action) {
+  void for_each(F action) const {
     visit([&] (T* si) {
       action(si);
       return true;
@@ -94,7 +94,7 @@
   }
 
   template<typename F>
-  bool visit(F action) {
+  bool visit(F action) const {
     for (LinkedListEntry<T>* e = head_; e != nullptr; e = e->next) {
       if (!action(e->element)) {
         return false;