In fact, I think the (require 'edebug) in which-func.el is leftover code. I didn't realize that Lars had in fact reverted that patch, sort of.

In 55cc8b040b (2022-08-08), he modified lisp-mode.el (mentioned in the commit log), and also which-func.el and lisp-mode-tests.el (these are not mentioned).

And then, in 48b0f2606b (2022-08-23), he removed just the changes to lisp-mode.el, but he left the new tests and the change in which-func.el.

His reverting lisp-mode.el left behind a few little changes, but he removed all references to edebug-form-spec
, so there's no point now to the one-line change to which-func.el and it should be reverted too, I think.