[clang] [PAC][clang] Define `PointerAuthQualifier` and `PointerAuthenticationMode` (PR #84384)

Daniil Kovalev via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 16 10:30:13 PDT 2024


================
@@ -2196,6 +2196,16 @@ class ASTContext : public RefCountedBase<ASTContext> {
     return getQualifiedType(type.getUnqualifiedType(), Qs);
   }
 
+  /// \brief Return a type with the given __ptrauth qualifier.
+  QualType getPointerAuthType(QualType Ty, PointerAuthQualifier PointerAuth) {
+    assert(!Ty.getPointerAuth());
+    assert(PointerAuth);
+
+    Qualifiers qs;
+    qs.setPointerAuth(PointerAuth);
+    return getQualifiedType(Ty, qs);
----------------
kovdan01 wrote:

Thanks, fixed naming here and in `static PointerAuthQualifier fromOpaqueValue(uint32_t Opaque)`, see cfb3afe19c698aaf41fb7b492503081989896434


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


More information about the cfe-commits mailing list