script: remove unused SCRIPT_ERR_LAST
What changed, and why it matters
This commit removes an unused macro named SCRIPT_ERR_LAST from a Bitcoin Core header file. The macro was simply another name for an existing internal counter and was not referenced anywhere in the code. There is no functional change, no bug fix, and no security relevance.
No action required. This is a non-functional code cleanup commit with no security implications.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The patch deletes the line ‘#define SCRIPT_ERR_LAST SCRIPT_ERR_ERROR_COUNT’ from src/script/script_error.h. The commit message states the macro was never used and the only call site uses SCRIPT_ERR_ERROR_COUNT directly. The diff confirms the removal is a pure cleanup with no callers modified and no behavior change.
Changed components
src/script/script_error.hInspect captured patch +0 / −2
diff --git a/src/script/script_error.h b/src/script/script_error.h
index 58ac7db5..7aec1020 100644
--- a/src/script/script_error.h
+++ b/src/script/script_error.h
@@ -86,8 +86,6 @@ typedef enum ScriptError_t
SCRIPT_ERR_ERROR_COUNT
} ScriptError;
-#define SCRIPT_ERR_LAST SCRIPT_ERR_ERROR_COUNT
-
std::string ScriptErrorString(ScriptError error);
#endif // BITCOIN_SCRIPT_SCRIPT_ERROR_H
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.