Wrap long lines to fit within 80 columns across the codebase

Pure whitespace/line-break reformatting (braces, newlines, and line
continuations matching this codebase's existing wrap conventions) - no
logic, string content, or identifiers changed anywhere. Confirmed via
diff against the pre-change tree and by rebuilding + re-running the
affected test suites, which produce identical pass/fail results.

Co-Authored-By: Claude Sonnet 5 <[email protected]>
This commit is contained in:
2026-09-05 13:13:10 -05:00
co-authored by Claude Sonnet 5
parent de53bebeb8
commit cebd3d81e7
70 changed files with 1025 additions and 425 deletions
+26 -12
View File
@@ -100,8 +100,12 @@ static void test_memoryCopy(void **state) {
// Overlapping regions (should assert)
void *overlap = memoryAllocate(size * 2);
expect_assert_failure(memoryCopy((uint8_t*)overlap, (uint8_t*)overlap + 8, size));
expect_assert_failure(memoryCopy((uint8_t*)overlap + 8, (uint8_t*)overlap, size));
expect_assert_failure(
memoryCopy((uint8_t*)overlap, (uint8_t*)overlap + 8, size)
);
expect_assert_failure(
memoryCopy((uint8_t*)overlap + 8, (uint8_t*)overlap, size)
);
memoryFree(overlap);
memoryFree(src);
@@ -198,22 +202,32 @@ static void test_memoryCopyRangeSafe(void **state) {
assert_memory_equal(dest, src, size);
// Cannot copy to NULL destination
expect_assert_failure(memoryCopyRangeSafe(NULL, src, (uint8_t*)src + 5, size));
expect_assert_failure(
memoryCopyRangeSafe(NULL, src, (uint8_t*)src + 5, size)
);
// Cannot copy from NULL start
expect_assert_failure(memoryCopyRangeSafe(dest, NULL, (uint8_t*)src + 5, size));
expect_assert_failure(
memoryCopyRangeSafe(dest, NULL, (uint8_t*)src + 5, size)
);
// Cannot copy from NULL end
expect_assert_failure(memoryCopyRangeSafe(dest, (uint8_t*)src, NULL, size));
// Start and end are the same
expect_assert_failure(memoryCopyRangeSafe(dest, (uint8_t*)src, (uint8_t*)src, size));
expect_assert_failure(
memoryCopyRangeSafe(dest, (uint8_t*)src, (uint8_t*)src, size)
);
// End is before start
expect_assert_failure(memoryCopyRangeSafe(dest, (uint8_t*)src + 5, (uint8_t*)src + 2, size));
expect_assert_failure(
memoryCopyRangeSafe(dest, (uint8_t*)src + 5, (uint8_t*)src + 2, size)
);
// Size to copy exceeds maximum
expect_assert_failure(memoryCopyRangeSafe(dest, (uint8_t*)src, (uint8_t*)src + 10, 5));
expect_assert_failure(
memoryCopyRangeSafe(dest, (uint8_t*)src, (uint8_t*)src + 10, 5)
);
memoryFree(src);
memoryFree(dest);
+2 -1
View File
@@ -77,7 +77,8 @@ void testSortMethod(
int_t compareStructsValues(const void *a, const void *b) {
const teststruct_t *structA = (const teststruct_t*)a;
const teststruct_t *structB = (const teststruct_t*)b;
return (structA->value > structB->value) - (structA->value < structB->value);
return
(structA->value > structB->value) - (structA->value < structB->value);
}
sortMethod(structArray, 4, sizeof(teststruct_t), compareStructsValues);
char expectedValues[4] = {'a', 'b', 'c', 'd'};
+5 -1
View File
@@ -207,7 +207,11 @@ static void test_stringFormat(void **state) {
// Test buffer too small
expect_assert_failure(stringFormat(buffer, 5, "This is too long"));
expect_assert_failure(stringFormat(buffer, sizeof(buffer), "Hello %s", "This string is way too long to fit within the buffer that we have allocated"));
expect_assert_failure(stringFormat(
buffer, sizeof(buffer), "Hello %s",
"This string is way too long to fit within the buffer that we have "
"allocated"
));
// Test NULL destination, simply returns required length
len = stringFormat(NULL, 0, "Hello %s!", "World");