(define-key search-map "o" 'occur)
+(define-key search-map "b" 'occur-backward)
+(define-key search-map "f" 'occur-forward)
FWIW, I don't think those keys (`M-s b' and `M-s f') should be
bound to those commands. If we want to bind the new commands
during Isearch then I suggest that the occur commands be grouped
on prefix key `M-s o':
M-s oo occur
M-s ob occur-backward
M-s of occur-backward
`M-s' is a _general_ search prefix key. There is nothing
particularly mnemonic about `b' or `f' being `occur-backward'
or `occur-forward'. And we should not sacrifice 3 `M-s' keys
to these commands.
I, and perhaps other users, and perhaps in the future vanilla
Emacs, have other bindings on `M-s'. And `M-s' bindings can
be anything at all related to the encompassing context of
searching.