Skip to content

Commit 2acd1d6

Browse files
committed
Drop uint 256 not operator
All the other operators are integer or bit operations, and this is unused apart from tests.
1 parent 0de7cc8 commit 2acd1d6

File tree

2 files changed

+0
-15
lines changed

2 files changed

+0
-15
lines changed

src/arith_uint256.h

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -64,14 +64,6 @@ class base_uint
6464

6565
explicit base_uint(const std::string& str);
6666

67-
bool operator!() const
68-
{
69-
for (int i = 0; i < WIDTH; i++)
70-
if (pn[i] != 0)
71-
return false;
72-
return true;
73-
}
74-
7567
const base_uint operator~() const
7668
{
7769
base_uint ret;

src/test/arith_uint256_tests.cpp

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -198,13 +198,6 @@ BOOST_AUTO_TEST_CASE( shifts ) { // "<<" ">>" "<<=" ">>="
198198

199199
BOOST_AUTO_TEST_CASE( unaryOperators ) // ! ~ -
200200
{
201-
BOOST_CHECK(!ZeroL);
202-
BOOST_CHECK(!(!OneL));
203-
for (unsigned int i = 0; i < 256; ++i)
204-
BOOST_CHECK(!(!(OneL<<i)));
205-
BOOST_CHECK(!(!R1L));
206-
BOOST_CHECK(!(!MaxL));
207-
208201
BOOST_CHECK(~ZeroL == MaxL);
209202

210203
unsigned char TmpArray[32];

0 commit comments

Comments
 (0)