================ @@ -84,22 +88,33 @@ inline bool isUniqueGVALinkage(GVALinkage L) { } inline bool isExternallyVisible(Linkage L) { - return L >= VisibleNoLinkage; + switch (L) { + case Linkage::Invalid: + llvm_unreachable("Linkage hasn't been computed!"); ---------------- Endilll wrote:
@AaronBallman I sprinkled a lot of `llvm_unreachable` in this patch, following an example I've seen in one of the switches on `Linkage`. Let me know if you'd like this to be handled in a different way. https://github.com/llvm/llvm-project/pull/71049 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits