From 31249ee3c9626b5d89b1e3dd446885746370bf6a Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Sat, 23 Aug 2025 19:53:44 -0400 Subject: Don't align trailing comments --- src/parse.c | 8 ++++---- src/stdlib/lists.c | 4 ++-- src/typecheck.c | 2 +- src/types.c | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) (limited to 'src') diff --git a/src/parse.c b/src/parse.c index 9f6f1581..4eb09695 100644 --- a/src/parse.c +++ b/src/parse.c @@ -1428,7 +1428,7 @@ PARSER(parse_term_no_suffix) { spaces(&pos); ast_t *term = NULL; (void)(false || (term = parse_none(ctx, pos)) || (term = parse_num(ctx, pos)) // Must come before int - || (term = parse_int(ctx, pos)) || (term = parse_negative(ctx, pos)) // Must come after num/int + || (term = parse_int(ctx, pos)) || (term = parse_negative(ctx, pos)) // Must come after num/int || (term = parse_heap_alloc(ctx, pos)) || (term = parse_stack_reference(ctx, pos)) || (term = parse_bool(ctx, pos)) || (term = parse_text(ctx, pos)) || (term = parse_path(ctx, pos)) || (term = parse_lambda(ctx, pos)) || (term = parse_parens(ctx, pos)) || (term = parse_table(ctx, pos)) @@ -1554,10 +1554,10 @@ ast_e match_binary_operator(const char **pos) { case '<': { *pos += 1; if (match(pos, "=")) return LessThanOrEquals; // "<=" - else if (match(pos, ">")) return Compare; // "<>" + else if (match(pos, ">")) return Compare; // "<>" else if (match(pos, "<")) { if (match(pos, "<")) return UnsignedLeftShift; // "<<<" - return LeftShift; // "<<" + return LeftShift; // "<<" } else return LessThan; } case '>': { @@ -1565,7 +1565,7 @@ ast_e match_binary_operator(const char **pos) { if (match(pos, "=")) return GreaterThanOrEquals; // ">=" if (match(pos, ">")) { if (match(pos, ">")) return UnsignedRightShift; // ">>>" - return RightShift; // ">>" + return RightShift; // ">>" } return GreaterThan; } diff --git a/src/stdlib/lists.c b/src/stdlib/lists.c index 415e28a5..24383609 100644 --- a/src/stdlib/lists.c +++ b/src/stdlib/lists.c @@ -105,8 +105,8 @@ void List$insert_all(List_t *list, List_t to_insert, Int_t int_index, int64_t pa fail("Invalid insertion index ", index, " for a list with length ", (int64_t)list->length); if ((int64_t)list->free >= (int64_t)to_insert.length // Adequate free space - && list->data_refcount == 0 // Not aliased memory - && (int64_t)list->stride == padded_item_size) { // Contiguous list + && list->data_refcount == 0 // Not aliased memory + && (int64_t)list->stride == padded_item_size) { // Contiguous list // If we can fit this within the list's preallocated free space, do that: list->free -= to_insert.length; list->length += to_insert.length; diff --git a/src/typecheck.c b/src/typecheck.c index 680d3049..738fb235 100644 --- a/src/typecheck.c +++ b/src/typecheck.c @@ -1763,7 +1763,7 @@ PUREFUNC bool is_constant(env_t *env, ast_t *ast) { } case TextJoin: { DeclareMatch(text, ast, TextJoin); - if (!text->children) return true; // Empty string, OK + if (!text->children) return true; // Empty string, OK if (text->children->next) return false; // Concatenation, not constant return is_constant(env, text->children->ast); } diff --git a/src/types.c b/src/types.c index e60483aa..e3a6efb5 100644 --- a/src/types.c +++ b/src/types.c @@ -503,7 +503,7 @@ PUREFUNC size_t type_size(type_t *t) { size_t size = type_size(tag->type); if (size > max_size) max_size = size; } - size_t size = sizeof(UnknownType); // generic enum + size_t size = sizeof(UnknownType); // generic enum if (max_align > 1 && size % max_align > 0) // Padding before first union field size += max_align - (size % max_align); size += max_size; -- cgit v1.2.3