[clang] [clang] Be const-correct with all uses of `Module *`. (PR #93493)

David Stone via cfe-commits cfe-commits at lists.llvm.org
Tue May 28 13:34:58 PDT 2024


================
@@ -817,11 +817,11 @@ class alignas(8) Decl {
            "owned local decl but no local module storage");
     return reinterpret_cast<Module *const *>(this)[-1];
   }
-  void setLocalOwningModule(Module *M) {
+  void setLocalOwningModule(const Module *M) {
----------------
davidstone wrote:

Hmm yes I should have been more careful around that `reinterpret_cast`.

https://github.com/llvm/llvm-project/pull/93493


More information about the cfe-commits mailing list