[PATCH] D75542: [Sema] Prevent UB for uninitialized `IsSurrogate`

Brian Gesiak via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Mar 3 10:21:14 PST 2020


modocache marked an inline comment as done.
modocache added inline comments.


================
Comment at: clang/lib/Sema/SemaOverload.cpp:7371
     return;
   }
 
----------------
@rsmith I'd definitely appreciate any pointers here -- if initializing `IsSurrogate` with a value as I do in this patch is the kind of change that doesn't "need" an explicit test, then great. But if a test is in order, I'd be happy to write one, but I'm not certain this `if` statement (and the one whose body statement I modify above) is being tested. Even commenting it out entirely still has `check-clang` passing for me. I'd greatly appreciate advice on how to exercise this code path in a Clang regression test.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D75542/new/

https://reviews.llvm.org/D75542





More information about the cfe-commits mailing list