I was reading tcsh's documentation and it mentioned the -q option
exists in other csh implementations but is often undocumented.
Comparing behavior between csh -f and csh -fq on OpenBSD 6.4 (though I
suspect the version doesn't matter for this) showed that the q option
is indeed accepted and used, as in the latter case, ^\ (SIGQUIT)
causes csh to quit and dump core, unlike in the former case.
The source:
> case 'q': /* -q (Undoc'd) ... die on quit */
https://cvsweb.openbsd.org/src/bin/csh/csh.c?rev=1.45&content-type=text/x-cvsweb-markup
confirms this.
I'm unsure how to best phrase this in csh's man page, though, other
than simply adopting the wording used in tcsh's man page.

It also turns out the other of the two things in tcsh's man page
labeled as "usually undocumented" also works in OpenBSD's csh.  The
`time' variable accepts format flags.
compare:
set time=0
sleep 1
with:
set time=(0 %E)
sleep 1
The source:
> case 'E': /* elapsed (wall-clock) time */
https://cvsweb.openbsd.org/src/bin/csh/time.c?rev=1.17&content-type=text/x-cvsweb-markup

Reply via email to