Skip to content

Commit

Permalink
Merge branch 'master' into ao-move-memdiff-to-trace-executed
Browse files Browse the repository at this point in the history
* master:
  EIP 1884 Re-pricing of trie-size dependent operations (openethereum#10992)
  xDai chain support and nodes list update (openethereum#10989)
  [trace] check mem diff within range (openethereum#11002)
  EIP-1344 Add CHAINID op-code (openethereum#10983)
  Make ClientIoMessage generic over the Client (openethereum#10981)
  bump spin to 0.5.2 (openethereum#10996)
  fix compile warnings (openethereum#10993)
  • Loading branch information
ordian committed Aug 29, 2019
2 parents c1bf8ab + dabfa2c commit 5b4a438
Show file tree
Hide file tree
Showing 139 changed files with 1,271 additions and 753 deletions.
109 changes: 103 additions & 6 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ spec = { path = "ethcore/spec" }
term_size = "0.3"
textwrap = "0.9"
toml = "0.4"
verification = { path = "ethcore/verification" }

[build-dependencies]
rustc_version = "0.2"
Expand Down
6 changes: 3 additions & 3 deletions accounts/ethstore/src/accounts_dir/disk.rs
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ impl<T> KeyDirectory for DiskDirectory<T> where T: KeyFileManager {

fn path(&self) -> Option<&PathBuf> { Some(&self.path) }

fn as_vault_provider(&self) -> Option<&VaultKeyDirectoryProvider> {
fn as_vault_provider(&self) -> Option<&dyn VaultKeyDirectoryProvider> {
Some(self)
}

Expand All @@ -294,12 +294,12 @@ impl<T> KeyDirectory for DiskDirectory<T> where T: KeyFileManager {
}

impl<T> VaultKeyDirectoryProvider for DiskDirectory<T> where T: KeyFileManager {
fn create(&self, name: &str, key: VaultKey) -> Result<Box<VaultKeyDirectory>, Error> {
fn create(&self, name: &str, key: VaultKey) -> Result<Box<dyn VaultKeyDirectory>, Error> {
let vault_dir = VaultDiskDirectory::create(&self.path, name, key)?;
Ok(Box::new(vault_dir))
}

fn open(&self, name: &str, key: VaultKey) -> Result<Box<VaultKeyDirectory>, Error> {
fn open(&self, name: &str, key: VaultKey) -> Result<Box<dyn VaultKeyDirectory>, Error> {
let vault_dir = VaultDiskDirectory::at(&self.path, name, key)?;
Ok(Box::new(vault_dir))
}
Expand Down
8 changes: 4 additions & 4 deletions accounts/ethstore/src/accounts_dir/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,17 +57,17 @@ pub trait KeyDirectory: Send + Sync {
/// Get directory filesystem path, if available
fn path(&self) -> Option<&PathBuf> { None }
/// Return vault provider, if available
fn as_vault_provider(&self) -> Option<&VaultKeyDirectoryProvider> { None }
fn as_vault_provider(&self) -> Option<&dyn VaultKeyDirectoryProvider> { None }
/// Unique representation of directory account collection
fn unique_repr(&self) -> Result<u64, Error>;
}

/// Vaults provider
pub trait VaultKeyDirectoryProvider {
/// Create new vault with given key
fn create(&self, name: &str, key: VaultKey) -> Result<Box<VaultKeyDirectory>, Error>;
fn create(&self, name: &str, key: VaultKey) -> Result<Box<dyn VaultKeyDirectory>, Error>;
/// Open existing vault with given key
fn open(&self, name: &str, key: VaultKey) -> Result<Box<VaultKeyDirectory>, Error>;
fn open(&self, name: &str, key: VaultKey) -> Result<Box<dyn VaultKeyDirectory>, Error>;
/// List all vaults
fn list_vaults(&self) -> Result<Vec<String>, Error>;
/// Get vault meta
Expand All @@ -77,7 +77,7 @@ pub trait VaultKeyDirectoryProvider {
/// Vault directory
pub trait VaultKeyDirectory: KeyDirectory {
/// Cast to `KeyDirectory`
fn as_key_directory(&self) -> &KeyDirectory;
fn as_key_directory(&self) -> &dyn KeyDirectory;
/// Vault name
fn name(&self) -> &str;
/// Get vault key
Expand Down
2 changes: 1 addition & 1 deletion accounts/ethstore/src/accounts_dir/vault.rs
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ impl VaultDiskDirectory {
}

impl VaultKeyDirectory for VaultDiskDirectory {
fn as_key_directory(&self) -> &KeyDirectory {
fn as_key_directory(&self) -> &dyn KeyDirectory {
self
}

Expand Down
Loading

0 comments on commit 5b4a438

Please sign in to comment.