andykaylor wrote: @HendrikHuebner Now that we've introduced `std::optional` returns as you had proposed here, can you rebase this PR to use that mechanism? https://github.com/llvm/llvm-project/pull/168051