sic

The sic programming language, compiler and tools (WIP)
Log | Files | Refs

commit ac3570c8478f52b875d79afb958b23b2543efa12
parent 41c64bbaebc015b042cd43f14bf2407e17fe48a9
Author: citbl <citbl@citbl.org>
Date:   Sun, 10 May 2026 17:07:15 +1000

minor

Diffstat:
M.clang-format | 2+-
Msrc/lexer.c | 5++++-
2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/.clang-format b/.clang-format @@ -19,7 +19,7 @@ AlignConsecutiveMacros: false SortIncludes: false IndentCaseLabels: false -ColumnLimit: 120 +ColumnLimit: 110 # gives about two column on screen at 20px PenaltyBreakBeforeFirstCallParameter: 1 AlignAfterOpenBracket: DontAlign BinPackArguments: false diff --git a/src/lexer.c b/src/lexer.c @@ -21,6 +21,7 @@ void print_tokens(Lexer *l) for (i = 0; i < l->len; i++) { t = l->tokens[i]; typ = t.type; + switch (typ) { case LIT_STRING: printf("STRING LITERAL: %s\n", l->tokens[i].value.as_string.value); @@ -74,7 +75,9 @@ Lexer *lexer_lex(Lexer *l) { char c = '\0'; size_t len = strlen(l->code); - Token t = { .filename = l->filename, .path = l->path, .col = -1, .line = -1, .type = NOTYETSET, .value = { 0 } }; + Token t = { + .filename = l->filename, .path = l->path, .col = -1, .line = -1, .type = NOTYETSET, .value = { 0 } + }; l->tokens = calloc(250, sizeof(Token)); l->state.pos = 0;