       (error "%s does not contain Geiser!" dir))
     (geiser-unload)
     (setq load-path (remove geiser-elisp-dir load-path))
+    (setq geiser-impl-installed-implementations installed-impls)
     (load-file geiser-main-file)
-    (geiser-setup)
-    (dolist (feature (reverse (geiser--features-list)))
+    (dolist (feature (geiser--features-list))
       (load-library (format "%s" feature)))
     (geiser-impl--reload-implementations impls)
     (geiser-repl--restore repls)

                                                geiser-root-dir))
                  geiser-root-dir))
         (geiser-main-file (expand-file-name "elisp/geiser.el" dir))
         (impls (and (featurep 'geiser-impl) geiser-impl--impls))
         (repls (and (featurep 'geiser-repl) (geiser-repl--repl-list)))
         (buffers (and (featurep 'geiser-mode) (geiser-mode--buffers))))

        geiser-faces
        geiser-mode
        geiser-guile
        geiser-plt
        geiser-impl
        geiser-xref))


;;; Scheme mode setup:

(defsubst geiser-impl--impl-feature (impl)
  (intern (format "geiser-%s" impl)))

(defun geiser-setup ()
  (eval-after-load "scheme"
    '(add-hook 'scheme-mode-hook 'turn-on-geiser-mode))
  (mapc (lambda (impl)
          (require (geiser-impl--impl-feature impl) nil t))
        (or geiser-impl-installed-implementations
            '(guile plt))))


