Python logo

上一主题

内存管理

下一主题

在堆上分配对象

当前页面

  • 报告 Bug
  • 显示源码

导航

  • 索引
  • 模块 |
  • 下一页 |
  • 上一页 |
  • Python logo
  • Python »
  • 3.12.1 Documentation »
  • Python/C API 参考手册 »
  • 对象实现支持
  • |
  • |

对象实现支持¶

本章描述了定义新对象类型时所使用的函数、类型和宏。

  • 在堆上分配对象
  • 公用对象结构体
    • 基本的对象类型和宏
    • 实现函数和方法
    • 访问扩展类型的属性
      • 成员旗标
      • 成员类型
      • 定义读取器和设置器
  • 类型对象
    • 快速参考
      • "tp_方法槽"
      • 子方法槽(方法域)
      • 槽位 typedef
    • PyTypeObject 定义
    • PyObject 槽位
    • PyVarObject 槽位
    • PyTypeObject 槽
    • 静态类型
    • 堆类型
  • 数字对象结构体
  • 映射对象结构体
  • 序列对象结构体
  • 缓冲区对象结构体
  • 异步对象结构体
  • 槽位类型 typedef
  • 例子
  • 使对象类型支持循环垃圾回收
    • 控制垃圾回收器状态
    • 查询垃圾回收器状态

上一主题

内存管理

下一主题

在堆上分配对象

当前页面

  • 报告 Bug
  • 显示源码
«

导航

  • 索引
  • 模块 |
  • 下一页 |
  • 上一页 |
  • Python logo
  • Python »
  • 3.12.1 Documentation »
  • Python/C API 参考手册 »
  • 对象实现支持
  • |
  • |
© 版权所有 2001-2024, Python Software Foundation.
This page is licensed under the Python Software Foundation License Version 2.
Examples, recipes, and other code in the documentation are additionally licensed under the Zero Clause BSD License.
See History and License for more information.

The Python Software Foundation is a non-profit corporation. Please donate.

最后更新于 Feb 02, 2024 (05:33 UTC). Found a bug?
由 Sphinx 7.2.6创建。