| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
1000+ LoC spent; just 300+ excluding tests.
Still one known gap; we don't check the entirety of an array's element
type if it's a compound. So far we just check if say both sides start with
'addr'. Obviously that's not good enough.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
At the SubX level we have to put up with null-terminated kernel strings
for commandline args. But so far we haven't done much with them. Rather
than try to support them we'll just convert them transparently to standard
length-prefixed strings.
In the process I realized that it's not quite right to treat the combination
of argc and argv as an array of kernel strings. Argc counts the number
of elements, whereas the length of an array is usually denominated in bytes.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
And we're using it now in factorial.mu!
In the process I had to fix a couple of bugs in pointer dereferencing.
There are still some limitations:
a) Indexing by a literal doesn't work yet.
b) Only arrays of ints supported so far.
Looking ahead, I'm not sure how I can support indexing arrays by non-literals
(variables in registers) unless the element size is a power of 2.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
This cleans up a bunch of little warts that had historically accumulated
because of my bull-headedness in not designing a grammar up front. Let's
see if the lack of a grammar comes up again.
We now require that there be no space in variable declarations between
the name and the colon separating it from its type.
|
|
|
|
|
|
|
|
| |
Allow comments at the end of all kinds of statements.
To do this I replaced all calls to next-word with next-mu-token.. except
one. I'm not seeing any bugs yet, any places where comments break things.
But this exception makes me nervous.
|
| |
|
|
|
|
|
|
|
|
| |
Support calling SubX code from Mu. I have _zero_ idea how to make this
safe.
Now we can start writing tests. We can't use commandline args yet. That
requires support for kernel strings.
|
|
|