merge_bits(3f) - [FORTRAN:INTRINSIC:BIT MANIPULATION] Merge of bits under mask
Syntax
Description
Arguments
Return Value
Standard
Class
result = merge_bits(i, j, mask)
merge_bits(i, j, mask) merges the bits of I and J as determined by the mask. The k-th bit of the result is equal to the k-th bit of I if the k-th bit of MASK is 1; it is equal to the k-th bit of J otherwise.
I - Shall be of type INTEGER. J - Shall be of type INTEGER and of the same kind as I. MASK - Shall be of type INTEGER and of the same kind as I.
The result is of the same type and kind as I.
[[Fortran 2008]] and later
[[Elemental function]]
merge_bits (3) | March 18, 2019 |