binpac: Fix a large number of clang-tidy warnings

This commit is contained in:
Tim Wojtulewicz 2025-08-21 15:05:42 +00:00
parent 4dc546f8c8
commit 31b65f70da
48 changed files with 231 additions and 193 deletions

View file

@ -1,8 +1,8 @@
// See the file "COPYING" in the main distribution directory for copyright.
#include <stdio.h>
#include <stdlib.h>
#include <string.h> // for memcpy
#include <cstdio>
#include <cstdlib>
#include <cstring> // for memcpy
#define binpac_regex_h
@ -82,7 +82,7 @@ void FlowBuffer::ResetLineState() {
case CR_OR_LF: state_ = CR_OR_LF_0; break;
case STRICT_CRLF: state_ = STRICT_CRLF_0; break;
case LINE_BREAKER: break; // Nothing to reset
default: BINPAC_ASSERT(0); break;
default: BINPAC_ASSERT(false); break;
}
}
@ -248,7 +248,7 @@ void FlowBuffer::MarkOrCopyLine() {
case CR_OR_LF: MarkOrCopyLine_CR_OR_LF(); break;
case STRICT_CRLF: MarkOrCopyLine_STRICT_CRLF(); break;
case LINE_BREAKER: MarkOrCopyLine_LINEBREAK(); break;
default: BINPAC_ASSERT(0); break;
default: BINPAC_ASSERT(false); break;
}
}