没有合适的资源?快使用搜索试试~ 我知道了~
首页Common Lisp the Language 2nd Edition
Common Lisp the Language 2nd Edition
需积分: 10 148 浏览量
更新于2023-05-29
评论 1
收藏 4.42MB PDF 举报
the Common Lisp Object System, with new features to support function overloading and object-oriented programming, plus complete technical specifications * Loops, a powerful control structure for multiple variables * Conditions, a generalization of the error signaling mechanism * Series and generators * Plus other subjects not part of the ANSI standards but of interest to professional programmers. Throughout, you'll find fresh examples, additional clarifications, warnings, and tips - all presented with the author's customary vigor and wit.
资源详情
资源评论
资源推荐

Contents
Preface (Second Edition) xi
Acknowledgments (Second Edition)
xiii
Acknowledgments (First Edition) xvii
1. Introduction
1
1.1. Purpose 1
1.2. Notational Conventions 4
1.2.1. Decimal Numbers 4
1.2.2. Nil, False, and the Empty
List 4
1.2.3. Evaluation, Expansion, and
Equivalence 5
1.2.4. Errors 5
1.2.5. Descriptions of Functions and
Other Entities 6
1.2.6. The Lisp Reader 10
1.2.7. Overview of Syntax 10
2. Data Types
13
2.1. Numbers 16
2.1.1. Integers 17
2.1.2. Ratios 19
2.1.3. Floating-PointNumbers 20
2.1.4. Complex Numbers 24
2.2. Characters 24
2.2.1. Standard Characters 25
2.2.2. Line Divisions 26
2.2.3. Non-standard Characters 27
2.2.4. Character Attributes 28
2.2.5. String Characters 28
2.3. Symbols 29
2.4. Lists and Conses 32
2.5. Arrays 33
2.5.1. Vectors 35
2.5.2. Strings 36
2.5.3. Bit-Vectors 37
2.6. Hash Tables 38
2.7. Readtables 38
2.8. Packages 38
2.9. Pathnames 38
2.10. Streams 38
2.11. Random-States 39
2.12. Structures 39
2.13. Functions 39
2.14. Unreadable Data Ob jects 40
2.15. Overlap, Inclusion, and
Disjointness of Types 41
3. Scope and Extent
46
4. Type Sp ecifiers
53
4.1. Type Sp ecier Symbols 53
4.2. Type Sp ecier Lists 53
4.3. Predicating Type
Speciers 55
4.4. Type Sp eciers That
Combine 55
4.5. Type Sp eciers That
Specialize 57
4.6. Type Sp eciers That
Abbreviate 64
v

vi CONTENTS
4.7. Dening New Type
Speciers 66
4.8. Type Conversion Function 68
4.9. Determining the Type of an
Ob ject 70
4.10. Type Upgrading 72
5. Program Structure
73
5.1. Forms 73
5.1.1. Self-Evaluating Forms 74
5.1.2. Variables 74
5.1.3. Special Forms 76
5.1.4. Macros 78
5.1.5. Function Calls 79
5.2. Functions 79
5.2.1. Named Functions 80
5.2.2. Lambda-Expressions 80
5.3. Top-Level Forms 88
5.3.1. Dening Named Functions 90
5.3.2. Declaring Global Variables and
Named Constants 92
5.3.3. Control of Time of
Evaluation 94
6. Predicates
101
6.1. Logical Values 102
6.2. Data Type Predicates 102
6.2.1. General Type Predicates 102
6.2.2. Specic Data Type
Predicates 105
6.3. Equality Predicates 110
6.4. Logical Op erators 116
7. Control Structure
119
7.1. Constants and Variables 120
7.1.1. Reference 120
7.1.2. Assignment 127
7.2. Generalized Variables 129
7.3. Function Invocation 154
7.4. Simple Sequencing 155
7.5. Establishing New Variable
Bindings 157
7.6. Conditionals 165
7.7. Blocks and Exits 170
7.8. Iteration 172
7.8.1. Indenite Iteration 172
7.8.2. General Iteration 173
7.8.3. Simple Iteration
Constructs 178
7.8.4. Mapping 180
7.8.5. The \Program Feature" 183
7.9. Structure Traversal and Side
Eects 188
7.10. Multiple Values 189
7.10.1. Constructs for Handling
Multiple Values 190
7.10.2. Rules Governing the Passing of
Multiple Values 195
7.11. Dynamic Non-Local Exits 198
8. Macros
205
8.1. Macro Denition 206
8.2. Macro Expansion 215
8.3. Destructuring 217
8.4. Compiler Macros 217
8.5. Environments 220
9. Declarations
228
9.1. Declaration Syntax 228
9.2. Declaration Speciers 237
9.3. Type Declaration for
Forms 252
10. Symbols
254
10.1. The Property List 254
10.2. The Print Name 259
10.3. Creating Symbols 260
11. Packages
264
11.1. Consistency Rules 266
11.2. Package Names 266
11.3. Translating Strings to
Symbols 268
11.4. Exporting and Importing
Symbols 270
11.5. Name Conicts 272
11.6. Built-in Packages 275

