As noted by @MarcoFalke in #18994 (review) the case can be made that at least some of the functions in our code base returning const char*
should return std::string
instead.
Candidates:
0$ git grep -E '^(static |inline |const |unsigned )*char *\*[^(<]*\(' ":(exclude)src/leveldb/" ":(exclude)src/univalue/" ":(exclude)src/serialize.h" ":(exclude)src/tinyformat.h"
1src/bitcoin-cli.cpp:static const char *http_errorstring(int code)
2src/script/script.cpp:const char* GetOpName(opcodetype opcode)
3src/script/script.h:const char* GetOpName(opcodetype opcode);
4src/script/script_error.cpp:const char* ScriptErrorString(const ScriptError serror)
5src/script/script_error.h:const char* ScriptErrorString(const ScriptError error);
6src/script/standard.cpp:const char* GetTxnOutputType(txnouttype t)
7src/script/standard.h:const char* GetTxnOutputType(txnouttype t);
8src/test/script_tests.cpp:static const char *FormatScriptError(ScriptError_t err)
Want to work on this issue?
The purpose of the good first issue
label is to highlight which issues are suitable for a new contributor without a deep understanding of the codebase.
You do not need to request permission to start working on this. You are encouraged to comment on the issue if you are planning to work on it. This will help other contributors monitor which issues are actively being addressed and is also an effective way to request assistance if and when you need it.
For guidance on contributing, please read CONTRIBUTING.md before opening your pull request.