File tree Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Original file line number Diff line number Diff line change 12
12
13
13
namespace {
14
14
15
- /* * Pop the first byte from a Span<const uint8_t> , and return it. */
16
- uint8_t ReadByte (Span< const uint8_t > & buffer)
15
+ /* * Pop the first byte from a byte-span , and return it. */
16
+ uint8_t ReadByte (FuzzBufferType & buffer)
17
17
{
18
18
if (buffer.empty ()) return 0 ;
19
19
uint8_t ret = buffer.front ();
@@ -23,7 +23,7 @@ uint8_t ReadByte(Span<const uint8_t>& buffer)
23
23
24
24
/* * Perform a simulation fuzz test on BitSet type S. */
25
25
template <typename S>
26
- void TestType (Span< const uint8_t > buffer)
26
+ void TestType (FuzzBufferType buffer)
27
27
{
28
28
/* * This fuzz test's design is based on the assumption that the actual bits stored in the
29
29
* bitsets and their simulations do not matter for the purpose of detecting edge cases, thus
Original file line number Diff line number Diff line change 5
5
#ifndef BITCOIN_TEST_FUZZ_FUZZ_H
6
6
#define BITCOIN_TEST_FUZZ_FUZZ_H
7
7
8
- #include < span.h>
9
-
10
8
#include < cstdint>
11
9
#include < functional>
10
+ #include < span>
12
11
#include < string_view>
13
12
14
13
/* *
23
22
#define LIMITED_WHILE (condition, limit ) \
24
23
for (unsigned _count{limit}; (condition) && _count; --_count)
25
24
26
- using FuzzBufferType = Span <const uint8_t >;
25
+ using FuzzBufferType = std::span <const uint8_t >;
27
26
28
27
using TypeTestOneInput = std::function<void (FuzzBufferType)>;
29
28
struct FuzzTargetOptions {
You can’t perform that action at this time.
0 commit comments