Commits
- Commit:
ff74f7cdda7b08da6fe7c8bbcca990305fd6b547
- From:
- Russ Cox <rsc@swtch.com>
- Date:
rc: allow unquoted = in command arguments
dd fans rejoice!
Also helps with commands like go test -run=x.
- Commit:
7d6a248f2c68d70f58387afc69e73e695c3d940c
- From:
- Russ Cox <rsc@swtch.com>
- Date:
rc: move free carat handling into parser
This fixes at least one shell script (printfont) that expected
'x'`{y}'z'
to mean
'x'^`{y}^'z'
as it now does. Before it meant:
'x'^`{y} 'z'
One surprise is that adjacent lists get a free carat:
(x y z)(1 2 3)
is
(x1 y2 z3)
This doesn't affect any rc script in Plan 9 or plan9port.
- Commit:
3caf5c238a886d06b438ec6d42f2609b8625463f
- From:
- Russ Cox <rsc@swtch.com>
- Date:
rc: move newline handling into parser
- Commit:
47d4646eebac34c0b94951cfcf1b81ed2ca513e1
- From:
- Russ Cox <rsc@swtch.com>
- Date:
rc: add recursive descent parser
The old yacc-based parser is available with the -Y flag,
which will probably be removed at some point.
The new -D flag dumps a parse tree of the input,
without executing it. This allows comparing the output
of rc -D and rc -DY on different scripts to see that the
two parsers behave the same.
The rc paper ends by saying:
It is remarkable that in the four most recent editions of the UNIX
system programmer’s manual the Bourne shell grammar described in the
manual page does not admit the command who|wc. This is surely an
oversight, but it suggests something darker: nobody really knows what
the Bourne shell’s grammar is. Even examination of the source code is
little help. The parser is implemented by recursive descent, but the
routines corresponding to the syntactic categories all have a flag
argument that subtly changes their operation depending on the context.
Rc’s parser is implemented using yacc, so I can say precisely what the
grammar is.
The new recursive descent parser here has no such flags.
It is a straightforward translation of the yacc.
The new parser will make it easier to handle free carats
in more generality as well as potentially allow the use of
unquoted = as a word character.
Going through this exercise has highlighted a few
dark corners here as well. For example, I was surprised to
find that
x >f | y
>f x | y
are different commands (the latter redirects y's output).
It is similarly surprising that
a=b x | y
sets a during the execution of y.
It is also a bit counter-intuitive
x | y | z
x | if(c) y | z
are not both 3-phase pipelines.
These are certainly not things we should change, but they
are not entirely obvious from the man page description,
undercutting the quoted claim a bit.
On the other hand, who | wc is clearly accepted by the grammar
in the manual page, and the new parser still handles that test case.
- Commit:
c1c1b5267fd5e14be531a4b22ed0124b35d427cb
- From:
- sean <phonologus@gmail.com>
- Via:
- David du Colombier <0intro@gmail.com>
- Date:
9c: added explicit -fcommon to gcc defaults.
Version 10 of gcc enforces -fno-common which breaks a lot of things.
This fix reverts to the pre-10 behaviour. The real fix is to clean up
stray redefinitions which should be declarations.
- Commit:
4650064aa757c217fa72f8819a2cf67c689bcdef
- From:
- Russ Cox <rsc@swtch.com>
- Date:
acme: scale window bodies on resize, not including tag space
This avoids reopening collapsed windows after a large vertical resize.
- Commit:
92aa0e13ad8cec37936998a66eb728bfca88d689
- From:
- Larkin Nickle <me@larbob.org>
- Via:
- Dan Cross <crossd@gmail.com>
- Date:
Fix broken references to plan9.bell-labs.com/plan9
Fixes #357
- Commit:
0237dec768a4ee36ae9e18ce8566d2c999d78410
- From:
- Neven Sajko <nsajko@gmail.com>
- Via:
- Dan Cross <crossd@gmail.com>
- Date:
libthread: fix ARM build by renaming file
Fixes #363
Change-Id: Ic8ad5ccce3935fdf00732d78d3024b535db90447
- Commit:
f66f0a587b48337388296c8f1820f9b3dbfd0085
- From:
- Martin Palma <m@palma.bz>
- Via:
- GitHub <noreply@github.com>
- Date:
devdraw: fix `cmd-r` to toggle retina vs. non-retina mode on macOS (#361)
and not unexpectedly quitting an application.
Fixes #360
- Commit:
4197af4122bc06cf4062ca2d1d5bc8f973e37cf1
- From:
- Russ Cox <rsc@swtch.com>
- Date:
libthread: comment stack border a bit more
- Commit:
93e2e820a5551ba3d0a1e0f0fbd4c5eb65e18ce6
- From:
- Russ Cox <rsc@swtch.com>
- Date:
acme: report close failure in Put, this time for sure
Missed in 0b349f6f that Bterm is not closing fd.
- Commit:
f6c9f7b14c9dce53fff6020200b28c4e25621e87
- From:
- Russ Cox <rsc@swtch.com>
- Date:
libthread: fix test deps, cleanup in mkfile
- Commit:
4698bde2367f971fed3924f2dee736e0dfe37bb9
- From:
- Russ Cox <rsc@swtch.com>
- Date:
libthread: clean up sysofiles.sh a bit more
- Commit:
37e7d24c0cb9fd2d18ab332980c31cf470454d93
- From:
- Russ Cox <rsc@swtch.com>
- Date:
libthread: rm OpenBSD tas implementations
OpenBSD is using pthreads now, so no need for tas.
- Commit:
41b3e8b9893a8561af7e85ca98444bc284b4013d
- From:
- Russ Cox <rsc@swtch.com>
- Date:
libthread: use consistent stack calculation code in makecontext
Also reduce duplication: makecontext is per-arch not per-os-arch.
May fix #353.