mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-04 04:40:56 -06:00
string: Add new HEX sub-command
This commit is contained in:
@@ -36,6 +36,7 @@ Synopsis
|
||||
|
||||
`Generation`_
|
||||
string(`ASCII`_ <number>... <out-var>)
|
||||
string(`HEX`_ <string> <out-var>)
|
||||
string(`CONFIGURE`_ <string> <out-var> [...])
|
||||
string(`MAKE_C_IDENTIFIER`_ <string> <out-var>)
|
||||
string(`RANDOM`_ [<option>...] <out-var>)
|
||||
@@ -355,6 +356,16 @@ Generation
|
||||
|
||||
Convert all numbers into corresponding ASCII characters.
|
||||
|
||||
.. _HEX:
|
||||
|
||||
.. code-block:: cmake
|
||||
|
||||
string(HEX <string> <output_variable>)
|
||||
|
||||
Convert each byte in the input ``<string>`` to its hexadecimal representation
|
||||
and store the concatenated hex digits in the ``<output_variable>``. Letters in
|
||||
the output (``a`` through ``f``) are in lowercase.
|
||||
|
||||
.. _CONFIGURE:
|
||||
|
||||
.. code-block:: cmake
|
||||
|
||||
Reference in New Issue
Block a user