wash
b630aa009c
lang: lex: add function to check if tokens are available
...
if this function returns false, any attempt to read tokens from the lexer will cause another line of input to be retrieved from the lexer's line source.
2024-11-23 19:27:29 +00:00
wash
54a0c331b2
common: add a status code for internal errors
2024-11-23 19:26:29 +00:00
wash
5c5a2d236c
lang: ast: add stub parser functions
2024-11-23 10:15:40 +00:00
wash
8219797cbb
cmake: don't link bluelib modules to their dependencies
...
this fixes duplicate library warnings given by ld, but still ensures that the user lists all dependent bluelib modules in their CMakeFiles.txt
2024-11-23 10:14:05 +00:00
wash
6f06f42953
lang: add missing includes
2024-11-22 22:30:26 +00:00
wash
f1be82c495
asm: add missing includes
2024-11-22 22:30:15 +00:00
wash
ceb9f10b66
lang: add ast node definitions
2024-11-22 21:47:37 +00:00
wash
90f96b6229
lang: lex: fix regular number characters not incrementing the token length
2024-11-21 20:05:13 +00:00
wash
2d89db48d2
doc: standardise the use of braces, brackets, and parens in asm source
...
parens () are used to specify object parent (e.g. the name of the class
that a message handler belongs to)
braces {} are used to specify the contents of an object (e.g. the
getter/setter for a property)
brackets [] are used to specify the identifier of an object (e.g. the
selector for a message handler)
2024-11-20 22:15:14 +00:00
wash
230e66e066
asm: lex: add left and right brace symbols
2024-11-20 22:15:10 +00:00
wash
17ee2b6b57
frontend: switch to new bluelib tty interface
2024-11-20 22:14:35 +00:00
wash
92f407ac09
lang: add colour to internal print functions
2024-11-20 22:14:11 +00:00
wash
8df4592a6b
frontend: assemble: lex assembly file contents
2024-11-19 22:09:54 +00:00
wash
adf4e38578
frontend: implement function for printing assembly lex tokens
2024-11-19 22:09:32 +00:00
wash
4e8d6e8122
asm: implement asembly lexer
2024-11-19 22:08:58 +00:00
wash
605d70d967
doc: add decimal number to sample source file
2024-11-19 16:58:44 +00:00
wash
335e360b2d
frontend: implement printing integer and double lex tokens
2024-11-19 16:57:39 +00:00
wash
6e642b3c19
lang: lex: implement lexing of decimal numbers
2024-11-19 16:57:20 +00:00
wash
a54a232428
lang: lex: fix underscore label producing two separate tokens
2024-11-19 16:17:58 +00:00
wash
ea3c01204b
frontend: repl: remove line continuations from input produced by line-ed
2024-11-19 15:59:05 +00:00
wash
b62c048498
frontend: line-ed: fix control characters (\n, \r, etc) being mishandled on win32
2024-11-19 15:58:25 +00:00
wash
1dbe68cfeb
lang: lex: add missing symbol and keyword definitions
2024-11-19 15:57:31 +00:00
wash
7eab36aa5f
frontend: add command for internal debugging functionality
2024-11-19 15:22:58 +00:00
wash
7c42bf7bc9
lang: add internal debugging interface
2024-11-19 15:22:39 +00:00
wash
881f345bbe
lang: lex: move structure definitions to a separate header
2024-11-19 15:22:16 +00:00
wash
0f3328565e
lang: lex: fix identifier prefixed with underscore being tokenised incorrectly
2024-11-19 14:00:42 +00:00
wash
eda7a1f951
frontend: line-ed: add missing tty function implementations for linux & darwin
2024-11-19 13:00:11 +00:00
wash
4d411c67f0
frontend: line-ed: add missing wchar includes
2024-11-19 12:59:52 +00:00
wash
90a32ac1a1
lang: lex: use a dictionary to lookup keywords
2024-11-19 10:49:42 +00:00
wash
c5f60c285e
frontend: line-ed: convert all escape code usage to s_tty calls
2024-11-18 21:13:28 +00:00
wash
5a5b0d01d8
lang: lex: only read linefeeds up to the end of the current line buffer
2024-11-18 15:19:26 +00:00
wash
96172eac84
frontend: line-ed: move platform-specific code to separate directory
2024-11-18 15:15:04 +00:00
wash
29447bf5ec
frontend: split interactive and non-interactive modes into separate commands
2024-11-18 09:55:02 +00:00
wash
d5c86c4eea
frontend: move token printing code to a separate file
2024-11-18 09:54:27 +00:00
wash
4fc1a6ade8
frontend: add a line editor for shell input
2024-11-18 09:53:55 +00:00
wash
f44a3364b3
common: add MIN and MAX macros
2024-11-18 09:53:35 +00:00
wash
61eabd52c4
lang: lex: replace call to isnumber() with isdigit()
2024-11-17 10:58:31 +00:00
wash
6a563da1b0
doc: include dquote strings in Person.im
2024-11-17 09:32:49 +00:00
wash
c9661af81e
frontend: compile: print number and atom token info
2024-11-17 09:32:26 +00:00
wash
104e549b32
lang: lex: implement lexing of numbers and atoms
2024-11-17 09:31:58 +00:00
wash
f55b8f4851
frontend: compile: use new opaque lexer interface
2024-11-16 23:05:07 +00:00
wash
f14c387a6e
lang: lex: implement state stack; make lexer structure opaque
...
the state stack is used to track whether a string is currently being read,
what kind of string it is, and whether or not we are in an interpolation
within that string.
2024-11-16 23:03:43 +00:00
wash
412e9abf05
frontend: compile: add colour-coding to token list
2024-11-16 23:03:16 +00:00
wash
e01798db2f
doc: add a note describing lexer state transitions
2024-11-16 21:30:45 +00:00
wash
102769735e
lang: lex: start implementing strings and interpolation
2024-11-16 21:30:32 +00:00
wash
7959dc26a1
Merge branch 'main' of https://github.com/washh/ivy
2024-11-16 20:40:32 +00:00
wash
6e5db6a3e2
frontend: compile: print lex token details as they are read
2024-11-16 17:06:02 +00:00
wash
00cf226078
lang: lex: implement lexing of symbols, identifiers, labels, keywords, and comments
2024-11-16 17:05:29 +00:00
wash
024d317e13
cmake: store all build artifacts in bin/ and lib/ directories
2024-11-16 17:04:50 +00:00
wash
5af7aebba7
vim: fix self:: being highlighted as a label rather than a builtin var
2024-11-16 17:03:51 +00:00