Skip to content

Commit 5e0ea2e

Browse files
committed
Document ptrauth_string_discriminator in clang/docs/PointerAuthentication.
1 parent 61be7a9 commit 5e0ea2e

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

clang/docs/PointerAuthentication.rst

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -328,6 +328,21 @@ be done in a single instruction with an immediate integer.
328328
``pointer`` must have pointer type, and ``integer`` must have integer type. The
329329
result has type ``ptrauth_extra_data_t``.
330330

331+
``ptrauth_string_discriminator``
332+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
333+
334+
.. code-block:: c
335+
336+
ptrauth_string_discriminator(string)
337+
338+
Produce a discriminator value for the given string. ``string`` must be
339+
a string literal of ``char`` character type. The result has type
340+
``ptrauth_extra_data_t``.
341+
342+
The result is always a constant expression. The result value is never zero and
343+
always within range for both the ``__ptrauth`` qualifier and
344+
``ptrauth_blend_discriminator``.
345+
331346
``ptrauth_strip``
332347
^^^^^^^^^^^^^^^^^
333348

0 commit comments

Comments
 (0)