aboutsummaryrefslogtreecommitdiff
path: root/src/test/fuzz/script_assets_test_minimizer.cpp
diff options
context:
space:
mode:
authorSebastian Falbesoner <sebastian.falbesoner@gmail.com>2021-09-11 13:02:47 +0200
committerSebastian Falbesoner <sebastian.falbesoner@gmail.com>2022-04-11 22:19:46 +0200
commit9cc8e876e412056ed22d364538f0da3d5d71946d (patch)
treecf30bf1d489e1bd7a37274deedf06fe60fb175b4 /src/test/fuzz/script_assets_test_minimizer.cpp
parent2b5a741e98f186e50d9fbe1ceadcc8b8c91547f7 (diff)
refactor: introduce single-separator split helper `SplitString`
This helper uses spanparsing::Split internally and enables to replace all calls to boost::split where only a single separator is passed. Co-authored-by: Martin Ankerl <Martin.Ankerl@gmail.com> Co-authored-by: MarcoFalke <falke.marco@gmail.com>
Diffstat (limited to 'src/test/fuzz/script_assets_test_minimizer.cpp')
-rw-r--r--src/test/fuzz/script_assets_test_minimizer.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/test/fuzz/script_assets_test_minimizer.cpp b/src/test/fuzz/script_assets_test_minimizer.cpp
index 00a3bed12f..a18a0de47e 100644
--- a/src/test/fuzz/script_assets_test_minimizer.cpp
+++ b/src/test/fuzz/script_assets_test_minimizer.cpp
@@ -11,8 +11,8 @@
#include <streams.h>
#include <univalue.h>
#include <util/strencodings.h>
+#include <util/string.h>
-#include <boost/algorithm/string.hpp>
#include <cstdint>
#include <string>
#include <vector>
@@ -130,8 +130,7 @@ unsigned int ParseScriptFlags(const std::string& str)
if (str.empty()) return 0;
unsigned int flags = 0;
- std::vector<std::string> words;
- boost::algorithm::split(words, str, boost::algorithm::is_any_of(","));
+ std::vector<std::string> words = SplitString(str, ',');
for (const std::string& word : words) {
auto it = FLAG_NAMES.find(word);