dag: require Send and Sync on Persist::Lock

Summary: This will make async migrating easier.

Reviewed By: sfilipco

Differential Revision: D25350913

fbshipit-source-id: f33bdc0023ae0cc49601504b811991ea6813ff9e
This commit is contained in:
Jun Wu 2020-12-10 12:32:23 -08:00 committed by Facebook GitHub Bot
parent abc97bb6fe
commit f30934ab4f

View File

@ -313,7 +313,7 @@ pub trait IdMapSnapshot {
/// Describes how to persist state to disk.
pub trait Persist {
/// Return type of `lock()`.
type Lock;
type Lock: Send + Sync;
/// Obtain an exclusive lock for writing.
/// This should prevent other writers.