       (if (not (eq cur-buffer (current-buffer)))
           (display-buffer (current-buffer) `(,go-coverage-display-buffer-func))))))
 
-(define-prefix-command 'go-goto-map)
-(define-key go-mode-map (kbd "C-c C-g") 'go-goto-map)
-
 (defun go-goto-function ()
   "Go to the function defintion above point.
 

      (when (looking-at "Test")
        (forward-char 4)))))

(define-key go-goto-map (kbd "f") 'go-goto-function-name)

(defun go-goto-arguments ()
  "Go to the return value declaration of the current function."
  (interactive)
  (go-goto-function-name)
  (forward-word 1)
  (forward-char 1))

(define-key go-goto-map (kbd "a") 'go-goto-arguments)

(defun go-goto-return-value ()
  "Go to the return value declaration of the current function.

    (newline)
    (insert (format "// %s " (go--get-function-name)))))

(defun go--get-function-name ()
  "Return the current function name as a string"
  (save-excursion
    (go-goto-function-name)
    (symbol-name (symbol-at-point))))

(define-prefix-command 'go-goto-map)
(define-key go-mode-map (kbd "C-c C-g") 'go-goto-map)

(define-key go-goto-map (kbd "a") 'go-goto-arguments)
(define-key go-goto-map (kbd "d") 'go-goto-docstring)
(define-key go-goto-map (kbd "f") 'go-goto-function-name)
(define-key go-goto-map (kbd "i") 'go-goto-imports)
(define-key go-goto-map (kbd "r") 'go-goto-return-value)
(define-key go-goto-map (kbd "t") 'go-goto-type-signature)

(provide 'go-mode)

;;; go-mode.el ends here
