RFC: support custom rules to scrub ignored structs
The first 6 commits include some error fix and refactors, and they can land earlier.
The last commit is to invite for discussions.
The corresponding header updates:
- mesa: mesa/mesa!16568 (closed)
- virglrenderer: virglrenderer!807 (closed)