会员
周边
新闻
博问
闪存
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
小小张说故事
博客园
首页
新随笔
联系
订阅
管理
2026年11月5日
Python 的 list[int] 为什么不是 list?拆开 __class_getitem__ 和那层 80 字节的薄包装
摘要: 先看几行我在本机跑出来的结果(CPython 3.13.14): >>> type(list[int]) <class 'types.GenericAlias'> >>> list[int] is list[int] False >>> list[int] == list[int] True >>>
阅读全文
posted @ 2026-11-05 15:08 小小张说故事
阅读(5)
评论(0)
推荐(0)
公告