public inbox for ~johnnyrichard/olang-devel@lists.sr.ht
 help / color / mirror / code / Atom feed
* [PATCH olang v2 0/4] create initial syntax analysis logic
@ 2024-03-01 22:24 Johnny Richard
  2024-03-01 22:24 ` [PATCH olang v2 1/4] string_view: add string view formatter for printf fmt Johnny Richard
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Johnny Richard @ 2024-03-01 22:24 UTC (permalink / raw)
  To: ~johnnyrichard/olang-devel; +Cc: Johnny Richard

This patchset implements the initial syntax analysis logic for a small
portion of the language.

Since the type system contains only a u32 type, the semantic analysis
can be postponed.

In terms of Abstract Syntax Tree, this patchset also introduces a very
basic AST data structure.

Johnny Richard (4):
  string_view: add string view formatter for printf fmt
  string_view: add string view conversion to uint32_t
  lexer: add token lookahead capability
  parser: create simplified parser for tiny AST

 src/ast.c                     |  79 +++++++++++++
 src/ast.h                     | 101 +++++++++++++++++
 src/lexer.c                   |  36 ++++++
 src/lexer.h                   |  10 ++
 src/parser.c                  | 202 ++++++++++++++++++++++++++++++++++
 src/parser.h                  |  38 +++++++
 src/string_view.c             |  11 ++
 src/string_view.h             |   8 +-
 tests/unit/parser_test.c      |  88 +++++++++++++++
 tests/unit/string_view_test.c |  67 +++++++++++
 10 files changed, 639 insertions(+), 1 deletion(-)
 create mode 100644 src/ast.c
 create mode 100644 src/ast.h
 create mode 100644 src/parser.c
 create mode 100644 src/parser.h
 create mode 100644 tests/unit/parser_test.c
 create mode 100644 tests/unit/string_view_test.c

-- 
2.43.2


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2024-03-01 22:08 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-03-01 22:24 [PATCH olang v2 0/4] create initial syntax analysis logic Johnny Richard
2024-03-01 22:24 ` [PATCH olang v2 1/4] string_view: add string view formatter for printf fmt Johnny Richard
2024-03-01 22:24 ` [PATCH olang v2 2/4] string_view: add string view conversion to uint32_t Johnny Richard
2024-03-01 22:24 ` [PATCH olang v2 3/4] lexer: add token lookahead capability Johnny Richard
2024-03-01 22:24 ` [PATCH olang v2 4/4] parser: create simplified parser for tiny AST Johnny Richard
2024-03-01 21:32   ` [olang/patches/.build.yml] build success builds.sr.ht
2024-03-01 22:08   ` [PATCH olang v2 4/4] parser: create simplified parser for tiny AST Carlos Maniero

Code repositories for project(s) associated with this public inbox

	https://git.johnnyrichard.com/olang.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox