摘要:
引用计数机制 简介 python内部使用引用计数,来保持追踪内存中的对象,Python内部记录了对象有多少个引用,即引用计数,当对象被创建时就创建了一个引用计数,当对象不再需要时,这个对象的引用计数为0时,它被垃圾回收。 特性 当给一个对象分配一个新名称或者将一个对象放入一个容器(列表、元组或字典) 阅读全文
posted @ 2022-01-01 13:58 foghorn 阅读(59) 评论(0) 推荐(0)
posted @ 2022-01-01 13:58 foghorn 阅读(59) 评论(0) 推荐(0)
posted @ 2021-12-29 10:56 foghorn 阅读(68) 评论(0) 推荐(0)
posted @ 2021-12-12 21:27 foghorn 阅读(222) 评论(0) 推荐(0)
posted @ 2021-12-11 20:05 foghorn 阅读(367) 评论(0) 推荐(0)
posted @ 2021-11-30 22:55 foghorn 阅读(564) 评论(1) 推荐(1)
posted @ 2021-11-14 20:40 foghorn 阅读(750) 评论(0) 推荐(0)
posted @ 2021-11-13 23:54 foghorn 阅读(3193) 评论(0) 推荐(0)
posted @ 2021-11-13 10:21 foghorn 阅读(1066) 评论(0) 推荐(0)
posted @ 2021-11-08 10:53 foghorn 阅读(48) 评论(0) 推荐(0)
posted @ 2021-11-06 14:36 foghorn 阅读(170) 评论(0) 推荐(1)