File: ilisp.texi

package info (click to toggle)
ilisp 5.12.0%2Bcvs.2004.12.26-27.2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 2,880 kB
  • sloc: lisp: 14,682; sh: 143; makefile: 142
file content (2507 lines) | stat: -rw-r--r-- 79,740 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
\input texinfo    @c -*-texinfo-*-         Last modified: December 6, 2002
@setfilename ilisp.info
@settitle The ILISP Inferior Lisp Interface

@dircategory Lisp Programming
@direntry
* ILisp: (ilisp).       Inferior Lisp mode.
@end direntry

@iftex
@finalout
@end iftex

@c  NOTE:  KEYBINDING DESCRIPTIONS IN THIS FILE
@c
@c  Texinfo doesn't support the functionality of  substitute-command-keys,
@c  which kind of makes things tough when the bindings change.
@c
@c  Note that all the keys here which use the ILISP prefix have
@c  @key{C-z} before them, so a global replace can be used to put in a
@c  specific value for this (if wanted).  The whole string should be
@c  rpelaced, as in (replace-string "@key{C-z}" "@key{C-c}").  Any occurrences
@c  of this should be in the proper @kbd{} construct, or in a table.
@c
@c  Key command descriptions in tables have the function listed after
@c  them, as in   "@item RET   (return-ilisp)"  so it should be poosible
@c  to update these descriptions with a little ELisp code.
@c
@c  Todd Kaufmann    17-Mar-91
@c  toad@cs.cmu.edu


@c ================================================================
@c THIS file has the new style title page commands.

@c Run using special version of `texinfo.tex'.
@c Version 2.13 or higher is recommended.

@c Also, run `makeinfo' rather than `texinfo-format-buffer'.
@c (Get the texinfo2 package.)
@c ================================================================

@c Use this if you want small book size like the GNU Emacs bound book.
@c smallbook

@c tex
@c \overfullrule=0pt
@c end tex

@comment   INDEX   USAGE:
@c
@c	@cindex     concept
@c	@findex     function
@c	@vindex     variable
@c	@kindex     key
@c	@pindex     command     (normally program)
@c
@c not used:
@c	@tindex    (data)type


@c
@c Combine indices.
@c @synindex cp fn
@c @syncodeindex vr fn
@c @syncodeindex ky fn
@c @syncodeindex pg fn
@c @syncodeindex tp fn
@c oops: texinfo-format-buffer ignores synindex
@c So, use makeinfo.c.  Get texinfo2.tar.Z off of prep.ai.mit.edu
@c

@c TODO:
@c - Add doc for rlogin lisps.


@ifinfo
This file documents ILISP.

This is edition 0.24 of the ILISP manual
for ILISP Version: 5.12.1

@example
Copyright (C) 1991,1992,1993 Todd Kaufmann
              1993,1994 Ivan Vasquez
              1994, 1995, 1996 Marco Antoniotti and Rick Busdiecker
              1996, 1997, 1998, 1999 Marco Antoniotti and Rick Campbell
@end example

Permission is granted to make and distribute verbatim copies of
this manual provided the copyright notice and this permission notice
are preserved on all copies.

Permission is granted to copy and distribute modified versions of this
manual under the conditions for verbatim copying, provided that the entire
resulting derived work is distributed under the terms of a permission
notice identical to this one.

Permission is granted to copy and distribute translations of this manual
into another language, under the above conditions for modified versions,
except that this permission notice may be stated in a translation approved
by the Foundation.
@end ifinfo
@c

@c
@setchapternewpage odd

@titlepage
@title ILISP User Manual
@subtitle A GNU Emacs Interface for Interacting with Lisp
@subtitle Edition 0.24, December 2002
@subtitle For ILISP Version: 5.12.1
@c
@c the following comment string is removed by the ctrl-c-doc.sh script,
@c which can be used to change all ilisp-*prefix* bindings to C-c (or
@c other).
@c
@comment ctrl-C version: @subtitle This is the ``@key{C-z}'' version of the manual.

@author by Todd Kaufmann, Chris McConnell, Ivan Vazquez,
@author Marco Antoniotti, Rick Campbell
@author and Paolo Amoroso

@page
@vskip 0pt plus 1filll
Copyright @copyright{}
@itemize
        @item 1991, 1992, 1993 Todd Kaufmann
        @item 1993, 1994 Ivan Vasquez
        @item 1994, 1995, 1996 Marco Antoniotti and Rick Busdiecker
        @item 1996, 1997, 1998, 1999 Marco Antoniotti and Rick Campbell
@end itemize

@sp 2
This is edition 0.24 of the @cite{ILISP User Manual}
for ILISP Version: 5.12.1,
December 2002.

@sp 2

Permission is granted to make and distribute verbatim copies of
this manual provided the copyright notice and this permission notice
are preserved on all copies.

Permission is granted to copy and distribute modified versions of this
manual under the conditions for verbatim copying, provided that the entire
resulting derived work is distributed under the terms of a permission
notice identical to this one.

Permission is granted to copy and distribute translations of this manual
into another language, under the above conditions for modified versions,
except that this permission notice may be stated in a translation approved
by this author.
@end titlepage
@page


@node Top, Distribution, (dir), (dir)
@comment  node-name,  next,  previous,  up


@ifinfo
This Info file documents ILISP, a GNU Emacs interface for a Lisp
running in a buffer.
@comment ctrl-C version: @sp
@comment ctrl-C version: This is the ``@key{C-z}'' version of the manual.
@end ifinfo

@menu
* Distribution::                How to get the latest ILISP distribution.

* Acknowledgements::            Acknowledgements
* Features::                    An list of ILISP features.
* Installation::                How to install ILISP.
* Starting up::                 How to run a Lisp process using ILISP.

* Keybindings::                 A word about the keys used by ILISP.
* Buffers of ILISP::            Buffers used by ILISP, and their commands.
* ILISP Commands::
* Customization::               Description of ILISP variables and hooks.
* Dialects::                    How ILISP knows how to communicate with Lisp,
                                    and how to define new dialects.

Indices:
* Concept index::               General concepts.
* Key index::                   ILISP key sequences.
* Command index::               Commands by name.
* Variable index::              Variables and hooks that influence ILISP's
								   behavior.

* Function index::              Internal Emacs Lisp functions.
@end menu

@node Distribution, Acknowledgements, Top, Top
@unnumbered How to get the latest ILISP distribution.

ILISP is ``free''; this means that everyone is free to use it and free
to redistribute it on a free basis.  ILISP is not in the public domain;
it is copyrighted and there are restrictions on its distribution, but
these restrictions are designed to permit everything that a good
cooperating citizen would want to do.  What is not allowed is to try to
prevent others from further sharing any version of ILISP that they might
get from you.  The precise conditions appear in the file
@file{COPYING}.
@cindex @file{COPYING}

The easiest way to get a copy of ILISP is from someone else who has it.
You need not ask for permission to do so, or tell any one else; just
copy it.

General information on ILISP is available at:
@example
http://ilisp.cons.org/
@end example

The project site, which provides access to the CVS source tree, bug
database, mailing lists and other resources, is hosted at SourceForge:
@example
http://sourceforge.net/projects/ilisp/
@end example

The following mailing lists are available:
@table @file

@item ilisp-announce
Subscribe to this list if you want to receive public announcements
regarding ILISP.
@cindex @code{ilisp-announce} mailing list

@item ilisp-devel
This is the list for people who want to be actively involved in the
development of ILISP.
@cindex @code{ilisp-devel} mailing list

@item ilisp-help
This is the list for asking usage questions regarding ILISP.
@cindex @code{ilisp-help} mailing list

@item ilisp-cvs
Subscribe to this list @emph{only} if you want to monitor the CVS
repository activity.
@cindex @code{ilisp-cvs} mailing list
@end table

