Skip to content

Commit

Permalink
Use edition 2018.
Browse files Browse the repository at this point in the history
  • Loading branch information
reitermarkus committed Sep 24, 2019
1 parent 6b85298 commit d55638b
Show file tree
Hide file tree
Showing 10 changed files with 26 additions and 25 deletions.
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ license = "MIT OR Apache-2.0"
name = "cross"
repository = "https://github.com/rust-embedded/cross"
version = "0.1.16"
edition = "2018"

[dependencies]
atty = "0.2"
Expand Down
4 changes: 2 additions & 2 deletions src/cargo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ use std::path::{Path, PathBuf};
use std::process::{Command, ExitStatus};
use std::{env, fs};

use errors::*;
use extensions::CommandExt;
use crate::errors::*;
use crate::extensions::CommandExt;

#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub enum Subcommand {
Expand Down
6 changes: 3 additions & 3 deletions src/cli.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
use std::env;

use Target;
use cargo::Subcommand;
use rustc::TargetList;
use crate::Target;
use crate::cargo::Subcommand;
use crate::rustc::TargetList;

pub struct Args {
pub all: Vec<String>,
Expand Down
10 changes: 5 additions & 5 deletions src/docker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ use std::{env, fs};
use atty::Stream;
use semver::{Version, VersionReq};

use {Target, Toml};
use cargo::Root;
use errors::*;
use extensions::CommandExt;
use id;
use crate::{Target, Toml};
use crate::cargo::Root;
use crate::errors::*;
use crate::extensions::CommandExt;
use crate::id;

const DOCKER_IMAGES: &[&str] = &include!(concat!(env!("OUT_DIR"), "/docker-images.rs"));

Expand Down
2 changes: 1 addition & 1 deletion src/extensions.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use std::process::{Command, ExitStatus};

use errors::*;
use crate::errors::*;

pub trait CommandExt {
fn run(&mut self, verbose: bool) -> Result<()>;
Expand Down
2 changes: 1 addition & 1 deletion src/file.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use std::fs::File;
use std::io::Read;
use std::path::Path;

use errors::*;
use crate::errors::*;

pub fn read<P>(path: P) -> Result<String>
where P: AsRef<Path>
Expand Down
6 changes: 3 additions & 3 deletions src/interpreter.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
use std::path::Path;

use errors::*;
use file;
use Target;
use crate::errors::*;
use crate::file;
use crate::Target;

/// Checks if the interpreters have been registered in the host system
pub fn is_registered(target: &Target) -> Result<bool> {
Expand Down
8 changes: 4 additions & 4 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,12 @@ use std::{env, io, process};

use toml::{Value, value::Table};

use cargo::{Root, Subcommand};
use errors::*;
use rustc::{TargetList, VersionMetaExt};
use self::cargo::{Root, Subcommand};
use self::errors::*;
use self::rustc::{TargetList, VersionMetaExt};

#[allow(non_camel_case_types)]
#[derive(Debug, Clone, Copy, PartialEq)]
#[derive(Debug, Clone, PartialEq)]
pub enum Host {
Other,

Expand Down
6 changes: 3 additions & 3 deletions src/rustc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ use std::process::Command;

use rustc_version::{Version, VersionMeta};

use {Host, Target};
use errors::*;
use extensions::CommandExt;
use crate::{Host, Target};
use crate::errors::*;
use crate::extensions::CommandExt;

pub struct TargetList {
triples: Vec<String>,
Expand Down
6 changes: 3 additions & 3 deletions src/rustup.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
use std::process::Command;

use Target;
use errors::*;
use extensions::CommandExt;
use crate::Target;
use crate::errors::*;
use crate::extensions::CommandExt;

#[derive(Debug)]
pub struct AvailableTargets {
Expand Down

0 comments on commit d55638b

Please sign in to comment.