| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the process of debugging the last couple of commits (though I no
longer remember exactly how) I noticed that 'wait-for-routine' only
waits until the target routine stops running for any reason, including
when it blocks on something. That's not the synchronization primitive we
want in production code, even if it's necessary for some scenarios like
'buffer-lines-blocks-until-newline'. So we rename the old 'wait-for-routine'
primitive to 'wait-for-routine-to-block', and create a new version of
'wait-for-routine' that say callers of 'start-writing' can safely use,
because it waits until a target routine actually completes (either
successfully or not).
|
| |
|
|
|
|
|
| |
Bugfix in filesystem creation. I'm sure there are other fake-filesystem
bugs.
|
| |
|
| |
|
|
|
|
| |
High time I committed the part that works.
|
| |
|
|
|
|
|
| |
Replace some asserts when checking scenario screens with better error
messages.
|
| |
|
|
|
|
|
| |
This is inefficient; every occurrence of a recipe literal requires a
scan through the whole caller recipe.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I started out incredibly lax about running past errors (I even used to
call them 'warnings' when I started Mu), but I've been gradually seeing
the wisdom of Go and Racket in refusing to run code if it doesn't pass
basic integrity checks (such as using a literal as an address).
Go is right to have no warnings, only errors. But where Go goes wrong is
in even caring about unused variables.
Racket and other languages perform more aggressive integrity checks so
that the can optimize more aggressively, and I'm starting to realize I
don't know enough to disagree with them.
|
| |
|
| |
|
|
|
|
|
|
|
| |
Drop support for escape characters in dilated reagents. We haven't felt
the need for it yet, we have no tests for it, and eventually when we do
we want to treat escapes the way we treat them in the rest of the
language. (commit 3233)
|
|
|
|
| |
Use allocate() in 'assume-console'.
|
| |
|
| |
|
|
|
|
|
|
| |
Clean up primitive for reading from file. Never return EOF character.
Stop using null character to indicate EOF as well. Instead, always use a
second product to indicate EOF, and require calls to use it.
|
|
|
|
|
|
|
|
| |
More checks for unsafe filesystem primitives. Most important, make sure
the product of any $close-file instruction is never ignored, and that
it's the same variable as the ingredient. (No way to indicate that in Mu
code yet, but then Mu code should always be safe and not require such
checks.)
|
| |
|
| |
|
|
|
|
| |
Fix some breaking sandbox/ tests.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Thanks Sam Putman for helping think through this idea.
When you encounter a backslash, strip it out and pass through any
following run of backslashes. If we 'escaped' a single following
character like C, then the character '\' would be the same as:
'\\' escaped once
'\\\\' escaped twice
'\\\\\\\\' escaped thrice (8 backslashes)
..and so on, the number of backslashes doubling each time. Instead, our
approach is to make the character '\' the same as:
'\\' escaped once
'\\\' escaped twice
'\\\\' escaped thrice
..and so on, the number of backslashes merely increasing by one each
time.
This approach only works as long as backslashes aren't also overloaded
to create special characters. So Mu doesn't follow C's approach of
overloading backslashes both to escape quote characters and also as a
notation for unprintable characters like '\n'.
|
|
|
|
| |
Support pipe characters in fake files. Still super ugly, though.
|
| |
|
| |
|
|
|
|
| |
Built with Stephen Malina.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
For example usage of file operations, see filesystem.mu.
Is it ugly that we don't actually write to disk unless we wait for the
writing routine to exit? Maybe there's a nice way to wrap it. At any
rate, all buffering is explicit, which seems a win compared to *nix.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Commit 3191 stopped defining _XOPEN_SOURCE when building termbox/ to get
Mu to build on OpenBSD. However, that had the side effect of not
declaring the prototype for wcwidth() on some versions of Linux. Ugh.
Just hack around this morass.
In general the direction we want to go in Mu is fewer feature #defines.
At least explicit ones. Should be an internal detail of the underlying
platform our code shouldn't have to worry about. If headers don't
cooperate, just start explicitly declaring prototypes and damn the
consequences.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Trying keeping html in the master branch:
https://github.com/blog/2228-simpler-github-pages-publishing
Let's see if https://akkartik.github.io/mu updates after I push this
commit to just the master branch.
|
|
|
|
|
|
| |
Fix CI. Scenario size_of_shape_shifting_exclusive_container was
triggering undefined behavior in tangle/ and causing things to break in
some compilers but not others.
|
|
|
|
| |
Fix a new warning from Perl.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Another hole in refcount management, which I noticed while doing commit
3202, and thinking about which led to the insight of commit 3212.
Now the summary of commit 3197 is modified to this:
Update refcounts of products after every instruction, EXCEPT:
a) when instruction is a non-primitive and the callee starts with
'local-scope' (because it's already not decremented in 'return')
OR:
b) when instruction is primitive 'next-ingredient' or
'next-ingredient-without-typechecking', and its result is saved to a
variable in the default space (because it's already incremented at
the time of the call)
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
When updating refcounts for a typed segment of memory being copied over
with another, we were only ever using the new copy's data to determine
any tags for exclusive containers. Looks like the right way to do
refcounts is to increment and decrement separately.
Hopefully this is a complete fix for the intermittent but
non-deterministic errors we've been encountering while running the edit/
app.
|
| |
|
|
|
|
| |
Thanks Ella Couch; this was long overdue.
|
| |
|