about summary refs log tree commit diff
path: root/src/librustc_errors/json
diff options
context:
space:
mode:
authorMark Rousskov <mark.simulacrum@gmail.com>2019-12-22 17:42:04 -0500
committerMark Rousskov <mark.simulacrum@gmail.com>2019-12-22 17:42:47 -0500
commita06baa56b95674fc626b3c3fd680d6a65357fe60 (patch)
treecd9d867c2ca3cff5c1d6b3bd73377c44649fb075 /src/librustc_errors/json
parent8eb7c58dbb7b32701af113bc58722d0d1fefb1eb (diff)
downloadrust-a06baa56b95674fc626b3c3fd680d6a65357fe60.tar.gz
rust-a06baa56b95674fc626b3c3fd680d6a65357fe60.zip
Format the world
Diffstat (limited to 'src/librustc_errors/json')
-rw-r--r--src/librustc_errors/json/tests.rs4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/librustc_errors/json/tests.rs b/src/librustc_errors/json/tests.rs
index 4ab5cd21b0b..a96bf715858 100644
--- a/src/librustc_errors/json/tests.rs
+++ b/src/librustc_errors/json/tests.rs
@@ -41,9 +41,7 @@ impl<T: Write> Write for Shared<T> {
 
 fn with_default_globals(f: impl FnOnce()) {
     let globals = syntax_pos::Globals::new(syntax_pos::edition::DEFAULT_EDITION);
-    syntax_pos::GLOBALS.set(&globals, || {
-        syntax_pos::GLOBALS.set(&globals, f)
-    })
+    syntax_pos::GLOBALS.set(&globals, || syntax_pos::GLOBALS.set(&globals, f))
 }
 
 /// Test the span yields correct positions in JSON.