CONTENTS vii
11.7. Package System Functions and
Variables 279
11.8. Mo dules 295
11.9. An Example 296
12. Numbers
307
12.1. Precision, Contagion, and
Coercion 308
12.2. Predicates on Numbers 312
12.3. Comparisons on Numbers 313
12.4. Arithmetic Operations 315
12.5. Irrational and Transcendental
Functions 319
12.5.1. Exponential and Logarithmic
Functions 320
12.5.2. Trigonometric and Related
Functions 323
12.5.3. Branch Cuts, Principal Values,
and Boundary Conditions in
the Complex Plane 332
12.6. Type Conversions and
Component Extractions on
Numbers 375
12.7. Logical Operations on
Numbers 382
12.8. Byte Manipulatio n
Functions 388
12.9. Random Numbers 391
12.10. Implementation
Parameters 394
13. Characters
398
13.1. Character Attributes 401
13.2. Predicates on Characters 403
13.3. Character Construction and
Selection 409
13.4. Character Conversions 410
13.5. Character Control-Bit
Functions 413
14. Sequences
415
14.1. Simple Sequence
Functions 419
14.2. Concatenating, Mapping, and
Reducing Sequences 421
14.3. Modifying Sequences 426
14.4. Searching Sequences for
Items 432
14.5. Sorting and Merging 436
15. Lists
440
15.1. Conses 440
15.2. Lists 442
15.3. Alteration of List
Structure 453
15.4. Substitution of
Expressions 455
15.5. Using Lists as Sets 457
15.6. Association Lists 463
16. Hash Tables
468
16.1. Hash Table Functions 469
16.2. Primitive Hash Function 475
17. Arrays
476
17.1. Array Creation 476
17.2. Array Access 481
17.3. Array Information 482
17.4. Functions on Arrays of
Bits 487
17.5. Fill Pointers 489
17.6. Changing the Dimensions of an
Array 490
18. Strings
495
18.1. String Access 496
18.2. String Comparison 496
18.3. String Construction and
Manipulation 499
19. Structures
504
19.1. Introduction to
Structures 504
19.2. How to Use Defstruct 506

viii CONTENTS
19.3. Using the Automatically
Dened Constructor
Function 510
19.4. Defstruct Slot-Options 512
19.5. Defstruct Options 513
19.6. By-Position Constructor
Functions 519
19.7. Structures of Explicitl y
Specied Representational
Type 523
19.7.1. Unnamed Structures 523
19.7.2. Named Structures 524
19.7.3. Other Aspects of Explicitly
Specied Structures 526
20. The Evaluator
528
20.1. Run-Time Evaluation of
Forms 528
20.2. The Top-Level Lo op 532
21. Streams
535
21.1. Standard Streams 535
21.2. Creating New Streams 538
21.3. Op erations on Streams 542
22. Input/Output
547
22.1. Printed Representation of Lisp
Ob jects 547
22.1.1. What the Read Function
Accepts 548
22.1.2. Parsing of Numbers and
Symbols 554
22.1.3. Macro Characters 563
22.1.4. Standard Dispatching Macro
Character Syntax 570
22.1.5. The Readtable 582
22.1.6. What the PrintFunction
Produces 593
22.2. Input Functions 611
22.2.1. Input from Character
Streams 611
22.2.2. Input from Binary
Streams 622
22.3. Output Functions 622
22.3.1. Output to Character
Streams 623
22.3.2. Output to Binary
Streams 627
22.3.3. Formatted Output to
Character Streams 627
22.4. Querying the User 659
23. File System Interface
661
23.1. File Names 661
23.1.1. Pathnames 662
23.1.2. Case Conventions 668
23.1.3. Structured Directories 672
23.1.4. Extended Wildcards 675
23.1.5. Logical Pathnames 681
23.1.5.1. Syntax of Logical Pathname
Namestrings 681
23.1.5.2. Parsing of Logical Pathname
Namestrings 682
23.1.5.3. Using Logical
Pathnames 683
23.1.5.4. Examples of the Use of
Logical Pathnames 686
23.1.5.5. Discussion of Logical
Pathnames 688
23.1.6. Pathname Functions 690
23.2. Opening and Closing
Files 700
23.3. Renaming, Deleting, and Other
File Operations 707
23.4. Loading Files 712
23.5. Accessing Directories 718
24. Errors
720
24.1. General Error-Signaling
Functions 721
24.2. Specialized Error-Signaling
Forms and Macros 726
24.3. Special Forms for Exhaustive
Case Analysis 729
25. Miscellaneous Features
732
25.1. The Compiler 732
25.1.1. Compiler Diagnostics 740

