Bit_ Derived Type

type, public :: Bit_

This is a derived type for a bit array.


Components

Type Visibility Attributes Name Initial
logical, public, allocatable :: bitArray(:)

Type-Bound Procedures

procedure, public :: init => initBit

It is a constructor of a bit array

  • public subroutine initBit(obj, n)

    Arguments

    Type IntentOptional Attributes Name
    class(Bit_), intent(inout) :: obj
    integer(kind=int32), intent(in) :: n

procedure, public :: int => intBit

It converts bit array into a int value.

  • public function intBit(obj) result(ret)

    Arguments

    Type IntentOptional Attributes Name
    class(Bit_), intent(inout) :: obj

    Return Value integer(kind=int32)

procedure, public :: not => notBit

It converts NOT operation for all bits in a bit array.

  • public subroutine notBit(obj)

    Arguments

    Type IntentOptional Attributes Name
    class(Bit_), intent(inout) :: obj