https://github.com/ilya-biryukov approved this pull request. LGTM assuming the `getCurFunction()` comment is addressed in some form (moving it to callers or adding an assertion) Thanks for the change! https://github.com/llvm/llvm-project/pull/71945