<Example Program>

Program shiftr_example
    Integer,Parameter :: i8 = Selected_Int_Kind(2)
    Integer(i8) :: a(3) = [ Int(z'f0',i8),Int(z'70',i8),Int(z'0f',i8) ]
    Do i=0,3
        Print '(I3,3(2X,B8.8))',i,Shiftr(a,i)
    End Do
End Program

Note: Execution Results

  0  11110000  01110000  00001111
  1  01111000  00111000  00000111
  2  00111100  00011100  00000011
  3  00011110  00001110  00000001