ishft(3I)

ISHFT - Performs a logical shift

As shipped in IRIX 6.5. First release of IRIX 6.5.

NAME
     ISHFT - Performs a logical shift

SYNOPSIS
     ISHFT ([I=]i, [SHIFT=]shift)

IMPLEMENTATION
     UNICOS, UNICOS/mk, and IRIX systems

STANDARDS
     Fortran 90

DESCRIPTION
     The ISHFT intrinsic function performs a logical shift.  It accepts the
     following arguments:

     i    Must be of type integer.

     shift
          Must be of type integer.  The absolute value of shift must be
          less than or equal to BIT_SIZE(i).

     ISHFT is an elemental function.  The name of this intrinsic cannot be
     passed as an argument.

RETURN VALUES
     The result type and type parameter are the same as i.  The result has
     the value obtained by shifting the bits of i by shift positions.  If
     shift is positive, the shift is to the left; if shift is negative, the
     shift is to the right; and if shift is zero, no shift is performed.
     Bits shifted out from the left or from the right, as appropriate, are
     lost.  Zeros are shifted in from the opposite end.  The bit model
     defines the interpretation of an integer value as a sequence of bits.
     For more information on the bit model, see the MODELS(3I) man page.

EXAMPLES
     ISHFT (3, 1) has the result 6.

SEE ALSO
     MODELS(3I)

     Intrinsic Procedures Reference Manual, publication SR-2138, for the
     printed version of this man page.