summary refs log tree commit diff
path: root/library/std/src/macros.rs
AgeCommit message (Collapse)AuthorLines
2022-05-03Auto merge of #96490 - dtolnay:writetmpbackport, r=Mark-Simulacrumbors-6/+6
Make [e]println macros eagerly drop temporaries (for backport) This PR extracts the subset of #96455 which is only the parts necessary for fixing the 1.61-beta regressions in #96434. My larger PR #96455 contains a few other changes relative to the pre-#94868 behavior; those are not necessary to backport into 1.61. argument position | before #94868 | after #94868 | after this PR --- |:---:|:---:|:---: `write!($tmp, "…", …)` | :rage: | :rage: | :rage: `write!(…, "…", $tmp)` | :rage: | :rage: | :rage: `writeln!($tmp, "…", …)` | :rage: | :rage: | :rage: `writeln!(…, "…", $tmp)` | :rage: | :rage: | :rage: `print!("…", $tmp)` | :rage: | :rage: | :rage: `println!("…", $tmp)` | :smiley_cat: | :rage: | :smiley_cat: `eprint!("…", $tmp)` | :rage: | :rage: | :rage: `eprintln!("…", $tmp)` | :smiley_cat: | :rage: | :smiley_cat: `panic!("…", $tmp)` | :smiley_cat: | :smiley_cat: | :smiley_cat:
2022-03-11Format core and std macro rules, removing needless surrounding blocksDavid Tolnay-10/+18
2022-01-06Add diagnostic items for macrosAlex Macleod-0/+5
2021-08-01bump bootstrap compiler to 1.55Pietro Albini-2/+1
2021-07-27Make `SEMICOLON_IN_EXPRESSIONS_FROM_MACROS` warn by defaultAaron Hill-1/+1
2021-07-13expand: Support helper attributes for built-in derive macrosVadim Petrochenkov-1/+2
2021-05-13Change "etc." to "and similar"Ian Jackson-1/+1
Co-authored-by: Josh Triplett <josh@joshtriplett.org>
2021-05-12dbg macro: Discuss use in tests, and slightly clarifyIan Jackson-3/+4
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
2021-02-23Use #[doc = include_str!()] in stdLeSeulArtichaut-1/+1
2021-02-20Update the bootstrap compilerJoshua Nelson-15/+0
Note this does not change `core::derive` since it was merged after the beta bump.
2021-01-25Implement new panic!() behaviour for Rust 2021.Mara Bos-0/+16
2021-01-21Document why cannot use concat! in dbg!Lzu Tao-0/+4
Co-authored-by: Miguel Ojeda <ojeda@users.noreply.github.com>
2020-12-30Bump bootstrap compiler to 1.50 betaMark Rousskov-1/+1
2020-10-19Add cfg(not(test)) to std_panic_macro rustc_diagnostic_item.Mara Bos-1/+1
2020-10-18Add cfg(not(bootstrap)) on the new rustc_diagnostic_item attributes.Mara Bos-1/+1
The beta compiler doesn't accept rustc_diagnostic_items on macros yet.
2020-10-18Mark the panic macros as diagnostic items.Mara Bos-0/+1
2020-10-26Use ? in core/std macrosTaiki Endo-5/+2
2020-08-22Add missing linksCamelid-3/+3
2020-08-22Add missing intra-doc linkCamelid-0/+2
2020-08-22Switch to intra-doc links in `std::macros`Camelid-11/+8
Also: * Fix typo in module docs * Link to `std::io::stderr` instead of `std::io::Stderr` to match the link text * Link to `std::io::stdout`
2020-07-27mv std libs to library/mark-0/+313