aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPieter Wuille <pieter@wuille.net>2020-06-18 14:12:54 -0700
committerPieter Wuille <pieter@wuille.net>2020-07-30 13:57:09 -0700
commit567825049fb0e47e698dcaad9caa65693a6b42d3 (patch)
tree889f4e6b9b100ea324e1aa3a58ba2a7e759a26f3 /src
parent131a2f0337f5c396739a47b60bb856ed84ec8937 (diff)
Make uint256 Span-convertible by adding ::data()
Diffstat (limited to 'src')
-rw-r--r--src/uint256.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/uint256.h b/src/uint256.h
index 0e0473a300..8ab747ef49 100644
--- a/src/uint256.h
+++ b/src/uint256.h
@@ -51,6 +51,9 @@ public:
void SetHex(const std::string& str);
std::string ToString() const;
+ const unsigned char* data() const { return m_data; }
+ unsigned char* data() { return m_data; }
+
unsigned char* begin()
{
return &m_data[0];