[PATCH] D134544: [clang-cl] Implement /ZH: flag

Hans Wennborg via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Sep 23 22:35:10 PDT 2022


hans accepted this revision.
hans added a comment.
This revision is now accepted and ready to land.

lgtm



================
Comment at: clang/include/clang/Basic/CodeGenOptions.h:106
+  enum SrcHashAlgorithm {
+    CSK_MD5,
+    CSK_SHA1,
----------------
thakis wrote:
> hans wrote:
> > what does CSK stand for here?
> I'm guessing "check sum kind", but I don't know :)
> 
> `SHA_` looks a bit funny as prefix too...
> 
> I also don't love the cc1 flag name, but I figured it's a bit bikesheddy and it's internal only so i kept it as is.
> 
> If you have a preference for flag name, enum name, and enum prefix, let me know.
How about

`enum DebugSrcHashKind { DSH_MD5, ...`

("kind" seems a common suffix for these, "debug" is a nice hint about what area this applies to.)


================
Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:377
+  }
+  return CSKind;
 }
----------------
Perhaps it would be simpler to drop the CSKind variable and fold the return into the individual cases?


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

https://reviews.llvm.org/D134544



More information about the cfe-commits mailing list