You can subscribe to the lists and access the archives via the general
information pages:
@itemize @bullet
@item
@code{http://lists.sourceforge.net/mailman/listinfo/ilisp-announce}

@item
@code{http://lists.sourceforge.net/mailman/listinfo/ilisp-devel}

@item
@code{http://lists.sourceforge.net/mailman/listinfo/ilisp-help}

@item
@code{http://lists.sourceforge.net/mailman/listinfo/ilisp-cvs}
@end itemize

You may send bug reports, questions, suggestions, etc. to
@file{ilisp-help} or @file{ilisp-devel}.  To report a bug you can also
switch to the buffer where the problem occurs, execute the @code{M-x
ilisp-bug} command and follow the displayed instructions.
@cindex Mailing lists
@cindex Reporting bugs
@cindex Bugs, reporting them
@pindex ilisp-bug

@menu
* FTP and Web directions::              FTP and Web directions
@end menu

@node FTP and Web directions, ,  , Distribution
@unnumberedsec FTP and Web directions
@cindex FTP site
@cindex Anonymous FTP
@cindex Downloading ILISP
@cindex Web site
@cindex How to get
@cindex Getting ILISP
@noindent
You can get the distribution file, @code{ilisp-x.y.z.tar.gz}
(@code{ilisp-x.y.z.zip}), via HTTP or anonymous FTP at the following
addresses:

@itemize @bullet
@item
@code{http://sourceforge.net/project/showfiles.php?group_id=3957}

@item
@code{http://www2.cons.org:8000/ftp-area/ilisp/}

@item
@code{ftp://ftp2.cons.org/pub/languages/lisp/ilisp/}

@end itemize

If you use a tty ftp client, just log in as 'anonymous'.

Please report any problems to the @file{ilisp-help} mailing list.
@xref{Distribution}.
@cindex @code{ilisp-help} mailing list

@noindent
Unpack and install:

@code{% @dfn{gzip -dc ilisp-x.y.z.tar.gz | tar xf -}}

@noindent
or

@code{% @dfn{unzip ilisp-x.y.z.zip}}

@xref{Installation}.


@node Acknowledgements, Features, Distribution, Top
@unnumbered Acknowledgements

ILISP replaces the standard inferior Lisp mode.  ILISP is based on
comint mode and derived from a number of different interfaces including
Symbolics, CMU Common Lisp, and Thinking Machines.

There are many people that have taken the time to report bugs, make
suggestions and even better send code to fix bugs or implement new
features.

Thanks to
Paolo Amoroso,
Martin Atzmueller,
David Bakash,
Daniel Barlow,
Guido Bosch,
Tim Bradshaw,
David Braunegg,
Thomas M. Breuel,
Craig Brozefsky,
Rick Campbell,
Hans Chalupsky,
Bill Clementson,
Kimball Collins,
William Deakin,
Brian Dennis,
David Duff,
Tom Emerson,
Michael Ernst,
Scott Fahlman,
Karl Fogel,
Dave Fox,
Paul Fuqua (for the CMU-CL GC display code),
David Gadbois,
Robert P. Goldman,
Marty Hall,
Richard Harris,
Utz-Uwe Haus,
Jim Healy,
Matthias Hoelzl,
Christopher Hoover,
Larry Hunter,
Ben Hyde,
Chuck Irvine,
Mark Kantrowitz,
Michael Kashket,
Matthias Koeppe,
Hannu Koivisto,
Qiegang Long,
Christian Lynbech,
Erik Naggum,
Alain Picard
Dan Pierson,
Yusuf Pisan,
Frank Ritter,
Ole Rohne,
Kevin Rosenberg,
Jeffrey Mark Siskind,
Neil Smithline,
Richard Stallman,
Larry Stead,
Jason Trenouth,
Christof Ullwer,
Reini Urban,
Bjorn Victor,
Edmund Weitz,
Fred White,
Ben Wing,
Matsuo Yoshihiro,
Jamie Zawinski
and many others for bug reports, suggestions and
code.  Our apologies to anyone we may have forgotten.

Special thanks to Todd Kaufmann for the texinfo file, work on bridge,
epoch-pop and for really exercising everything.

Please send bug reports, fixes and extensions to the @file{ilisp-devel}
mailing list so that they can be merged into the master
source. @xref{Distribution}.
@cindex @code{ilisp-devel} mailing list
@noindent
@example
--Chris McConnell                     1991-03-18
--Ivan Vazquez                        1993-06-27
--Marco Antoniotti and Rick Campbell  1996-10-25
--Marco Antoniotti and Paolo Amoroso  1999-08-19
@end example


@node Features, Installation, Acknowledgements, Top
@unnumbered Features
@cindex features

ILISP is an interface from GNU Emacs to an inferior Lisp.  It has the
following features:

@itemize @bullet
@item
Runs under Emacs 18 through 21, and XEmacs 19 through 21.

@item
Support for multiple Common Lisp (including Allegro, CLISP and CMU),
XLisp and Scheme dialects on multiple machines even at the same time.

@item
Dynamically sized pop-up windows that can be buried and scrolled from
any window.

@item
When the user sends an expression from a Lisp source buffer for
evaluation in an inferior Lisp process, ILISP automatically switches to
the package that is indicated at the beginning of the buffer.  The
expression is therefore read by the inferior Lisp process with the
correct current package.

@item
Evaluation and compilation of an entire file, or of a region, a
definition, or an s-expression of a buffer.  The user can specify for
ILISP to switch to the inferior Lisp buffer after evaluation or
compilation.  The user can also specify that a function definition
should be called after evaluation.  Evaluation and compilation can be
done either synchronously (ILISP waits for the answer), asynchronously
(ILISP does not wait), or in batch mode.

@item
Arglist, documentation, describe, inspect and macroexpand.

@item
Completion of filename components and Lisp symbols including partial matches.

@item
Find source both with and without help from the inferior Lisp,
including CLOS methods, multiple definitions and multiple files.


@item
Edit the callers of a function with and without help from the
inferior Lisp.

@item
Trace/untrace a function.

@item
@kbd{M-q} (``Fill-paragraph'') works properly on paragraphs in comments,
strings and code.

@item
Find unbalanced parentheses.

@item
ILISP has commands for closing all open parentheses of the current
``defun'' (in Emacs terminology).

@item
Handles editing, entering and indenting full Lisp expressions.

@item
Next, previous, and similar history mechanism compatible with comint.

@item
Handles Lisp errors.

@item
Uniform interface to Lisp debuggers.

@item
Result histories are maintained in the inferior Lisp.

@item
Does not create spurious symbols and handles case issues.

@item
Online manuals for ILISP and Common Lisp.

@end itemize

@node Installation, Starting up, Features, Top
@chapter How to install ILISP
@cindex Installation
Installation of ILISP and some initialization of your computing
environment are described in this chapter.  Please read the following
sections carefully before getting started with ILISP.

Copy the ILISP distribution archive, e.g. @code{ilisp-x.y.z.tar.gz}, to
the location where you would like to install it. Next extract the
archive, see @xref{FTP and Web directions}. You may need root privileges to
perform these operations.



@menu
* Configuration and compilation::
@end menu

@node  Configuration and compilation,  ,  , Installation
@comment  node-name,  next,  previous,  up
@section Configuration and compilation

Some configuration needs to be done before compiling the Emacs Lisp
files that comprise ILISP.  Start with the @file{Makefile} file, in the
section after the comment @code{Various variables} (you can
safely ignore the variables for configuring packaging and distribution,
which are intended for maintainers).

First, set the @code{EMACS} variable to be the pathname of the Emacs you
will be using ILISP with. This is the Emacs that will be used to compile
ILISP with. Be sure to set @code{LN} to the name of your operating
system's command for creating symbolic filesystem links,
@strong{especially if you are a Windows user}.

@cindex Compiling ILISP files
@cindex Byte-compiling ILISP files
@cindex @file{Makefile}
@findex ilisp-compile-inits
@vindex EMACS
@vindex LN
@vindex HyperSpec
@vindex ilisp-load-inits
@vindex ilisp-site-hook
@vindex ilisp-program
@vindex ilisp-init-binary-command
@vindex ilisp-init-binary-extension

If your Emacs supports the @code{easymenu} package, it is possible to
make ILISP add to Lisp mode buffers and buffers with inferior Lisp
processes, or to Scheme mode buffers and buffers with inferior Scheme
processes, an @code{Ilisp} menu with all available commands. To enable
this feature, set to @code{t} the variable
@code{ilisp-*enable-cl-easy-menu-p*} in @file{ilisp-def.el} for the Common
Lisp dialects, and @code{ilisp-*enable-scheme-easy-menu-p*} for Scheme
dialects. Setting these variables also causes the default @code{Lisp}
menu to be removed before displaying the @code{Ilisp} one.
@cindex @code{easymenu} package
@cindex @code{Ilisp} menu
@cindex @code{Lisp} menu
@vindex @code{ilisp-*enable-cl-easy-menu-p*}
@vindex @code{ilisp-*enable-scheme-easy-menu-p*}
@cindex @file{ilisp-def.el}

See the file @file{INSTALLATION} for additional configuration options
and known problems for specific Lisp dialects.
@cindex @file{INSTALLATION}

Run @code{make} or @code{make compile} to build ILISP from source.
Ignore any compilation warnings unless they result in ILISP not
compiling completely. If you are a Windows user, and you don't have GNU
@code{make}, you can still compile ILISP by running the
@file{icompile.bat} batch file (be sure to customize for your system the
variables mentioned by the comment at the top).
@pindex make
@pindex make compile
@cindex Windows, compiling under
@cindex @file{icompile.bat}

To activate ILISP you should add appropriate Emacs Lisp forms to your
@file{.emacs} or to the system-wide @file{default.el} file, depending on
who will be using ILISP. These forms take care of starting it whenever
you access a Lisp file or run an inferior Lisp process. You can copy
relevant portions of the sample file @file{ilisp.emacs}, which also
shows how to customize some ILISP features.
@cindex @file{ilisp.emacs}
@cindex @file{.emacs}
@cindex @file{default.el}

You should add the directory where all of the ILISP Emacs Lisp files
reside to your @code{load-path}.  There is an example of this in
@file{ilisp.emacs}.

As an alternative you could set up a @file{.ilisp} which contains the
appropriate portions of @file{ilisp.emacs}, in order to avoid cluttering
too much @file{.emacs} or @file{default.el}.

The first time a dialect is started, the interface files will complain
about not being compiled, just ignore the message.  Once a Lisp dialect
is started up, you should execute the command @code{ilisp-compile-inits}
which will compile the @file{*.lisp} files and write them to the same
directory as the ILISP files.@refill
@pindex ilisp-compile-inits
@cindex @file{.lisp} files

The binary files should have a unique
extension for each different combination of architecture and
Lisp dialect.  You will need to change
@code{ilisp-init-binary-extension} and
@code{ilisp-init-binary-command} to get additional
extensions.  The binary for each different architecture
should be different.  If you want to build the interface
files into a Lisp world, you will also need to set
@code{ilisp-load-inits} to @code{nil} in the same place that
you change @code{ilisp-program} to load the Lisp
world.@refill

There is an @code{ilisp-site-hook} for initializing site specific stuff
like program locations when ILISP is first loaded.  You may want to
define appropriate autoloads in your system Emacs start up
file.
@vindex ilisp-site-hook

Example site init:
@example
;;; CMU site
(setq ilisp-site-hook
      '(lambda ()
        (setq ilisp-motd "CMU ILISP V%s")
        (setq expand-symlinks-rfs-exists t)
        (setq allegro-program "/usr/local/acl5/lisp")
        (setq lucid-program "/usr/misc/.lucid/bin/lisp")))
@end example

Kent Pitman and Xanalys Inc. have made publicly available on the Web the
Common Lisp HyperSpec, an HTML version of the full text of the ANSI
Common Lisp specification:
@example
http://www.xanalys.com/software_tools/reference/HyperSpec/
@end example
It is also possible to get a local copy of the HyperSpec, whose latest
version is currently v6, by downloading the file
@code{HyperSpec-6-0.tar.gz} from the above mentioned site.

Daniel Barlow, Stephen Carney and Erik Naggum independently developed
Emacs Lisp packages for looking up Lisp symbols in the HyperSpec and
displaying the relevant sections with a Web browser. ILISP used to include all
of them in the @file{extra} directory of the distribution tree.
However, because of some changes to the CLHS only Erik Naggum's
version is now distributed.  If you want to use one of the
others, please contact the other authors.
@cindex ANSI Common Lisp
@cindex HyperSpec
@cindex Common Lisp HyperSpec
@cindex @file{extra}
@cindex Common Lisp Manual

The @file{ilisp.emacs} file provides sample instructions for making
Naggum's package access a local copy of the HyperSpec. Since the package
relies on the @code{browse-url} Emacs package, make sure that the latter
is properly configured.
@cindex @file{ilisp.emacs}
@cindex @code{browse-url}

Digital Press has made publicly available online, as a service to the
Lisp community, the full text of the book ``Common Lisp, The Language''
(by Guy L. Steele Jr., 2nd edition, Digital Press, 1990, ISBN
1-55558-041-6; a.k.a. ``CLtL2'') in a number of formats, including HTML.
ILISP provides support, contributed by Utz-Uwe Haus, for looking up Lisp
symbols in the HTML version of the book and displaying the relevant
sections with a Web browser.  See the file @file{extra/cltl2.el} for
more information on configuring this feature. @xref{Documentation
functions}, for usage instructions.
@cindex Common Lisp
@cindex CLtL2
@cindex Common Lisp Manual

The @file{ilisp.emacs} file provides sample instructions for making
ILISP's CLtL2 support access a local copy of the book.  What has been
said above about @code{browse-url} configuration also applies to CLtL2
lookup.
@cindex @file{ilisp.emacs}
@cindex @code{browse-url}

Note that, althougth Steele's book is a well written and useful resource,
it covers the Common Lisp language in the state it was a few years
before ANSI standardization.  If you need an accurate description of
ANSI Common Lisp, see the above mentioned HyperSpec instead.

Previous versions of ILISP provided commands for accessing the online
Common Lisp documentation shipped with Franz Inc.'s Allegro CL product
(@code{fi:clman} module). The public availability of the HyperSpec, and
the inclusion since version 5.9 of ILISP of the @code{hyperspec}
packages, make access to the Franz documentation no longer necessary. So
by default ILISP does not load the @code{fi:clman} module, but if you
still want to use its commands set the
@code{ilisp-*use-fi-clman-interface-p*} to @code{t} in
@file{ilisp-def.el}.
@pindex fi:clman
@cindex Allegro CL
@cindex Franz manual
@vindex ilisp-*use-fi-clman-interface-p*
@cindex @file{ilisp-def.el}

The ILISP documentation consists of a user manual and a reference card
(the latter may not be up to date). Both of them are in the @file{docs}
directory of the distribution tree.
@cindex Documentation
@cindex @file{docs}

The generation of GNU Info, DVI, PostScript and HTML versions of the
documentation from the Texinfo and TeX source is controlled by the
@file{Makefile} in the @file{docs} directory. Run @code{make docs} or
just @code{make} to generate all of the formats. If you are interested
in only some of them then issue the appropriate command: @code{make
info} for GNU Info, @code{make dvi} for DVI, @code{make ps} for
PostScript and @code{make html} for HTML. To remove the intermediate
files produced during the generation of DVI output you can run
@code{make tmpclean}. Note that some of the output formats may not be
supported for certain documents.
@cindex User manual
@cindex @file{Makefile}
@cindex @file{docs}
@pindex make
@pindex make docs
@pindex make info
@pindex make dvi
@pindex make ps
@pindex make html

The ILISP reference card is available as a TeX source file. Check the
comments at the beginning of the file if you need to generate a version
with a different number of columns (the default is 3).
@cindex Reference card


@c ==================================================================
@node Starting up, Keybindings, Installation, Top
@chapter How to run a Lisp process using ILISP
@cindex Running Lisp
@cindex Starting up Lisp
@cindex Supported dialects
@cindex Dialects supported
@pindex run-ilisp
@pindex common-lisp
@cindex Common Lisp
@pindex allegro
@cindex Allegro CL
@pindex lucid
@cindex Lucid Common Lisp
@pindex cmulisp
@cindex CMU Common Lisp
@pindex clisp-hs
@cindex CLISP
@pindex kcl
@cindex Kyoto Common Lisp
@pindex akcl
@cindex Austin Kyoto Common Lisp
@pindex gcl
@cindex GNU Common Lisp
@pindex ecl
@cindex EcoLisp
@pindex ibcl
@cindex Ibuki Common Lisp
@pindex scheme
@cindex Scheme
@pindex oaklisp
@cindex Oaklisp
@pindex sbcl
@cindex SB Common Lisp
@cindex SCM
@pindex scm
@cindex Chez Scheme
@pindex chez
@cindex STk
@pindex stk
@cindex Snow
@pindex snow
@cindex GUILE
@pindex guile
@cindex MzScheme
@pindex mzscheme
@cindex DrScheme-jr
@pindex drscheme-jr
@pindex xlisp
@cindex XLisp
@pindex xlispstat
@cindex XLisp-Stat
@pindex openmcl
@cindex OpenMCL
@pindex cormanlisp
@cindex Corman Lisp

To start a Lisp use @kbd{M-x run-ilisp}, or a specific dialect like
@kbd{M-x allegro}.  If one of these two functions is called with a
numerical prefix, the user will be prompted for a buffer name and a
program to run.  The default buffer name is the name of the dialect with
@code{*}s around it.  The default program for a dialect will be the value
of DIALECT-program or the value of ilisp-program inherited from a less
specific dialect.  If there are multiple Lisp's, use the dialect name or
@kbd{M-x select-ilisp} (@kbd{@key{C-z} S}) to select the current ILISP
buffer.

Entry into ILISP mode runs the hooks on @code{comint-mode-hook} and
@code{ilisp-mode-hook} and then DIALECT-hooks specific to Lisp
dialects in the nesting order above.  Many dialects call
@code{ilisp-load-init} in their dialect setup.

These are the currently supported dialects.

@itemize @bullet
@item @code{allegro}
Allegro Common Lisp from Franz Inc.

@item @code{akcl}
Austin Kyoto Common Lisp, the U. Texas derivative.

@item @code{chez}
Chez Scheme by Cadence Research Systems.

@item @code{clisp-hs}
CLISP by Haible and Stoll.

@item @code{cmulisp}
CMU Common Lisp, the major development platform for ILISP so far.

@item @code{cormanlisp}
Corman Common Lisp by Roger Corman.

@item @code{drscheme-jr}
DrScheme-jr by Rice University's PLT.

@item @code{common-lisp}
Generic Common Lisp.

@item @code{ecl}
EcoLisp, the Embeddable Common Lisp by Beppe Attardi. A derivative of
KCL and AKCL.

@item @code{gcl}
GNU Common Lisp, the official GNU release. A derivative of AKCL.

@item @code{guile}
GUILE Scheme by the GNU Project.

@item @code{ibcl}
Ibuki Common Lisp, derived from KCL.

@item @code{kcl}
Kyoto Common Lisp, original version.

@item @code{liquid}
Liquid Common Lisp, the successor of Lucid Common Lisp supported by
Xanalys/Harlequin Ltd.

@item @code{lispworks}
LispWorks Common Lisp from Xanalys/Harlequin Ltd.

@item @code{lucid}
Lucid Common Lisp, currently supported by Xanalys/Harlequin Ltd.

@item @code{mzscheme}
MzScheme by Rice University's PLT.

@item @code{oaklisp}
Oaklisp scheme.

@item @code{openmcl}
OpenMCL.

@item @code{sbcl}
Steel Bank Common Lisp

@item @code{scheme}
Generic Scheme.

@item @code{scm}
SCM Scheme by Aubrey Jeffer.

@item @code{snow}
Snow, STk Scheme without supoort for the Tk toolkit.

@item @code{stk}
STk scheme by Erick Gallesio.

@item @code{xlisp}
XLisp by David Betz.

@item @code{xlispstat}
XLisp-Stat, a derivative of XLisp for statistical computations.
@end itemize

@emph{Support for Scheme and XLisp dialects is experimental} and your
feedback is welcome. The @file{ilisp-s2c.el} file contains a first cut
at defining the Scheme->C dialect, but it is neither compiled nor loaded
by ILISP.
@cindex XLisp
@cindex XLisp-Stat
@cindex Scheme->C
@cindex @file{ilisp-s2c.el}

To define a new dialect, @xref{Defining new dialects}, and
@xref{Customization}. If anyone figures out support for other dialects,
I would be happy to include it in future releases.  @xref{Dialects}.

The currently supported dialects are listed below so that the
indentation correponds to the hierarchical relationship between
dialects:
@example
 common-lisp
   allegro
   clisp-hs
   cmulisp
   cormanlisp
   kcl
     akcl
       gcl
       ecl
     ibcl
   lispworks
   lucid
     liquid
   openmcl
   sbcl
 scheme
   chez
   guile
   mzscheme
     drscheme-jr
   oaklisp
   Scheme->C (still "in fieri")
   scm
   snow
   stk
 xlisp
   xlispstat
@end example


@c ==================================================================
@node Keybindings, Buffers of ILISP, Starting up, Top
@chapter A word about the keys used by ILISP
@cindex keybindings
@cindex FSF keyspace
@vindex ilisp-*use-fsf-compliant-keybindings*

By default, most ILISP commands are bound under the prefix key
@key{C-z}.  Unfortunately, these bindings predate the modern FSF Emacs
keyspace policies, which stipulate that packages should use @key{C-c} as
a prefix, and bind only control characters, digits, and a few specific
punctuation chars under that prefix.

If you are already accustomed to the old ILISP bindings, don't worry --
we haven't changed the default.  However, for new users who don't have
old habits to unlearn, ILISP offers FSF-compliant bindings as an
alternative to the default.  To be compliant (and who wouldn't want to
be compliant?), put this line in your @file{.emacs} or in the
system-wide @file{default.el} file:

@example
   (setq ilisp-*use-fsf-compliant-keybindings* t)
@end example

This will cause the ILISP prefix key to be @key{C-c}, and also change
some of the bindings underneath that prefix.  After you do this, ILISP
will be FSF-compliant.

Because the rest of this document was originally written for the old,
default ILISP bindings, you'll need to make some mental translations if
you choose FSF-compliance:

@itemize @bullet

@item
All key bindings are compliant with the FSF guidelines for major mode
key bindings. In some cases, there is an overlap with a key binding
that is defined in either standard Emacs or comint mode; however, in
these cases, the overlap is consistent with the FSF guideline that "it
is reasonable for a major mode to rebind a key sequence with a
standard meaning, if it implements a command that does 'the same job'
in a way that fits the major mode better".

@item
Where possible, mnemonic key bindings have been made to facilitate
ease of learning and frequently-used commands have been assigned to a
key binding that is easy to reach.

@item
All of the <query> related functions are set up on on @kbd{@key{C-c
C-q} C-<letter>} key bindings. Rationale: The "q" binding is a
mnemonic binding.

@item
All of the <eval> related functions are set up on on @kbd{@key{C-c
C-j} C-<letter>} key bindings. Rationale: @kbd{C-c C-j} is an easy
control key sequence to hit and the "eval" functions are used quite a
lot.

@item
All of the <compile> related functions are set up on on @kbd{@key{C-c
C-k} C-<letter>} key bindings. Rationale: @kbd{C-k} is mnemonic for
"kompile".

@item
All of the <action>-and-go-lisp functions are of the form
@kbd{@key{C-c C-<character>} M-<letter>}. The corresponding <action>
functions are set up on the @kbd{@key{C-c C-<character>} C-<letter>}
binding. Rationale: This is an easy sequence to remember - the
"and-go-lisp" function is just the exact same sequence as the ordinary
function but with the last character modified with Meta rather than
control.

@item
All of the <buffer/edit> related functions are set up on on
@kbd{@key{C-c C-v} C-<letter>} key bindings. Rationale: @kbd{C-c C-v}
is an easy control key sequence to hit and the "buffer/edit" functions
are used quite a lot.

@item
All of the <debug> related functions are set up on on @kbd{@key{C-c
C-b} C-<letter>} key bindings. Rationale: These are de"b"ugging
commands.

@end itemize

Remember that you can type @kbd{C-h m} at any time to see help on the
current major mode, which will show (among other things) a list of all
currently active keybindings.

@c ==================================================================
@node Buffers of ILISP, ILISP Commands, Keybindings, Top
@chapter Buffers used by ILISP, and their commands
@cindex buffers of ILISP
@cindex ILISP buffers
@table @code

@item *@var{dialect}*
The Lisp listener buffer.  Forms can be entered in this buffer in, and
they will be sent to Lisp when you hit return if the form is complete.
This buffer is in ilisp-mode, which is built on top of comint-mode, and
all comint commands such as history mechanism and job control are
available.
@c  xref..

@item @var{lisp-mode-buffers}
A buffer is assumed to contain Lisp source code if its major mode is in
the list @code{lisp-source-modes}.  If it's loaded into a buffer that is
in one of these major modes, it's considered a Lisp source file by
@code{find-file-lisp}, @code{load-file-lisp} and
@code{compile-file-lisp}.
Used by these commands to determine defaults.@refill

@item @code{*Completions*}
@cindex @code{*Completions*} buffer
Used for listing completions of symbols or files by the completion commands.
@xref{Completion}.

@item *Aborted Commands*
@cindex @code{*Aborted Commands*} buffer
@xref{Interrupts}.

@item *Errors*
@itemx *Output*
@itemx *Error Output*
@cindex @code{*Error Output*} buffer
@cindex @code{*Errors*} buffer
@cindex @code{*Output*} buffer
used to pop-up results and errors from the inferior Lisp.

@item *ilisp-send*
@cindex @code{*ilisp-send*} buffer
Buffer containing the last form sent to the inferior Lisp.

@item *Edit-Definitions*
@itemx *All-Callers*
@cindex @code{*Edit-Definitions*} buffer
@cindex @code{*All-Callers*} buffer
@xref{Source code commands}.

@item *Last-Changes*
@itemx *Changed-Definitions*
@cindex @code{*Last-Changes*} buffer
@cindex @code{*Changed-Definitions*} buffer
@xref{Batch commands}.

@item *Arglist-Output*
@cindex @code{*Arglist-Output*} buffer
A buffer for showing arglist messages.
@end table

@menu
* Typeout windows::              temporary windows used for display.
* Switching buffers::           Switching buffers
@end menu

@node Typeout windows, Switching buffers,  , Buffers of ILISP
@section Typeout windows
@cindex  Typeout windows

All ILISP output is funneled through the function which is bound to
the hook @code{ilisp-display-output-function}.  The function gets
a single argument, a string, and should make that output visible to
the user somehow.

One possible choice for output display is
@code{ilisp-display-output-in-typeout-window},
which pops up a window at the top of the current screen which is
just large enough to display the output.  This window can be
``remotely controlled'' by the commands @code{ilisp-scroll-output},
@code{ilisp-bury-output}, and @code{ilisp-grow-output}.

Unlike the old popper facility, the ilisp typeout window facility
does not trounce on any existing Emacs functions or on any common
key bindings, like @kbd{C-x o}.

Other built-in functions which might be useful as values for
@code{ilisp-display-output-function} include
@code{ilisp-display-output-default},
@code{ilisp-display-output-adaptively},
@code{ilisp-display-output-in-lisp-listener},
@code{ilisp-display-output-in-temp-buffer}, and
@code{ilisp-display-output-in-typeout-window}.

The default display function is @code{ilisp-display-output-default},
which obeys the @code{lisp-no-popper} variable.

Users are encouraged to write their own output display functions
to get the exact desired behavior, displaying on a private Emacs
screen, in a pop-up dialog box, or whetever.


@table @kbd

@item @key{C-z} 1   (ilisp-bury-output)
deletes and buries the typeout output window.
@kindex @key{C-z} 1
@pindex ilisp-bury-output
@cindex bury output window


@item @key{C-z} v   (ilisp-scroll-output)
scrolls the output window if it is showing, otherwise does nothing.
If it is called with a negative prefix, it will scroll backwards.
@cindex scrolling output
@pindex ilisp-scroll-output
@kindex @key{C-z} v

@item @key{C-z} G   (ilisp-grow-output)
will grow the output window if showing by the prefix number of lines.
@cindex grow output window
@pindex ilisp-grow-output
@kindex @key{C-z} G

@end table

An alternative to typeout windows is to always have the inferior Lisp
buffer visible and have all output go there.  Setting
@code{lisp-no-popper} to @code{t} will cause all output to go to the
inferior Lisp buffer.  Setting @code{lisp-no-popper} to @code{'message}
will make output of one line go to the message window. Setting
@code{comint-always-scroll} to @code{t} will cause process output to
always be visible.  If a command gets an error, you will be left in the
break loop.@refill

@cindex Turning off typeout windows
@vindex comint-always-scroll
@vindex lisp-no-popper



@node Switching buffers,  ,Typeout windows, Buffers of ILISP
@section Switching buffers

Commands to make switching between buffers easier.
@cindex Switching buffers

@table @kbd
@item @key{C-z} b   (switch-to-lisp)
@kindex @key{C-z} b
@pindex switch-to-lisp
will pop to the current ILISP buffer or if already in an ILISP buffer,
it will return to the buffer that last switched to an ILISP buffer.
With a prefix, it will also go to the end of the buffer.  If you do not
want it to pop, set @code{pop-up-windows} to nil.
@vindex pop-up-windows


@item M-C-l   (previous-buffer-lisp)
will switch to the last visited buffer in the current window or the Nth
previous buffer with a prefix.
@cindex Previous lisp buffer
@pindex previous-buffer-lisp
@kindex M-C-l

@end table


@node ILISP Commands, Customization, Buffers of ILISP, Top
@chapter ILISP Commands


Most of these key bindings work in both Lisp Mode and ILISP mode.
There are a few additional and-go bindings found in Lisp Mode.


@menu
* Eval and compile functions::
* Documentation functions::
* Macroexpansion::
* Tracing functions::
* Package Commands::
* Source code commands::        Working on several files
* Batch commands::              Grouping changes for eval/compile
* Files and directories::
* Keyboard modes::              Interactive and raw keyboard modes
* Interrupts::                  Interrupts, aborts, and errors
* Debuggers::                   Interface to Lisp debuggers
* Command history::
* Completion::
* Miscellany::                  Indentation, parenthesis balancing,
				  and comment commands.
@end menu

@node Eval and compile functions, Documentation functions,  , ILISP Commands
@section Eval and compile functions
@cindex Eval/compile commands
@cindex Compile/eval commands

In Lisp, the major unit of interest is a form, which is anything between
two matching parentheses.  Some of the commands here also refer to
``defun,'' which is a list that starts at the left margin in a Lisp
buffer, or after a prompt in the ILISP buffer.  These commands refer to
the ``defun'' that contains the point.
@cindex Defun

``A call'' refers to a reference to a function call for a function or
macro, or a reference to a variable.  Commands which ``insert a call''
in the ILISP buffer will bring up the last command which matches it or
else will insert a template for a call.
@cindex Call

When an eval is done of a single form matching @code{ilisp-defvar-regexp}
the corresponding symbol will be unbound and the value assigned again.
@vindex ilisp-defvar-regexp

When you send a form to Lisp, the status light will reflect the progress
of the command.  In a Lisp mode buffer the light will reflect the status
of the currently selected inferior Lisp unless @code{lisp-show-status}
is nil. The very first inferior Lisp command executed may send some
forms to initialize the inferior Lisp. If you want to find out what
command is currently running, use the command @kbd{@key{C-z} s}
(status-lisp).  If you call it with a prefix, the pending commands will
be displayed as well.@refill
@cindex Currently running command
@cindex Displaying commands
@pindex status-lisp
@kindex @key{C-z} s
@vindex lisp-show-status
@cindex Status light
@cindex Modeline status

Note that in this table as elsewhere, the key @key{C-z} (ilisp-*prefix*)
is used as a prefix character for ILISP commands, though this may be
changed.
@kindex @key{C-z} prefix
@vindex ilisp-*prefix*
@c xref .. custom? or autoload?
For a full list of key-bindings, use @kbd{M-x describe-mode} or
@kbd{M-x describe-bindings} while in an ILISP-mode buffer.@refill
@cindex Listing bindings
@cindex Describing bindings


The eval/compile commands verify that their expressions are balanced and
then send the form to the inferior Lisp.  If called with a positive
prefix, the result of the operation will be inserted into the buffer
after the form that was just sent.
@cindex Inserting results

For commands which operate on a region, the result of the compile or eval
is the last form in the region.
@cindex Region commands

The @samp{and-go} versions will perform the operation and then
immediately switch to the ILISP buffer where you will see the results of
executing your form.  If @code{eval-defun-and-go-lisp} or
@code{compile-defun-and-go-lisp} is called with a prefix, a call for the
form will be inserted as well.@refill
@cindex Inserting calls
@pindex compile-defun-and-go-lisp
@pindex eval-defun-and-go-lisp
@cindex @samp{and-go} functions

@table @kbd

@item @key{C-z}
The prefix-key for most ILISP commands.  This can be changed by setting
the variable @code{ilisp-*prefix*}.
@c xref custom?

@item RET   (return-ilisp)
In ILISP-mode buffer, sends the current form to lisp if complete,
otherwise creates a new line and indents.  If you edit old input, the
input will be copied to the end of the buffer first and then sent.
@cindex Sending input to Lisp
@pindex return-ilisp
@kindex RET

@item C-]   (close-and-send-lisp)
Closes the current sexp, indents it, and then sends it to the current
inferior Lisp.
@pindex close-and-send-lisp
@kindex C-]

@item LFD   (newline-and-indent-lisp)
Insert a new line and then indent to the appropriate level.  If called
at the end of the inferior Lisp buffer and an sexp, the sexp will be
sent to the inferior Lisp without a trailing newline.
@pindex newline-and-indent-lisp
@kindex LFD

@item @key{C-z} e   (eval-defun-lisp)
@itemx M-C-x   (eval-defun-lisp)
@itemx @key{C-z} C-e   (eval-defun-and-go-lisp)
@kindex M-C-x
@kindex @key{C-z} e
@kindex @key{C-z} C-e
Send the defun to Lisp.
@pindex eval-defun-and-go-lisp
@pindex eval-defun-lisp

@item @key{C-z} r   (eval-region-lisp)
@itemx @key{C-z} C-r   (eval-region-and-go-lisp)
@kindex @key{C-z} r
@pindex eval-region-lisp
@kindex @key{C-z} C-r
@pindex eval-region-and-go-lisp
@cindex Eval region

@item @key{C-z} n   (eval-next-sexp-lisp)
@itemx @key{C-z} C-n   (eval-next-sexp-and-go-lisp)
@kindex @key{C-z} n
@pindex eval-next-sexp-lisp
@kindex @key{C-z} C-n
@pindex eval-next-sexp-and-go-lisp

@item @key{C-z} o   (eval-last-sexp-lisp)
@itemx @key{C-z} C-o   (eval-last-sexp-and-go-lisp)
@kindex @key{C-z} o
@pindex eval-last-sexp-lisp
@kindex @key{C-z} C-o
@pindex eval-last-sexp-and-go-lisp

@item @key{C-z} j   (eval-dwim-lisp)
@itemx @key{C-z} C-j   (eval-dwim-and-go-lisp)
@kindex @key{C-z} j
@pindex eval-dwim-lisp
@kindex @key{C-z} C-j
Evaluate DWIM (Do What I Mean).
If a region is selected, evaluate the region.  If the cursor is on or
immediately after a ')', evaluate the last sexp.  If the cursor is on
or immediately before a '(', evaluate the next sexp. If the cursor is
inside a defun, evaluate the defun. If the cursor is inside a
top-level sexp, evaluate the top-level sexp. Tests are done in the
order specified in these comments, so if there is any ambiguity, make
certain that the cursor is either on a parenthesis (for the eval
last/next commands or not directly before/after/on a parenthesis for
the eval defun/top-level commands.
@pindex eval-dwim-and-go-lisp

@item @key{C-z} c   (compile-defun-lisp)
@kindex @key{C-z} c
@pindex compile-defun-lisp
@item @key{C-z} C-c   (compile-defun-lisp-and-go)
@kindex @key{C-z} C-c
When @code{compile-defun-lisp} is called in an inferior Lisp buffer with
no current form, the last form typed to the top-level will be compiled.
@cindex Compile last form
@pindex compile-defun-lisp-and-go

@item @key{C-z} w   (compile-region-lisp)
@itemx @key{C-z} C-w   (compile-region-and-go-lisp)
@kindex @key{C-z} w
@pindex compile-region-lisp
@kindex @key{C-z} C-w
@pindex compile-region-and-go-lisp
@cindex Compile region

@end table


If any of the forms contain an interactive command, then the command
will never return.  To get out of this state, you need to use
@code{abort-commands-lisp} (@kbd{@key{C-z} g}).  If @code{lisp-wait-p}
is t, then EMACS will display the result of the command in the
minibuffer or a pop-up window.  If @code{lisp-wait-p} is @code{nil},
(the default) the send is done asynchronously and the results will be
brought up only if there is more than one line or there is an error.  In
this case, you will be given the option of ignoring the error, keeping
it in another buffer or keeping it and aborting all pending sends.  If
there is not a command already running in the inferior Lisp, you can
preserve the break loop.  If called with a negative prefix, the sense of
@code{lisp-wait-p} will be inverted for the next command.
@c @cindex Aborting commands
@vindex lisp-wait-p
@kindex @key{C-z} g
@pindex abort-commands-lisp



@node Documentation functions, Macroexpansion, Eval and compile functions, ILISP Commands
@section Documentation functions

@code{describe-lisp}, @code{inspect-lisp}, @code{arglist-lisp}, and
@code{documentation-lisp} switch whether they prompt for a response or
use a default when called with a negative prefix.  If they are
prompting, there is completion through the inferior Lisp by using
@kbd{TAB} or @kbd{M-TAB}.  When entering an expression in the
minibuffer, all of the normal ILISP commands like @code{arglist-lisp}
also work.@refill
@cindex Describing Lisp objects
@kindex M-TAB
@kindex TAB
@cindex Negative prefix
@cindex Minibuffer completion
@pindex describe-lisp
@cindex Documentation Functions

Commands that work on a function will use the nearest previous function
symbol.  This is either a symbol after a @samp{#'} or the symbol at the
start of the current list.

The @code{fi:clman} and @code{fi:clman-apropos} commands for accessing
the Franz Allegro CL documentation are not enabled by default.
@xref{Configuration and compilation}.
@cindex Allegro CL
@cindex Franz manual

@table @code

@item @key{C-z} a   (arglist-lisp)
@cindex Arglist Lisp
@kindex @key{C-z} a
@pindex arglist-lisp
Return the arglist of the current function.  With a numeric prefix, the
leading paren will be removed and the arglist will be inserted into the
buffer.

@item @key{SPC}   (ilisp-arglist-message-lisp-space)
@cindex Arglist Lisp
@kindex @key{SPC}
@pindex ilisp-arglist-message-lisp-space
@vindex ilisp-*arglist-message-lisp-space-p*
Display the value of the argument list of a symbol followed by
@key{SPC}. @emph{To enable this feature you have to set
@code{ilisp-*arglist-message-lisp-space-p*} to @code{t}.}

@item @key{C-z} d   (documentation-lisp)
@kindex @key{C-z} d
@pindex documentation-lisp
Infers whether function or variable documentation is desired.  With a
negative prefix, you can specify the type of documentation as well.
With a positive prefix the documentation of the current function call is
inserted into the buffer.

@item @key{C-z} i   (describe-lisp)
@kindex @key{C-z} i
Describe the previous sexp (it is evaluated).  If there is no previous
sexp and if called from inside an ILISP buffer, the previous result will
be described.

@item @key{C-z} I   (inspect-lisp)
@kindex @key{C-z} I
@pindex inspect-lisp
Switch to the current inferor Lisp and inspect the previous sexp (it is
evaluated).  If there is no previous sexp and if called from inside an
ILISP buffer, the previous result will be inspected.

@item @key{C-z} H   (hyperspec-lookup)
@kindex @key{C-z} H
@pindex hyperspec-lookup
Look up a standard symbol in the Common Lisp HyperSpec and display the
relevant section.
@cindex HyperSpec
@cindex Common Lisp HyperSpec

@item @key{C-z} L or @key{C-z} M-l   (cltl2-lookup)
@kindex @key{C-z} L
@kindex @key{C-z} M-l
@pindex cltl2-lookup
Look up a Common Lisp symbol in the CLtL2 book and display the relevant
section.
@cindex CLtL2

@item @key{C-z} D   (fi:clman)
@itemx @key{C-z} A   (fi:clman-apropos)
@kindex @key{C-z} D
@pindex fi:clman
@kindex @key{C-z} A
@pindex fi:clman-apropos
If the Franz online Common Lisp manual is available, get information on
a specific symbol.  @code{fi:clman-apropos} will get information apropos
a specific string.  Some of the documentation is specific to the Allegro
dialect, but most of it is for standard Common Lisp.
@cindex Apropos help
@cindex Common Lisp manual
@cindex Franz manual

@end table


@node Macroexpansion, Tracing functions, Documentation functions, ILISP Commands
@section Macroexpansion

@table @kbd
@item @key{C-z} M   (macroexpand-lisp)
@itemx @key{C-z} m   (macroexpand-1-lisp)
@kindex @key{C-z} M
@pindex macroexpand-lisp
@kindex @key{C-z} m
@pindex macroexpand-1-lisp
These commands apply to the next sexp.  If called with a positive
numeric prefix, the result of the macroexpansion will be inserted into
the buffer.  With a negative prefix, prompts for expression to expand.
@cindex Expanding macro forms
@cindex Macroexpansion


@end table

@node Tracing functions, Package Commands, Macroexpansion, ILISP Commands
@section Tracing functions

@table @kbd
@item @key{C-z} t   (trace-defun-lisp)
@kindex @key{C-z} t
@pindex trace-defun-lisp
@cindex Tracing defuns
@cindex Untracing defuns
traces the current defun.   When called with a numeric prefix the
function will be untraced.  When called with negative prefix, prompts
for function to be traced.
@item @key{C-z} C-t   (trace-defun-lisp-break)
@kindex @key{C-z} C-t
@pindex trace-defun-lisp-break
@cindex Tracing defuns
@cindex Untracing defuns
traces the current defun and enters the debugger whenever that function
is invoked.  When called with a numeric prefix the function will be
untraced.  When called with negative prefix, prompts for function to be
traced.
@end table

@node Package Commands, Source code commands, Tracing functions, ILISP Commands
@section Package Commands
@cindex Package commands

The first time an inferior Lisp mode command is executed in a Lisp Mode
buffer, the package will be determined by using the regular expression
@code{ilisp-hash-form-regexp} to find a package sexp and then passing that
sexp to the inferior Lisp through @code{ilisp-package-command}.  For the
@samp{common-lisp} dialect, this will find the first @code{(in-package
PACKAGE)} form in the file.  A buffer's package will be displayed in the
mode line.  If a buffer has no specification, forms will be evaluated in
the current inferior Lisp package.@refill

Buffer package caching can be turned off by setting the variable
@code{lisp-dont-cache-package} to @code{T}.  This will force ILISP to
search for the closest previous "in-package" form corresponding to
@code{ilisp-hash-form-regexp} in the buffer each time an inferior Lisp
mode command is executed.
@cindex Buffer package
@cindex Buffer package caching
@vindex lisp-dont-cache-package
@vindex ilisp-hash-form-regexp
@findex ilisp-package-command
@cindex In-package form

@table @code

@item @key{C-z} P   (set-package-lisp)
@kindex @key{C-z} P
@pindex set-package-lisp
Set the inferior Lisp package to the current buffer's package or with a
prefix to a manually entered package.

@item @key{C-z} p   (set-buffer-package-lisp)
@kindex @key{C-z} p
@cindex Set buffer package
@pindex set-buffer-package-lisp
Set the buffer's package from the buffer.  If it is called with a
prefix, the package can be set manually.

@end table

@node Source code commands, Batch commands, Package Commands, ILISP Commands
@section Source Code Commands
@cindex Source Code Commands
@cindex Finding source

The following commands all deal with finding things in source code.
The first time that one of these commands is used, there may be some
delay while the source module is loaded.  When searching files, the
first applicable rule is used:
@itemize @bullet
@item
try the inferior Lisp,
@item
try a tags file if defined,
@item
try all buffers in one of @code{lisp-source-modes} or all files
defined using @code{lisp-directory}.@refill
@pindex lisp-directory
@vindex lisp-source-modes
@end itemize

@code{M-x lisp-directory} defines a set of files to be
searched by the source code commands.  It prompts for a directory and
sets the source files to be those in the directory that match entries
in @code{auto-mode-alist} for modes in @code{lisp-source-modes}.
With a positive
prefix, the files are appended.  With a negative prefix, all current
buffers that are in one of @code{lisp-source-modes} will be searched.  This
is also what happens by default.  Using this command stops using a
tags file.@refill
@cindex Source modes
@vindex auto-mode-alist
@kindex M-x lisp-directory

@code{edit-definitions-lisp}, @code{who-calls-lisp}, and
@code{edit-callers-lisp} will switch whether they prompt for a response
or use a default when called with a negative prefix.  If they are
prompting, there is completion through the inferior Lisp by using
@kbd{TAB} or @kbd{M-TAB}.  When entering an expression in the
minibuffer, all of the normal ILISP commands like @kbd{arglist-lisp}
also work.@refill
@pindex edit-callers-lisp
@pindex who-calls-lisp
@pindex edit-definitions-lisp

@code{edit-definitions-lisp} (@kbd{M-.}) will find a
particular type of definition for a symbol.  It tries to use the rules
described above.  The files to be searched are listed in the buffer
@code{*Edit-Definitions*}.  If @code{lisp-edit-files} is nil, no search will be
done if not found through the inferior Lisp.  The variable
@code{ilisp-locator} contains a function that when given the name and type
should be able to find the appropriate definition in the file.  There
is often a flag to cause your Lisp to record source files that you
will need to set in the initialization file for your Lisp.  The
variable is @code{*record-source-files*} in both allegro and lucid.  Once a
definition has been found, @code{next-definition-lisp}
(@kbd{M-,}) will find the next definition
(or the previous definition with a prefix).@refill
@pindex next-definition-lisp
@vindex *record-source-files*
@vindex ilisp-locator
@vindex lisp-edit-files
@cindex @code{*Edit-Definitions*} buffer
@kindex M-.

@code{edit-callers-lisp} (@kbd{@key{C-z} ^}) will generate a list of all
of the callers of a function in the current inferior Lisp and edit the
first caller using @code{edit-definitions-lisp}.  Each successive call to
@code{next-caller-lisp} (@kbd{M-`}) will edit the next caller
(or the previous caller with a prefix).  The list is stored in the
buffer @code{*All-Callers*}.  You can also look at the callers by doing
@kbd{M-x who-calls-lisp}.@refill
@cindex List callers
@cindex Find callers
@cindex @code{*All-Callers*} buffer
@kindex M-x who-calls-lisp
@kindex M-`
@pindex next-caller-lisp
@kindex @key{C-z} ^
@pindex edit-callers-lisp

@code{search-lisp} (@kbd{M-?}) will search the current tags files,
@code{lisp-directory} files or buffers in one of @code{lisp-source-modes} for a
string or a regular expression when called with a prefix.
@code{next-definition-lisp} (@kbd{M-,}) will find the next definition
(or the previous definition with a prefix).@refill
@cindex Next definition
@cindex Previous definition
@kindex M-,
@pindex next-definition-lisp
@kindex M-?
@pindex search-lisp

@code{replace-lisp} (@kbd{M-"}) will replace a string (or a regexp with
a prefix) in the current tags files, @code{lisp-directory} files or
buffers in one of @code{lisp-source-modes}.@refill
@cindex Replace lisp
@kindex M-"
@pindex replace-lisp


Here is a summary of the above commands (behavior when given prefix
argument is given in parentheses):

@table @code
@item M-x lisp-directory
Define a set of files to be used by the source code commands.

@item M-.   (edit-definitions-lisp)
Find definition of a symbol.

@item M-,   (next-definition-lisp)
Find next (previous) definition.

@item @key{C-z} ^   (edit-callers-lisp)
Find all callers of a function, and edit the first.

@item M-`   (next-caller-lisp)
Edit next (previous) caller of function set by @code{edit-callers-lisp}.

@item M-x who-calls-lisp
List all the callers of a function.


@item M-?   (search-lisp)
Search for string (regular expression) in current tags,
@code{lisp-directory} files or buffers.  Use @code{next-definition-lisp}
to find next occurence.

@item M-"   (replace-lisp)
Replace a string (regular expression) in files.

@end table


@node Batch commands, Files and directories, Source code commands, ILISP Commands
@section Batch commands


The following commands all deal with making a number of changes all at
once.  The first time one of these commands is used, there may be some
delay as the module is loaded.  The eval/compile versions of these
commands are always executed asynchronously.
@cindex Group changes
@cindex File changes
@cindex Change commands

@code{mark-change-lisp} (@kbd{@key{C-z} SPC}) marks the current defun as
being changed.  A prefix causes it to be unmarked.  @code{clear-changes-lisp}
(@kbd{@key{C-z} * 0}) will clear all of the changes.
@code{list-changes-lisp} (@kbd{@key{C-z} * l}) will show the forms
currently marked.@refill
@cindex Marking changes
@cindex Clearing changes
@cindex Listing changes
@kindex @key{C-z} * l
@kindex @key{C-z} * 0
@kindex @key{C-z} SPC
@pindex list-changes-lisp
@pindex clear-changes-lisp
@pindex mark-change-lisp

@code{eval-changes-lisp} (@kbd{@key{C-z} * e}), or
@code{compile-changes-lisp} (@kbd{@key{C-z} * c}) will
evaluate or compile these changes as appropriate.
If called with a positive prefix, the changes will be kept.
If there is an error, the process will stop and show the error
and all remaining changes will remain in the list.  All of the results
will be kept in the buffer @code{*Last-Changes*}.@refill
@cindex Eval'ing changes
@cindex Compiling changes
@cindex @code{*Last-Changes*} buffer
@kindex @key{C-z} * e
@kindex @key{C-z} * c
@pindex compile-changes-lisp
@pindex eval-changes-lisp

@noindent
Summary:

@table @code
@item @key{C-z} SPC   (mark-change-lisp)
Mark (unmark) current defun as changed.
@item @key{C-z} * e   (eval-changes-lisp)
@itemx @key{C-z} * c   (compile-changes-lisp)
Call with a positive prefix to keep changes.
@item @key{C-z} * 0   (clear-changes-lisp)
@item @key{C-z} * l   (list-changes-lisp)
@end table


@node Files and directories, Keyboard modes, Batch commands, ILISP Commands
@section Files and directories

@cindex Files and directories
@cindex Directories and files
@cindex Current directory
File commands in Lisp source-mode buffers keep track of the last used
directory and file.  If the point is on a string, that will be the
default if the file exists.  If the buffer is one of
@code{lisp-source-modes}, the buffer file will be the default.  Otherwise,
the last file used in a lisp-source-mode will be used.


@table @kbd
@item C-x C-f   (find-file-lisp)
@kindex C-x C-f
@cindex Find file
@cindex Lisp find file
@cindex Symbolic link expansion
@pindex find-file-lisp
will find a file.  If it is in a string, that will be used as the
default if it matches an existing file.  Symbolic links are expanded so
that different references to the same file will end up with the same
buffer.

@item @key{C-z} l   (load-file-lisp)
@kindex @key{C-z} l
will load a file into the inferior Lisp.  You will be given the
opportunity to save the buffer if it has changed and to compile the file
if the compiled version is older than the current version. For
@file{<whatever>.system} files, which are used by DEFSYSTEM tools, no
compilation or loading of possibly existing
@file{<whatever>.binary-extension} is attempted.
@pindex load-file-lisp
@cindex Loading files
@cindex DEFSYSTEM files
@cindex System definition files

@item @key{C-z} k   (compile-file-lisp)
@kindex @key{C-z} k
will compile a file in the current inferior Lisp.
@pindex compile-file-lisp
@cindex Compiling files

@item @key{C-z} !   (default-directory-lisp)
@kindex @key{C-z} !
sets the default inferior Lisp directory to the directory of the current
buffer.  If called in an inferior Lisp buffer, it sets the Emacs
@code{default-directory} to the Lisp default directory.
@vindex default-directory
@cindex Default directory
@cindex Set default directory
@pindex default-directory-lisp

@end table

@node Keyboard modes, Interrupts, Files and directories, ILISP Commands
@section Switching between interactive and raw keyboard modes

@cindex Raw keyboard mode
@cindex Interactive keyboard mode
@vindex ilisp-raw-echo

There are two keyboard modes for interacting with the inferior Lisp,
``interactive'' and ``raw''.  Normally you are in interactive mode
where keys are interpreted as commands to EMACS and nothing is sent to
the inferior Lisp unless a specific command does so.  In raw mode, all
characters are passed directly to the inferior Lisp without any
interpretation as EMACS commands.  Keys will not be echoed unless
ilisp-raw-echo is T.

@pindex raw-keys-ilisp
@kindex @key{C-z} #
@pindex io-bridge-ilisp
@kindex M-x io-bridge-ilisp

Raw mode can be turned on interactively by the command
@code{raw-keys-ilisp} (@kbd{@key{C-z} #}) and will continue until you
type @key{C-g}.  Raw mode can also be turned on/off by inferior Lisp
functions if the command @code{io-bridge-ilisp} (@code{M-x
io-bridge-ilisp}) has been executed in the inferior Lisp either
interactively or on a hook.  To turn on raw mode, a function should
print @code{^[1^]} and to turn it off should print @code{^[0^]}.  An
example in Common Lisp would be:

@code{(progn (format t "^[1^]") (print (read-char)) (format t "^[0^]"))}

@node Interrupts, Debuggers, Keyboard modes, ILISP Commands
@section Interrupts, aborts, and errors


If you want to abort the last command you can use @kbd{C-g}.
@kindex C-g
@cindex Errors
@cindex Aborting commands
@cindex Interrupting commands

If you want to abort all commands, you should use the command
@code{abort-commands-lisp} (@kbd{@key{C-z} g}).  Commands that are
aborted will be put in the buffer @code{*Aborted Commands*} so that
you can see what was aborted.  If you want to abort the currently
running top-level command, use @code{interrupt-subjob-ilisp} (@kbd{C-c
C-c}).  As a last resort, @kbd{M-x panic-lisp} will reset the ILISP
state without affecting the inferior Lisp so that you can see what is
happening.

@pindex interrupt-subjob-ilisp
@cindex @code{*Aborted Commands*} buffer
@kindex @key{C-z} g
@pindex abort-commands-lisp
@pindex panic-lisp

@code{delete-char-or-pop-ilisp} (@kbd{C-d}) will delete
prefix characters unless you are at the end of an ILISP buffer in
which case it will pop one level in the break loop.
@cindex Pop in break loop
@cindex Break loop
@kindex C-d
@pindex delete-char-or-pop-ilisp

@code{reset-ilisp}, (@kbd{@key{C-z} z}) will reset the current inferior
Lisp's top-level so that it will no longer be in a break loop.
@cindex Resetting Lisp
@cindex Top-level, return to
@kindex @key{C-z} z
@pindex reset-ilisp


Summary:

@table @kbd
@item C-c C-c   (interrupt-subjob-ilisp)
Send a keyboard interrupt signal to lisp.
@item @key{C-z} g    (abort-commands-lisp)
Abort all running or unsent commands.
@item M-x panic-lisp (panic-lisp)
Reset the ILISP process state.
@item @key{C-z} z   (reset-ilisp)
Reset Lisp to top-level.
@item C-d   (delete-char-or-pop-ilisp)
If at end of buffer, pop a level in break loop.

@end table

@c duplicated from eval section.
If @code{lisp-wait-p} is @code{nil}  (the default),
all sends are done asynchronously and the results will be
brought up only if there is more than one line or there is an error.
In case, you will be given the option of ignoring the error, keeping
it in another buffer or keeping it and aborting all pending sends.
If there is not a command already running in the inferior Lisp, you can
preserve the break loop.  If called with a negative prefix, the sense of
@code{lisp-wait-p} will be inverted for the next command.
@vindex lisp-wait-p



@node Debuggers, Command history, Interrupts, ILISP Commands
@section Interface to Lisp debuggers
@cindex Debugger interface
@cindex Interface to Lisp debuggers
@cindex ILD

ILD is an interface to Lisp debuggers, currently the ones of the AKCL,
Allegro, CLISP, CMU CL, Corman Lisp and Lucid Common Lisp dialects. It
uses a standard set of single-keystroke commands to interface to a
variety of different debuggers and is vaguely modelled after the
Symbolics debugger. It provides two key advantages: single keystrokes
for moving up and down the stack, and a uniform interface to different
debuggers.

Not all debugger commands are available in all implementations. Some
are, but further work is needed. These are noted in the code (see the
dialect definition files). If you know how to fix them please contact
the ILISP maintainer.

Here is a list of the available ILD commands:

@table @kbd
@item M-a   (ild-abort)
Abort.
@pindex ild-abort
@kindex M-a
@cindex Aborting from a debugger
@item M-c   (ild-continue)
Continue.
@pindex ild-continue
@kindex M-c
@cindex Continuing from a debugger
@item M-C-n   (ild-next)
Next stack frame (with numeric argument @emph{n}, move to the next
@emph{n}-th stack frame).
@pindex ild-next
@kindex M-C-n
@cindex Next stack frame
@cindex Stack frames
@item M-C-p   (ild-previous)
Previous stack frame (with numeric argument @emph{n}, move to the
previous @emph{n}-th stack frame).
@pindex ild-previous
@kindex M-C-p
@cindex Previous stack frame
@cindex Stack frames
@item C-c <   (ild-top)
Top stack frame.
@pindex ild-top
@kindex C-c <
@cindex Top stack frame
@cindex Stack frames
@item C-c >   (ild-bottom)
Bottom stack frame.
@pindex ild-bottom
@kindex C-c >
@cindex Bottom stack frame
@cindex Stack frames
@item M-b   (ild-backtrace)
Backtrace.
@pindex ild-backtrace
@kindex M-b
@cindex Stack backtrace
@cindex Backtrace
@item M-C-d   (ild-locals)
Display all local variables.
@pindex ild-locals
@kindex M-C-d
@cindex Displaying local variables
@cindex Local variables
@item M-C-l   (ild-local)
Display a particular local variable (with numeric argument @emph{n},
display the @emph{n}-th local variable).
@pindex ild-local
@kindex M-C-l
@cindex Displaying local variables
@cindex Local variables
@item M-C-s   (ild-step)
Step to the next breakpoint.
@pindex ild-step
@kindex M-C-s
@cindex Stepping to next breakpoint
@item C-c r   (ild-return)
Return.
@pindex ild-return
@kindex C-c r
@cindex Returning from a debugger
@item M-C-r   (ild-retry)
Retry.
@pindex ild-retry
@kindex M-C-r
@cindex Retrying from a debugger
@item C-x t   (ild-trap-on-exit)
Trap on exit.
@pindex ild-trap-on-exit
@kindex C-x t
@cindex Trapping on exit from a debugger
@item C-c L   (select-lisp)
Select Lisp interaction buffer.
@pindex select-lisp
@kindex C-c L
@cindex Selecting a Lisp interaction buffer
@item @key{C-z} C-s   (slow-lisp)
Set compiler options for maximal debuggability.
@pindex slow-lisp
@kindex @key{C-z} C-s
@cindex Setting compiler options
@cindex Compiler options
@item @key{C-z} C-f   (fast-lisp)
Set compiler options for fastest but least debuggable code.
@pindex fast-lisp
@kindex @key{C-z} C-f
@cindex Setting compiler options
@cindex Compiler options
@end table



@node Command history, Completion, Debuggers, ILISP Commands
@section Command history
@cindex Command history
@cindex Last command
@cindex Previous commands

ILISP mode is built on top of @code{comint-mode}, the general
command-interpreter-in-a-buffer mode.  As such, it inherits many
commands and features from this, including a command history mechanism.
@cindex @code{comint-mode}

Each ILISP buffer has a command history associated with it.  Commands
that do not match @code{ilisp-filter-regexp} and that are longer than
@code{ilisp-filter-length} and that do not match the immediately prior
command will be added to this history.
@vindex ilisp-filter-length
@vindex ilisp-filter-regexp

@table @kbd

@item M-n   (comint-next-input)
@itemx M-p   (comint-previous-input)
@kindex M-n
@pindex comint-next-input
@cindex Next input
@kindex M-p
@pindex comint-previous-input
Cycle through the input history.

@item M-s    (comint-previous-similar-input)
@kindex M-s
@pindex comint-previous-similar-input
@cindex Similar input
Cycle through input that has the string typed so far as a prefix.

@item M-N    (comint-psearch-input)
@kindex M-N
@pindex comint-psearch-input
@cindex Search input
@cindex Input search
Search forwards for prompt.
@item M-P    (comint-msearch-input)
@kindex M-P
@pindex comint-msearch-input
Search backwards for prompt.

@item C-c R   (comint-msearch-input-matching)
@kindex C-c R
@pindex comint-msearch-input-matching
Search backwards for occurrence of prompt followed by string which is prompted
for (@emph{not} a regular expression).
@end table

See @code{comint-mode} documentation for more information on
@samp{comint} commands.


@node Completion, Miscellany, Command history, ILISP Commands
@section Completion

Commands to reduce number of keystrokes.
@cindex Completion
@cindex Partial completion
@cindex Filename completion

@table @kbd
@item M-TAB   (complete-lisp)
@kindex M-TAB
@pindex complete-lisp
@vindex ilisp-*prefix-match*
will try to complete the previous symbol in the current inferior Lisp.
Partial completion is supported unless @code{ilisp-*prefix-match*} is set to @code{t}.
(If you set it to @code{t}, inferior Lisp completions will be faster.)
With partial completion, @samp{p--n} would complete to
@samp{position-if-not} in Common Lisp.
If the symbol follows a left paren or a @samp{#'}, only symbols with
function cells will be considered.
If the symbol starts with a @samp{*} or you call with a
positive prefix all possible completions will be considered.
Only external symbols are considered if there is a package qualification
with only one colon.
The first time you try to complete a string the longest common substring
will be inserted and the cursor will be left
on the point of ambiguity.
If you try to complete again, you can see the possible completions.
If you are in a string, then filename completion will be done instead.
And if you try to complete a filename twice, you will see a list of
possible completions.
Filename components are completed individually, so @samp{/u/mi/} could
expand to @samp{/usr/misc/}.
If you complete with a negative
prefix, the most recent completion (symbol or filename) will be undone.@refill


@item  M-RET   (complete)
@kindex  M-RET
@pindex complete
@cindex TMC completion
will complete the current symbol to the most recently seen symbol in
Emacs that matches what you have typed so far.  Executing it repeatedly
will cycle through potential matches.  This is from the TMC completion
package and there may be some delay as it is initially loaded.

@end table

@node Miscellany,  , Completion, ILISP Commands
@section Miscellany

Indentation, parenthesis balancing, movement and comment commands.

@table @kbd

@item @kbd{TAB}   (indent-line-ilisp)
@kindex @kbd{TAB}
indents for Lisp.  With prefix, shifts rest of expression rigidly with
the current line.
@pindex indent-line-ilisp
@cindex Indentation
@cindex Rigid indentation


@item M-C-q   (indent-sexp-ilisp)
@kindex M-C-q
will indent each line in the next sexp.
@pindex indent-sexp-ilisp

@item M-q   (reindent-lisp)
@kindex M-q
will reindent the current paragraph if in a comment or string.
Otherwise it will close the containing defun and reindent it.
@pindex reindent-lisp
@cindex Reindent lisp

@item C-a   (bol-ilisp)
@kindex C-a
will go after the prompt as defined by @code{comint-prompt-regexp} or
@code{ilisp-other-prompt} or to the left margin with a prefix.
@pindex bol-ilisp
@cindex Going after the prompt
@vindex comint-prompt-regexp
@vindex ilisp-other-prompt

@item DEL   (backward-delete-char-untabify)
@kindex DEL
converts tabs to spaces as it moves back.
@pindex backward-delete-char-untabify
@cindex Converting tabs to spaces

@item @key{C-z} ;   (comment-region-lisp)
@kindex @key{C-z} ;
will put prefix copies of @code{comment-start} before and
@code{comment-end}'s after the lines in region.  To uncomment a region,
use a minus prefix.@refill
@pindex comment-region-lisp
@cindex Comment region
@cindex Uncomment region

@item @key{C-z} )   (find-unbalanced-lisp)
@kindex @key{C-z} )
will find unbalanced parens in the current buffer.  When called with a
prefix it will look in the current region.
@pindex find-unbalanced-lisp
@cindex Find unbalanced parens
@cindex Parenthesis balancing

@end table


@node Customization, Dialects, ILISP Commands, Top
@chapter ILISP Customization

@c = = =   = = =   = = =   = = =   = = =   = = =   = = =   = = =
@c this refers to hierarchiy, which isn't shown here.
@cindex Customization
@cindex Hooks
@cindex Dialect startup


Starting a dialect runs the hooks on @code{comint-mode-hook}
and @code{ilisp-mode-hook} and then @var{DIALECT}@code{-hooks} specific
to dialects in the nesting order below.
@vindex ilisp-mode-hook
@vindex comint-mode-hook
@example
 common-lisp
   allegro
   clisp-hs
   cmulisp
   cormanlisp
   kcl
     akcl
       gcl
       ecl
     ibcl
   lispworks
   lucid
     liquid
   openmcl
   sbcl
 scheme
   chez
   guile
   mzscheme
     drscheme-jr
   oaklisp
   Scheme->C (still "in fieri")
   scm
   snow
   stk
 xlisp
   xlispstat
@end example

On the very first prompt in the inferior Lisp,
the hooks on @code{ilisp-init-hook} are run.  For more information on
creating a new dialect or variables to set in hooks, see @file{ilisp.el}.
@cindex First prompt
@vindex ilisp-init-hook



@c ->  ->  ->  ->  ->  ->  ->  ->  ->  ->  ->  plenty of indexing here
@c         put these in a table for later expandment
@c

ILISP Mode Hooks:
@cindex ILISP Mode Hooks
@table @code
@item ilisp-site-hook
@vindex ilisp-site-hook
Executed when file is loaded
@item ilisp-load-hook
@vindex ilisp-load-hook
Executed when file is loaded
@item ilisp-mode-hook
@vindex ilisp-mode-hook
Executed when an ilisp buffer is created
@item ilisp-init-hook
@vindex ilisp-init-hook
Executed after inferior Lisp is initialized and the first prompt is
seen.
@item @var{DIALECT}-hook
@vindex @var{DIALECT}-hook
Executed when dialect is set
@end table

Variables you might want to set in a hook or dialect:
@table @code
@item ilisp-*prefix*
@vindex ilisp-*prefix*
Keys to prefix ilisp key bindings
@item ilisp-program
@vindex ilisp-program
Program to start for inferior Lisp
@item ilisp-motd
@vindex ilisp-motd
String printed on startup with version
@item lisp-wait-p
@vindex lisp-wait-p
Set to @code{t} for synchronous sends
@item ilisp-handle-errors
@vindex ilisp-handle-errors
Set to @code{t} for ilisp to handle errors from the underlying Lisp.
@item ilisp-display-output-function
@vindex ilisp-display-output-function
The name of a function which displays ILISP output.
@item lisp-no-popper
@vindex lisp-no-popper
Set to @code{t} to have all output in inferior Lisp
@item ilisp-*use-frame-for-output*
@vindex ilisp-*use-frame-for-output*
Set to @code{t} (default) to have multiline output in a distinct emacs-frame.
@item ilisp-*use-frame-for-arglist-output-p*
@vindex ilisp-*use-frame-for-arglist-output-p*
Set to @code{t} (default) to have multiline arglist-output in a seperate
emacs-frame.
@item ilisp-bindings-*bind-space-p*
@vindex ilisp-bindings-*bind-space-p*
Set to @code{t} to have the SPC-key bound to #'ilisp-arglist-message-lisp-space.
@item ilisp-*arglist-message-lisp-space-p*
@vindex ilisp-*arglist-message-lisp-space-p*
Set to @code{t} to display the arglist of the current function displayed,
after you hit SPC.
@item ilisp-*enable-imenu-p*
@vindex ilisp-*enable-imenu-p*
Set to @code{t} to enable ilisp-imenu, that provides an index of all
lisp-functions/definitions in a file.
@item lisp-show-status
@vindex lisp-show-status
Set to @code{nil} to stop showing process status
@item ilisp-*prefix-match*
@vindex ilisp-*prefix-match*
Set to @code{t} if you do not want partial completion
@item ilisp-filter-regexp
@vindex ilisp-filter-regexp
Input history filter
@item ilisp-filter-length
@vindex ilisp-filter-length
Input history minimum length
@item ilisp-other-prompt
@vindex ilisp-other-prompt
Prompt for non- top-level read-eval print loops
@end table

@node Dialects, Concept index, Customization, Top
@chapter Dialects
@cindex Dialects

A @dfn{dialect} of Lisp is a specific implementation.  For the parts of
Common Lisp which are well specified, they are usually the same.  For
the parts that are not (debugger, top-level loop, etc.), there is
usually the same functionality but different commands.

ILISP provides the means to specify these differences so that the ILISP
commands will use the specific command peculiar to an implementation,
but still offer the same behavior with the same interface.


@menu
* Defining new dialects::
* Writing new commands::
@end menu

@node Defining new dialects, Writing new commands,  , Dialects
@section Defining new dialects


To define a new dialect use the macro @code{defdialect}.  For examples,
look at the dialect definitions in @file{ilisp-acl.el},
@file{ilisp-cmu.el}, @file{ilisp-kcl.el}, @file{ilisp-luc.el}.  There are
hooks and variables for almost anything that you are likely to need to
change.  The relationship between dialects is hierarchical with the root
values being defined in @code{setup-ilisp}.  For a new dialect, you only
need to change the variables that are different than in the parent
dialect.
@cindex Defining new dialects
@pindex setup-ilisp
@pindex defdialect


@node Writing new commands,  , Defining new dialects, Dialects
@section Writing new commands
@cindex Internal ILISP functions

Basic tools for creating new commands:
@table @code
@item deflocal
@findex deflocal
Define a new buffer local variable.
@item ilisp-dialect
@findex ilisp-dialect
List of dialect types.  For specific dialect clauses.
@item lisp-symbol
@findex lisp-symbol
Create a symbol.
@item lisp-symbol-name
@findex lisp-symbol-name
Return a symbol's name
@item lisp-symbol-delimiter
@findex lisp-symbol-delimiter
Return a symbol's qualification
@item lisp-symbol-package
@findex lisp-symbol-package
Return a symbol's package
@item lisp-string-to-symbol
@findex lisp-string-to-symbol
Convert string to symbol
@item lisp-symbol-to-string
@findex lisp-symbol-to-string
Convert symbol to string
@item lisp-buffer-symbol
@findex lisp-buffer-symbol
Convert symbol to string qualified for buffer
@item lisp-previous-symbol
@findex lisp-previous-symbol
Return previous symbol
@item lisp-previous-sexp
@findex lisp-previous-sexp
Return previous sexp
@item lisp-def-name
@findex lisp-def-name
Return name of current definition
@item lisp-function-name
@findex lisp-function-name
Return previous function symbol
@item ilisp-read
@findex ilisp-read
Read an sexp with completion, arglist, etc
@item ilisp-read-symbol
@findex ilisp-read-symbol
Read a symbol or list with completion
@item ilisp-completing-read
@findex ilisp-completing-read
Read from choices or list with completion
@end table

@noindent
Notes:
@itemize @bullet
@item
Special commands like arglist should use @code{ilisp-send} to send a
message to the inferior Lisp.
@findex ilisp-send

@item
Eval/compile commands should use @code{eval-region-lisp} or
@code{compile-region-lisp}.
@findex compile-region-lisp
@findex eval-region-lisp

@end itemize

@node Concept index, Key index, Dialects, Top
@unnumbered Concept Index
@printindex cp

@node Key index, Command index, Concept index, Top
@unnumbered Key Index
@printindex ky

@node Command index, Variable index, Key index, Top
@unnumbered Command Index

@noindent
Commands available via @kbd{M-x} prefix.

@printindex pg

@node Variable index, Function index, Command index, Top
@unnumbered Variable Index

@noindent
Variables and hooks of ILISP.

@printindex vr

@node Function index,  , Variable index, Top
@unnumbered Function Index

@noindent
Internal functions of ILISP which can be used to write new commands.

@printindex fn

@contents

@bye


@comment Local variables:
@comment version-control: t
@comment End: