| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I have a plan for a way to avoid use-after-free errors without all the
overheads of maintaining refcounts. Has the nice side-effect of
requiring manual memory management. The Mu way is to leak memory by
default and build tools to help decide when and where to expend effort
plugging memory leaks. Arguably programs should be distributed with
summaries of their resource use characteristics.
Eliminating refcount maintenance reduces time to run tests by 30% for
`mu edit`:
this commit parent
mu test: 3.9s 4.5s
mu test edit: 2:38 3:48
Open questions:
- making reclamation easier; some sort of support for destructors
- reclaiming local scopes (which are allocated on the heap)
- should we support automatically reclaiming allocations inside them?
|
|
|
|
|
| |
Stop hardcoding Max_depth everywhere; we had a default value for a
reason but then we forgot all about it.
|
|
|
|
| |
Redo commit 3905 to always shutdown cleanly on any error raised.
|
|
|
|
|
|
|
|
|
| |
In tests where a text has the wrong length, properly show the text
observed to help debug failures.
We now also consistently say 'text' in Mu errors, never 'string'.
Thanks Ella Couch for reporting this long-standing issue.
|
|
|
|
|
|
|
| |
Standardize exit paths. Most layers now don't need to know about termbox.
We can't really use `assert` in console-mode apps; it can't just exit because
we want to be able to check assertion failures in tests.
|
| |
|
|
|
|
|
| |
Fix a crash on an invalid program. Thanks Lakshman Swaminathan for reporting
this issue.
|
| |
|
| |
|
|
|
|
| |
Fix CI, broken by commit 3691.
|
|
|
|
| |
Thanks Jack Couch for running into this.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Useful for programming contests like https://halite.io
Doesn't suffer from C++'s usual buffered gotchas: it'll skip leading
whitespace. Slow, though. Can be speeded up, though.
- 20 minutes later
But what's the point? Typewriter mode is actually harder to test than
'raw' console mode. Writing Mu programs in typewriter mode is just going
to encourage us all to slack off on writing tests.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
One more place we were missing expanding type abbreviations: inside
container definitions.
|
|
|
|
| |
Can't use type abbreviations inside 'memory-should-contain'.
|
|
|
|
|
|
| |
It might be too much, particularly if students start peeking inside .mu
files early. But worth a shot for not just to iron out the kinks in the
abbreviation system.
|
| |
|
| |
|
|
|
|
|
| |
array length = number of elements
array size = in locations
|
|
|
|
|
|
|
|
|
|
|
| |
Prefer preincrement operators wherever possible. Old versions of
compilers used to be better at optimizing them. Even if we don't care
about performance it's useful to make unary operators look like unary
operators wherever possible, and to distinguish the 'statement form'
which doesn't care about the value of the expression from the
postincrement which usually increments as a side-effect in some larger
computation (and so is worth avoiding except for some common idioms, or
perhaps even there).
|
| |
|
|
|
|
|
| |
Bugfix in filesystem creation. I'm sure there are other fake-filesystem
bugs.
|
| |
|
|
|
|
| |
Thanks Ella Couch for finding this bug.
|
| |
|
|
|
|
|
|
|
| |
More consistent labeling of waypoints. Use types only when you need to
distinguish between function overloadings. Otherwise just use variable
names unless it's truly not apparent what they are (like that the result
is a recipe in "End Rewrite Instruction").
|
|
|