Subject: bug#33695: 27.0.50; which-function reports wrong imenu information

From: martin rudalics <[email-masked]>
Date: Tue, 11 Dec 2018 09:35:08 +0100

> - Have `which-function' update `imenu--index-alist' before checking it
 >    (also easy to implement, but updating the index could be slow in large
 >    buffers)

Maybe we should try to do what 'imenu-update-menubar' does here:
Compare the values of 'imenu-menubar-modified-tick' and
'buffer-chars-modified-tick' and update 'imenu--index-alist' if they
differ.

martin