about summary refs log tree commit diff
path: root/src/libsyntax/source_map.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2018-08-24 17:02:23 +0000
committerbors <bors@rust-lang.org>2018-08-24 17:02:23 +0000
commit727eabd68143e968d8826ee29b8ea7792d29fa96 (patch)
tree39ed93235d768258148e640411fc823c98657225 /src/libsyntax/source_map.rs
parent61b00727076ce251b54bdefa18779a13819d2209 (diff)
parentc6039de546301cc8ad94637d0d9e24860d39832b (diff)
downloadrust-727eabd68143e968d8826ee29b8ea7792d29fa96.tar.gz
rust-727eabd68143e968d8826ee29b8ea7792d29fa96.zip
Auto merge of #53662 - kennytm:rollup, r=kennytm
Rollup of 16 pull requests

Successful merges:

 - #53311 (Window Mutex: Document that we properly initialize the SRWLock)
 - #53503 (Discourage overuse of mem::forget)
 - #53545 (Fix #50865: ICE on impl-trait returning functions reaching private items)
 - #53559 (add macro check for lint)
 - #53562 (Lament the invincibility of the Turbofish)
 - #53563 (use String::new() instead of String::from(""), "".to_string(), "".to_owned() or "".into())
 - #53592 (docs: minor stylistic changes to str/string docs)
 - #53594 (Update RELEASES.md to include clippy-preview)
 - #53600 (Fix a grammatical mistake in "expected generic arguments" errors)
 - #53614 (update nomicon and book)
 - #53617 (tidy: Stop requiring a license header)
 - #53618 (Add missing fmt examples)
 - #53636 (Prefer `.nth(n)` over `.skip(n).next()`.)
 - #53644 (Use SmallVec for SmallCStr)
 - #53664 (Remove unnecessary closure in rustc_mir/build/mod.rs)
 - #53666 (Added rustc_codegen_llvm to compiler documentation.)
Diffstat (limited to 'src/libsyntax/source_map.rs')
-rw-r--r--src/libsyntax/source_map.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libsyntax/source_map.rs b/src/libsyntax/source_map.rs
index c65931a8577..8f91db8efa7 100644
--- a/src/libsyntax/source_map.rs
+++ b/src/libsyntax/source_map.rs
@@ -1030,7 +1030,7 @@ mod tests {
         cm.new_source_file(PathBuf::from("blork.rs").into(),
                        "first line.\nsecond line".to_string());
         cm.new_source_file(PathBuf::from("empty.rs").into(),
-                       "".to_string());
+                       String::new());
         cm.new_source_file(PathBuf::from("blork2.rs").into(),
                        "first line.\nsecond line".to_string());
         cm