# 2.1 打印表示 和 读取语法

对象的**打印表示**（printed representation）是 **Lisp 打印器**（Lisp printer）（也就是函数prin1）所生成的，该类型对象的文本表示。每种数据类型都有它们各自的打印表示。**读取语法**（read syntax）是指可以被Lisp 读取器理解的，某种类型对象的文本表示。读取语法并不一定是特定的。很多对象拥有一种以上的读取语法。详情查阅 读取和打印。

绝大多数情况下，一个对象的打印表示同时也是这个对象的读取语法。不过，也有一些类型的对象没有读取语法。对于这些对象而言，使用读取语法将其输入 Lisp 没有多少现实意义。这些对象统一使用 哈希记法（hash notation），也就是由 字符 '#<'，一段描述性的字符串（通常来说是类型名加上对象名）, 以及符号 '>'，组成。比如：

```
(current-buffer)
    => #<buffer objects.texi>
```

哈希记法完全不可读（指无法被Lisp读取器理解），因此当你尝试使用哈希记法向 Lisp 程序输入数据时，会抛出 invalid-read-syntax 错误。（不论你有没有使用 '#<' ）。

在其他语言中，表达式就是文本，而没有其他形式。在 Lisp 中，表达式是一个 Lisp 对象，同时也可以是这个对象的读取语法。一般来说，两者没有区分的必要，但是你最好知道其中的区别，不然在后续的学习中你会经常感到困惑。

当你以交互的方式对一个表达式求值时，Lisp 解释器首先会读取这个表达式的文字性表示，然后生成一个 Lisp 对象，接着再对这个 Lisp 对象进行求值（详情查阅 求值）。需要注意的是，读取和求值是两个不同的过程。读取会返回文本对应的 Lisp 对象；但之后，这个 Lisp 对象可能被求值，也可能不被求值；查阅 输入函数，你可以找到最基础的用于读取对象的函数：read。


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://emacs-lisp.ivory.cafe/lisp-shu-ju-lei-xing/2.1-da-yin-biao-shi-he-du-qu-yu-fa.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
