]> git.lizzy.rs Git - rust.git/commitdiff
Merge #836
authorbors[bot] <bors[bot]@users.noreply.github.com>
Sat, 16 Feb 2019 11:29:03 +0000 (11:29 +0000)
committerbors[bot] <bors[bot]@users.noreply.github.com>
Sat, 16 Feb 2019 11:29:03 +0000 (11:29 +0000)
836: auto_import: fix bug when the common path was shorter than both the c… r=matklad a=eulerdisk

Fix bug when the common path was shorter than both the current use and target path.

Wrong 1 (unnecessary self)
```
use std::fmt::nested::Debug;
std::fmt::Display<|>
```
--->
```
use std::fmt::{ self, Display, nested::Debug};
Display<|>
```

Wrong 2 (unnecessary, Debug disappear!!)
```
use std::fmt::Debug;
std::fmt::nested::Display
```
-->
```
use std::fmt::Debug::{ self, nested::Display, };
Display<|>
```

Co-authored-by: Andrea Pretto <eulerdisk@gmail.com>

Trivial merge