DSHIFTR — Combined right shift¶
- DSHIFTR(I, J, SHIFT)¶
DSHIFTR(I, J, SHIFT)
combines bits ofI
andJ
. The leftmostSHIFT
bits of the result are the rightmostSHIFT
bits ofI
, and the remaining bits are the leftmost bits ofJ
.- Parameters
I – Shall be of type
INTEGER
or a BOZ constant.J – Shall be of type
INTEGER
or a BOZ constant. If bothI
andJ
have integer type, then they shall have the same kind type parameter.I
andJ
shall not both be BOZ constants.SHIFT – Shall be of type
INTEGER
. It shall be nonnegative. IfI
is not a BOZ constant, thenSHIFT
shall be less than or equal toBIT_SIZE(I)
; otherwise,SHIFT
shall be less than or equal toBIT_SIZE(J)
.
- Returns
If either
I
orJ
is a BOZ constant, it is first converted as if by the intrinsic functionINT
to an integer type with the kind type parameter of the other.
Standard:
Fortran 2008 and later
Class:
Elemental function
Syntax:
RESULT = DSHIFTR(I, J, SHIFT)
See also:
DSHIFTL