Next: MIN, Previous: MERGE, Up: Intrinsic Procedures [Contents][Index]
MERGE_BITS
— Merge of bits under maskMERGE_BITS(I, J, MASK)
merges the bits of I and J
as determined by the mask. The i-th bit of the result is equal to the
i-th bit of I if the i-th bit of MASK is 1; it is equal to
the i-th bit of J otherwise.
Fortran 2008 and later
Elemental function
RESULT = MERGE_BITS(I, J, MASK)
I | Shall be of type INTEGER or a boz-literal-constant. |
J | Shall be of type INTEGER with the same
kind type parameter as I or a boz-literal-constant.
I and J shall not both be boz-literal-constants. |
MASK | Shall be of type INTEGER or a boz-literal-constant
and of the same kind as I. |
The result is of the same type and kind as I.