Commit Graph

3 Commits

Author SHA1 Message Date
stupidcomputer e8da284365 add a proper command line interface 2024-06-16 20:12:56 -05:00
stupidcomputer 38877d36ab add more tests for the ISA; ISA bugfix
added more tests to the ISA -- covers all the instructions except RST
(reset).

fixed a bug in the ISA -- when comparing two numbers, we really compared
their pointers. in C, it's the difference between

```
int a = 10;
int b = 12;

int *ap = &a;
int *bp = &b;

if (ap < bp) { /* do stuff */ }
```

the problem is that you're comparing the pointers, *not* the values they
refer to. it instead should be like

if (*ap < *bp) { /* do stuff */ }

because you need to *dereference* the value before comparing. that's
what happens in cli/data/computer.py now.
2024-06-16 20:12:49 -05:00
stupidcomputer 6a038fcdde massive project restructure
relocated everything in its own module, `cli`, and split the server code
such that it's more component based, if you will

also, added a working test suite, which is somewhat exciting.
2024-06-16 18:18:28 -05:00