Mercurial > emacs
annotate lib-src/digest-doc.c @ 1678:62ecf0c5b54c
Give subprocess creation a way to find a valid current directory
for subprocesses when the buffer's default-directory is a handled
name.
* fileio.c (Funhandled_file_name_directory): New function.
(Qunhandled_file_name_directory): New file-name-handler operation.
(syms_of_fileio): Defsubr Sunhandled_file_name_directory, and
initialize and staticpro Qunhandled_file_name_directory.
* callproc.c (Fcall_process): Call Funhandled_file_name_directory
on the buffer's default directory. Do it earlier in the function
so there's less to GCPRO.
* process.c (create_process): Don't check the validity of the
buffer's default directory here...
(Fstart_process): Instead, do it here; if we call
Funhandled_file_name_directory here, there's less GCPROing to do.
* callproc.c (Fcall_process_region): Return the value returned by
Fcall_process.
author | Jim Blandy <jimb@redhat.com> |
---|---|
date | Sat, 12 Dec 1992 15:31:32 +0000 |
parents | bba832d91c66 |
children | dd3b83e4ceb0 |
rev | line source |
---|---|
9 | 1 /* Give this program DOCSTR.mm.nn as standard input |
2 and it outputs to standard output | |
3 a file of nroff output containing the doc strings. | |
4 | |
5 See also sorted-doc.c, which produces similar output | |
6 but in texinfo format and sorted by function/variable name. */ | |
7 | |
8 #include <stdio.h> | |
9 main () | |
10 { | |
11 register int ch; | |
12 register int notfirst = 0; | |
13 | |
14 printf (".TL\n"); | |
15 printf ("Command Summary for GNU Emacs\n"); | |
16 printf (".AU\nRichard M. Stallman\n"); | |
17 while ((ch = getchar ()) != EOF) | |
18 { | |
19 if (ch == '\037') | |
20 { | |
21 if (notfirst) | |
22 printf ("\n.DE"); | |
23 else | |
24 notfirst = 1; | |
25 | |
26 printf ("\n.SH\n"); | |
27 | |
28 ch = getchar (); | |
29 printf (ch == 'F' ? "Function " : "Variable "); | |
30 | |
31 while ((ch = getchar ()) != '\n') /* Changed this line */ | |
32 { | |
33 if (ch != EOF) | |
34 putchar (ch); | |
35 else | |
36 { | |
37 ungetc (ch, stdin); | |
38 break; | |
39 } | |
40 } | |
41 printf ("\n.DS L\n"); | |
42 } | |
43 else | |
44 putchar (ch); | |
45 } | |
46 return 0; | |
47 } |