fix(compile warn): &mut Trait -> dyn &mut Trait (#2872)

This commit is contained in:
Niklas Adolfsson
2019-06-15 09:01:37 +02:00
committed by Bastian Köcher
parent db5722adc3
commit 549b4e9fb1
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -715,7 +715,7 @@ impl<Block: BlockT<Hash=H256>> Backend<Block> {
}
#[cfg(any(test, feature = "test-helpers"))]
pub fn new_test_db(keep_blocks: u32, canonicalization_delay: u64, db: Arc<KeyValueDB>) -> Self {
pub fn new_test_db(keep_blocks: u32, canonicalization_delay: u64, db: Arc<dyn KeyValueDB>) -> Self {
let db_setting = DatabaseSettings {
cache_size: None,
+1 -1
View File
@@ -587,7 +587,7 @@ impl<B: BlockT> ChainSync<B> {
/// A batch of blocks have been processed, with or without errors.
/// Call this when a batch of blocks have been processed by the import queue, with or without
/// errors.
pub fn blocks_processed(&mut self, protocol: &mut Context<B>, processed_blocks: Vec<B::Hash>, has_error: bool) {
pub fn blocks_processed(&mut self, protocol: &mut dyn Context<B>, processed_blocks: Vec<B::Hash>, has_error: bool) {
for hash in processed_blocks {
self.queue_blocks.remove(&hash);
}