CONTENTS ix
25.1.2. Compiled Functions 741
25.1.3. Compilation Environment 742
25.1.4. Similarity of Constants 747
25.2. Do cumentation 751
25.3. Debugging Tools 752
25.4. Environment Inquiries 759
25.4.1. Time Functions 759
25.4.2. Other Environment
Inquiries 763
25.5. IdentityFunction 765
26. Loop
767
26.1. Introduction 767
26.2. How the Lo op Facility
Works 767
26.3. Parsing Lo op Clauses 768
26.3.1. Order of Execution 769
26.3.2. Kinds of Lo op Clauses 770
26.3.3. Loop Syntax 773
26.4. User Extensibility 773
26.5. Lo op Constructs 773
26.6. Iteration Control 774
26.7. End-Test Control 785
26.8. Value Accumulation 789
26.9. Variable Initializati ons 795
26.10. Conditional Execution 798
26.11. Unconditional Execution 800
26.12. Miscellaneous Features 802
26.12.1. Data Types 802
26.12.2. Destructuring 803
27. PrettyPrinting
808
27.1. Introduction 808
27.2. PrettyPrinting Control
Variables 809
27.3. Dynamic Control of the
ArrangementofOutput 810
27.4. Format Directive
Interface 822
27.5. Compiling Format Control
Strings 825
27.6. PrettyPrinting Dispatch
Tables 826
28. Common Lisp Ob ject
System
831
28.1. Programmer Interface
Concepts 831
28.1.1. Error Terminology 832
28.1.2. Classes 835
28.1.2.1. Dening Classes 836
28.1.2.2. Creating Instances of
Classes 837
28.1.2.3. Slots 837
28.1.2.4. Accessing Slots 839
28.1.3. Inheritance 841
28.1.3.1. Inheritance of Metho ds 841
28.1.3.2. Inheritance of Slots and Slot
Options 841
28.1.3.3. Inheritance of Class
Options 843
28.1.3.4. Examples 843
28.1.4. Integrating Types and
Classes 843
28.1.5. Determining the Class
Precedence List 845
28.1.5.1. Topological Sorting 848
28.1.5.2. Examples 848
28.1.6. Generic Functions and
Methods 851
28.1.6.1. Introduction to Generic
Functions 851
28.1.6.2. Introduction to
Methods 852
28.1.6.3. AgreementonParameter
Specializer s and Qualiers 855
28.1.6.4. CongruentLambda-Lists for
All Metho ds of a
Generic Function 856
28.1.6.5. Keyword Arguments in
Generic Functions and
Methods 856
28.1.7. Method Selection and
Combination 858
28.1.7.1. Determining the Eective
Method 858
28.1.7.2. Standard Metho d
Combination 861
剩余1095页未读,继续阅读

















sinat_21954747
- 粉丝: 0
- 资源: 24
上传资源 快速赚钱
我的内容管理 收起
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助

会员权益专享
最新资源
- Xilinx SRIO详解.pptx
- Informatica PowerCenter 10.2 for Centos7.6安装配置说明.pdf
- 现代无线系统射频电路实用设计卷II 英文版.pdf
- 电子产品可靠性设计 自己讲课用的PPT,包括设计方案的可靠性选择,元器件的选择与使用,降额设计,热设计,余度设计,参数优化设计 和 失效分析等
- MPC5744P-DEV-KIT-REVE-QSG.pdf
- 通信原理课程设计报告(ASK FSK PSK Matlab仿真--数字调制技术的仿真实现及性能研究)
- ORIGIN7.0使用说明
- 在VMware Player 3.1.3下安装Redhat Linux详尽步骤
- python学生信息管理系统实现代码
- 西门子MES手册 13 OpcenterEXCR_PortalStudio1_81RB1.pdf
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈



安全验证
文档复制为VIP权益,开通VIP直接复制

评论0