I would love a feature that behaves like SQL table delete cascades but for code. So if I delete a function, a high-level API ingress declaration, etc. then Cursor could trace back and ask me if I want to delete all of the related code (or even models) that were used by that code exclusively and are now stranded and unused.
In relation to the above would be awesome to have a tool for finding unused code in general to clean it all up.