]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/fortran/doc/gfortran/intrinsic-procedures/ior.rst
sphinx: add missing trailing newline
[thirdparty/gcc.git] / gcc / fortran / doc / gfortran / intrinsic-procedures / ior.rst
CommitLineData
c63539ff
ML
1..
2 Copyright 1988-2022 Free Software Foundation, Inc.
3 This is part of the GCC manual.
4 For copying conditions, see the copyright.rst file.
5
6.. _ior:
7
8.. index:: IOR
9
10.. index:: BIOR
11
12.. index:: IIOR
13
14.. index:: JIOR
15
16.. index:: KIOR
17
18.. index:: bitwise logical or
19
20.. index:: logical or, bitwise
21
22IOR --- Bitwise logical or
23**************************
24
25.. function:: IOR()
26
27 ``IOR`` returns the bitwise Boolean inclusive-OR of :samp:`{I}` and
28 :samp:`{J}`.
29
30 :param I:
31 The type shall be ``INTEGER`` or a boz-literal-constant.
32
33 :param J:
34 The type shall be ``INTEGER`` with the same
35 kind type parameter as :samp:`{I}` or a boz-literal-constant.
36 :samp:`{I}` and :samp:`{J}` shall not both be boz-literal-constants.
37
38 :return:
39 The return type is ``INTEGER`` with the kind type parameter of the
40 arguments.
41 A boz-literal-constant is converted to an ``INTEGER`` with the kind
42 type parameter of the other argument as-if a call to :ref:`INT` occurred.
43
44 Standard:
45 Fortran 90 and later, with boz-literal-constant Fortran 2008 and later, has overloads that are GNU extensions
46
47 Class:
48 Elemental function
49
50 Syntax:
51 .. code-block:: fortran
52
53 RESULT = IOR(I, J)
54
55 Specific names:
56 .. list-table::
57 :header-rows: 1
58
59 * - Name
60 - Argument
61 - Return type
62 - Standard
63
64 * - ``IOR(A)``
65 - ``INTEGER A``
66 - ``INTEGER``
67 - Fortran 90 and later
68 * - ``BIOR(A)``
69 - ``INTEGER(1) A``
70 - ``INTEGER(1)``
71 - GNU extension
72 * - ``IIOR(A)``
73 - ``INTEGER(2) A``
74 - ``INTEGER(2)``
75 - GNU extension
76 * - ``JIOR(A)``
77 - ``INTEGER(4) A``
78 - ``INTEGER(4)``
79 - GNU extension
80 * - ``KIOR(A)``
81 - ``INTEGER(8) A``
82 - ``INTEGER(8)``
83 - GNU extension
84
85 See also:
86 :ref:`IEOR`,
87 :ref:`IAND`,
88 :ref:`IBITS`,
89 :ref:`IBSET`,
90 :ref:`IBCLR`,
3ed1b4ce 91 :ref:`NOT`