如何看待Ghost Cell?(Rust)?
试用了下 GhostCell [1,2] + StaticRc [3],用来写链表。
总体感觉非常不错,很创新的一个概念,但如果能内置到编译器层面,可能使用上会更加方便。
GhostCell ——安全、零开销的内部可变性机制 GhostCell的思想大致是:通过一个GhostToken来控制一系列与之生命周期相等的GhostCell数据的读写行为,从而实现安全、零开销的内部可变性。
GhostCell文档首页给出的一个样例可以说明其使用方法。
use ghost_cell::{GhostToken, GhostC…。
{dede:pagebreak/}
上一篇 : 媒体称以色列防空成本一晚近 3 亿美元,最多再撑 12 天,美方会支援吗?若无美补给结果会如何?
本文地址:{dede:field name='arcurl' /}
{dede:type}更多{/dede:type}
{dede:include filename="pinglun.htm"/}