diff options
| author | Matt Corallo <[email protected]> | 2012-08-13 05:26:25 +0200 |
|---|---|---|
| committer | Matt Corallo <[email protected]> | 2013-01-16 12:48:01 -0500 |
| commit | 68feac96b67b80a4fe59c4f349b58af9c77e2709 (patch) | |
| tree | 70e96ef040904ba159a3b61accf0fd310e76ace4 /src | |
| parent | Fix clang warnings (diff) | |
| download | discoin-68feac96b67b80a4fe59c4f349b58af9c77e2709.tar.xz discoin-68feac96b67b80a4fe59c4f349b58af9c77e2709.zip | |
Add const versions of base_uint.end()/begin(), make size() const.
Diffstat (limited to 'src')
| -rw-r--r-- | src/uint256.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/uint256.h b/src/uint256.h index abd0b71e6..eb0066fa2 100644 --- a/src/uint256.h +++ b/src/uint256.h @@ -344,7 +344,17 @@ public: return (unsigned char*)&pn[WIDTH]; } - unsigned int size() + const unsigned char* begin() const + { + return (unsigned char*)&pn[0]; + } + + const unsigned char* end() const + { + return (unsigned char*)&pn[WIDTH]; + } + + unsigned int size() const { return sizeof(pn); } |