================
@@ -592,6 +592,36 @@ The result value is never zero and always within range for 
both the
 
 This can be used in constant expressions.
 
+``ptrauth_type_discriminator``
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+.. code-block:: c
+
+  ptrauth_type_discriminator(type)
+
+Compute the constant discriminator derived from the given type, as is computed
+for automatically type diversified schemas.
+
+``type`` must be a type. The result has the type ``ptrauth_extra_data_t``.
+
+This can be used in constant expressions.
+
+``ptrauth_function_pointer_type_discriminator``
----------------
kovdan01 wrote:

Nit: maybe `ptrauth_function_pointer_discriminator` (w/o type) would suite 
better here? We either have a type-based discriminator if the feature is 
requested or just have zero, so it might be better to call the macro just 
`ptrauth_function_pointer_discriminator` w/o making the user think that it's a 
type discriminator.

Totally optional and feel free to ignore.

https://github.com/llvm/llvm-project/pull/163456
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to