Skip to content

Commit

Permalink
Add SpanReader ignore method
Browse files Browse the repository at this point in the history
Needed to deserialize some types from spans like CScripts
  • Loading branch information
ryanofsky committed Dec 17, 2021
1 parent 0d5a918 commit bbb5c05
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/streams.h
Expand Up @@ -174,6 +174,11 @@ class SpanReader
memcpy(dst, m_data.data(), n);
m_data = m_data.subspan(n);
}

void ignore(size_t n)
{
m_data = m_data.subspan(n);
}
};

/** Double ended buffer combining vector and stream-like interfaces.
Expand Down

0 comments on commit bbb5c05

Please sign in to comment.