当前位置: 首页 >

如何看待Ghost Cell?(Rust)?

作者: 发布时间:{dede:field name='pubdate'function='strftime("%Y-%m-%d %H:%M:%S",@me)' /}点击:

试用了下 GhostCell [1,2] + StaticRc [3],用来写链表。

总体感觉非常不错,很创新的一个概念,但如果能内置到编译器层面,可能使用上会更加方便。

GhostCell ——安全、零开销的内部可变性机制 GhostCell的思想大致是:通过一个GhostToken来控制一系列与之生命周期相等的GhostCell数据的读写行为,从而实现安全、零开销的内部可变性。

GhostCell文档首页给出的一个样例可以说明其使用方法。

use ghost_cell::{GhostToken, GhostC…。

如何看待Ghost Cell?(Rust)?
相关标签:{dede:tag row='20' sort='rand'}{/dede:tag}
鄂-ICP备88347352号-1|网站地图鄂-ICP备88347352号-1|网站地图 【】