From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mail-a.sr.ht; dkim=pass header.d=johnnyrichard.com header.i=@johnnyrichard.com Received: from out-170.mta1.migadu.com (out-170.mta1.migadu.com [IPv6:2001:41d0:203:375::aa]) by mail-a.sr.ht (Postfix) with ESMTPS id D715220097 for <~johnnyrichard/olang-devel@lists.sr.ht>; Mon, 19 Feb 2024 00:39:58 +0000 (UTC) X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=johnnyrichard.com; s=key1; t=1708303198; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=POIEbGpzP9sI/CPFEqC0mo/EEFu9h8KoGD1dYHdvuKc=; b=FH1E1tfbjeuhsuRl7jX4v/7I+OmB+z8QtKAp28qT8hHO7qiVDoI0d1jRF6pi2p8lv3j7XV 53p0tsnv4PXhiS65zO12pHxw/0KSjLg6D2PkUUrBrDJ1X7I1bzo2Db7s3X6MKOpbgTuLYe 4fM2HVryjy2Fl4eDWfx6SyNHt6a2H0pseNBtjJ6TQMT2NXWpjNVH5s9W3cp4uRVHmFpf1N wE1nv++ATlRlRKfsTCXzOi673JV1aVkBbdiQyCfAtKLTfeIx8OTPw91Jc2sFWLd1lDqrFf zOn1/qYYacNZha0n711txWuMCRf6srDvHo39jKuk3ljs1zD1PtccUu2UL/JIiw== From: Johnny Richard To: ~johnnyrichard/olang-devel@lists.sr.ht Cc: Johnny Richard Subject: [PATCH olang v3 0/2] Create --dump-tokens on compiler cli Date: Mon, 19 Feb 2024 02:38:09 +0100 Message-ID: <20240219013843.15707-1-johnny@johnnyrichard.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT X-TUID: hBzE8wg2T9l6 This patchset creates the lexer and leave 3 TODO for man documents and test (unit / integration). Johnny Richard (2): utils: create string_view data structure lexer: create --dump-tokens cli command .gitignore | 1 + examples/main_exit.0 | 3 + src/0c.c | 121 +++++++++++++++++- src/lexer.c | 224 +++++++++++++++++++++++++++++++++ src/lexer.h | 74 +++++++++++ src/string_view.c | 35 ++++++ src/string_view.h | 34 +++++ tests/integration/cli_runner.c | 4 +- tests/integration/cli_runner.h | 2 +- tests/integration/cli_test.c | 2 +- 10 files changed, 494 insertions(+), 6 deletions(-) create mode 100644 examples/main_exit.0 create mode 100644 src/lexer.c create mode 100644 src/lexer.h create mode 100644 src/string_view.c create mode 100644 src/string_view.h -- 2.43.2