Subject: bug#78087: 31.0.50; [FR] Add hook for reacting to buffer trust changes

From: Eshel Yaron <[email-masked]>
Date: Sun, 27 Apr 2025 12:17:32 +0200

Hi,

It'd be great to have a hook executed when a buffer becomes (un)trusted.
For example, that'd allow us to enable a previously disabled
elisp-flymake-byte-compile when users mark a buffer as trusted.  WDYT?

(One way to do that, which I'm experimenting with in my Emacs branch, is
to hide trusted-content behind API functions that take care to run such
a hook for buffers that may be affected by changes to trust settings.)

Thanks,

Eshel