Skip to main content

dictionary_state_revision

Function dictionary_state_revision 

Source
pub fn dictionary_state_revision(paths: &RuntimePaths) -> Result<String>
Expand description

SHA-256 hex over text("msime-local-dictionary-state-v1") and every streamed record, where text(s) is integer(len) then the bytes and integer is a big-endian u64 (dictionary_revision.rs). Apple computes the same digest; keep the framing byte for byte.

每次都完整读一遍日志。算完顺带把结果记进 cached_dictionary_state_revision 的缓存,所以准备、激活快照这些必须拿精确值的地方算出来的新结果,之后的预览也直接用上。