BTW, it's really nice that you include how you tested the change, thanks for that!
Thanks! I find it's helpful in general when making PRs that are moderately complex because it forces me to…
Minor naming comments, otherwise looks good.
I think the cached_
prefix is maybe unnecessary given that the entire struct is named Cache
Changing this particular file affects a number of modes, not just Sculpt, was this tested against Vertex / Weight / GP / etc to make sure that we didn't cause regressions on the user-side?
I get that we have to do this here because the issue is that the brush isn't updated until stroke->test_start
, but that entire process seems a bit odd. It seems like we might want a separate initialization step that we can call so that the brush is initialized earlier?