Skip to content

Commit 2dd3568

Browse files
A few things before the point release.
1 parent 80c0557 commit 2dd3568

File tree

3 files changed

+11
-5
lines changed

3 files changed

+11
-5
lines changed

doc/array.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -369,6 +369,12 @@ Rule 4 ``'float16'`` ``-=`` ``'bfloat'`` → ``'float1
369369
Comparison operators
370370
""""""""""""""""""""
371371

372+
Comparison operators can operate between two ``Array`` objects, or between an ``Array`` and a scalar quantity (usually a number).
373+
374+
Note that they always produce an ``Array`` of :attr:`~Array.dtype` ``'bool'``, including the equality and inequality operators.
375+
376+
To test the boolean equality of two Arrays use the :meth:`~Array.equals` method instead.
377+
372378
.. method:: Array.__eq__(self, other: int | float | str | BitsType | Array) -> Array
373379

374380
``a1 == a2``

doc/index.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ Arrays of bitstrings
9595
^^^^^^^^^^^^^^^^^^^^
9696

9797
.. note ::
98-
This class was introduced in version 4.1.0 of bitstring, and is a 'beta' feature that may have some small changes in future point releases.
98+
This class was introduced in version 4.1 of bitstring, and is a 'beta' feature that may have some small changes in future point releases.
9999
100100
If you are dealing with just one type of data but perhaps it's not one of the dozen or so supported in the ``array`` module in the standard library, then we have you covered with the :class:`Array` class.
101101

@@ -109,7 +109,7 @@ You can also easily change the data's interpretation, convert to another format,
109109
>>> a = bitstring.Array('uint16', [0, 1, 4, 6, 11, 2, 8, 7])
110110
>>> a.data
111111
BitArray('0x0000000100040006000b000200080007')
112-
>>> b = bitstring.Array('int5', a.tolist())
112+
>>> b = a.astype('uint5')
113113
>>> b.data
114114
BitArray('0x0048658907')
115115
>>> a.tolist() == b.tolist()

release_notes.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
bitstring module version history
33
--------------------------------
44

5-
-----------------------------------
6-
In development: version 4.1.2
7-
-----------------------------------
5+
--------------------------------------
6+
September 2023: version 4.1.2 released
7+
--------------------------------------
88
Another maintenance release. Once again some small changes to the 'beta' Array class,
99
plus new Array functionality.
1010

0 commit comments

Comments
 (0)