Update to Rust 2018 Edition.
This commit is contained in:
@@ -22,21 +22,12 @@
|
||||
)
|
||||
)]
|
||||
|
||||
extern crate cranelift_codegen;
|
||||
extern crate cranelift_entity;
|
||||
extern crate cranelift_wasm;
|
||||
extern crate failure;
|
||||
use failure;
|
||||
#[macro_use]
|
||||
extern crate failure_derive;
|
||||
extern crate target_lexicon;
|
||||
extern crate wabt;
|
||||
extern crate wasmparser;
|
||||
extern crate wasmtime_environ;
|
||||
extern crate wasmtime_jit;
|
||||
extern crate wasmtime_runtime;
|
||||
|
||||
mod spectest;
|
||||
mod wast;
|
||||
|
||||
pub use spectest::instantiate_spectest;
|
||||
pub use wast::{WastContext, WastError};
|
||||
pub use crate::spectest::instantiate_spectest;
|
||||
pub use crate::wast::{WastContext, WastError};
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
use spectest::instantiate_spectest;
|
||||
use crate::spectest::instantiate_spectest;
|
||||
use std::io::Read;
|
||||
use std::path::Path;
|
||||
use std::{fmt, fs, io, str};
|
||||
@@ -26,7 +26,7 @@ pub struct UnknownInstance {
|
||||
}
|
||||
|
||||
impl fmt::Display for UnknownInstance {
|
||||
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
||||
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||
match self.instance {
|
||||
None => write!(f, "no default instance present"),
|
||||
Some(ref name) => write!(f, "no instance {} present", name),
|
||||
@@ -52,7 +52,7 @@ pub enum WastError {
|
||||
}
|
||||
|
||||
impl fmt::Display for WastError {
|
||||
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
||||
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||
match *self {
|
||||
WastError::Assert(ref message) => write!(f, "Assert command failed: {}", message),
|
||||
WastError::Instance(ref error) => error.fmt(f),
|
||||
|
||||
Reference in New Issue
Block a user