diff options
| author | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2021-05-05 21:31:25 +0200 |
|---|---|---|
| committer | Guillaume Gomez <guillaume.gomez@huawei.com> | 2021-07-08 16:16:28 +0200 |
| commit | a2654fb64c9c9d368063b488693d8da17bc9b4e9 (patch) | |
| tree | e6337d870d12feb89266d5dc2a77214458af7440 /compiler/rustc_parse_format/src | |
| parent | 0cd0709f19d316c4796fa71c5f52c8612a5f3771 (diff) | |
| download | rust-a2654fb64c9c9d368063b488693d8da17bc9b4e9.tar.gz rust-a2654fb64c9c9d368063b488693d8da17bc9b4e9.zip | |
Rework SESSION_GLOBALS API to prevent overwriting it
Diffstat (limited to 'compiler/rustc_parse_format/src')
| -rw-r--r-- | compiler/rustc_parse_format/src/tests.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/compiler/rustc_parse_format/src/tests.rs b/compiler/rustc_parse_format/src/tests.rs index 9fd0497fffe..b7693a85ad9 100644 --- a/compiler/rustc_parse_format/src/tests.rs +++ b/compiler/rustc_parse_format/src/tests.rs @@ -144,8 +144,7 @@ fn format_align_fill() { } #[test] fn format_counts() { - use rustc_span::{edition, SessionGlobals, SESSION_GLOBALS}; - SESSION_GLOBALS.set(&SessionGlobals::new(edition::DEFAULT_EDITION), || { + rustc_span::create_default_session_globals_then(|| { same( "{:10x}", &[NextArgument(Argument { |
