Xiretza
8489a67f0b
Implement IntoDiagnosticArg for rustc_ast::Path
2022-09-27 20:29:18 +02:00
Xiretza
495e271883
Migrate rustc_session::expr_parentheses_needed to Subdiagnostic struct
2022-09-27 20:29:18 +02:00
Guillaume Gomez
a925e203d1
Add GUI regression test for search results colors
2022-09-27 20:23:00 +02:00
Guillaume Gomez
ef410f1b01
Fix regression for results colors
2022-09-27 20:22:46 +02:00
Michael Howell
3bbb328e68
rustdoc: remove redundant #help-button
CSS
...
When the separate top and bottom styles were added in
cd3f4da244
, some of the CSS rules were
needlessly duplicated.
The `text-align: initial` rule on `.side-by-side` was always redundant, since
the rules that centered the text were set on children, not parents.
2022-09-27 10:52:08 -07:00
Jacob Hoffman-Andrews
b5b77a2959
Update src/test/rustdoc-gui/sidebar-mobile-scroll.goml
...
Co-authored-by: Michael Howell <michael@notriddle.com>
2022-09-27 10:52:05 -07:00
Michael Goulet
92561f43f1
Support bindings with anon consts in generics
2022-09-27 17:42:15 +00:00
Michael Goulet
05267b5a50
Make type_of work correctly for const arg bindings
2022-09-27 17:42:14 +00:00
Michael Goulet
cca48285b8
Format type_of
2022-09-27 17:42:13 +00:00
Michael Goulet
ca2e0bb51a
Deny associated type bindings within associated type bindings
2022-09-27 17:41:34 +00:00
Camille GILLOT
337a73da6e
Do not overwrite binders for another HirId.
2022-09-27 18:58:37 +02:00
Weihang Lo
5095f54219
Update cargo
...
22 commits in 73ba3f35e0205844418260722c11602113179c4a..f5fed93ba24607980647962c59863bbabb03ce14
2022-09-18 06:38:16 +0000 to 2022-09-27 12:03:57 +0000
- build-scripts.md: Use em dash consistently. (rust-lang/cargo#11150 )
- Indicate how Cargo locates the manifest (rust-lang/cargo#10770 )
- Reduce references to `[project]` within cargo (rust-lang/cargo#11135 )
- Iteratively construct target cfg (rust-lang/cargo#11114 )
- update comment about `CARGO_BIN_EXE_` (rust-lang/cargo#11146 )
- Call out that not all config values can be set via env vars (rust-lang/cargo#11139 )
- Bump to 0.67.0, update changelog (rust-lang/cargo#11137 )
- ci: update toolchain for building api doc (rust-lang/cargo#11134 )
- Http publish not noop (rust-lang/cargo#11111 )
- Improve errors for TOML fields that support workspace inheritance (rust-lang/cargo#11113 )
- switch to `std::task::ready!()` where possible (rust-lang/cargo#11130 )
- Report cmd aliasing failure with more contexts (rust-lang/cargo#11087 )
- minor: remove unused mut (rust-lang/cargo#11127 )
- fix(cli): Forward non-UTF8 arguments to external subcommands (rust-lang/cargo#11118 )
- This change adds an example to the authors attribute in the manifest. (rust-lang/cargo#10938 )
- Add support for relative git submodule paths (rust-lang/cargo#11106 )
- make unknown features on `cargo add` more discoverable (rust-lang/cargo#11098 )
- Unlink old final artifacts before compilation (rust-lang/cargo#11122 )
- refactor(cli): Prepare for clap v4 (rust-lang/cargo#11116 )
- fix(cli): Error trailing args rather than ignore (rust-lang/cargo#11119 )
- Add a minor clarification (rust-lang/cargo#11093 )
- doc(changelog): mention CVE fixes (rust-lang/cargo#11104 )
2022-09-27 17:46:42 +01:00
Jacob Hoffman-Andrews
8846c0853d
rustdoc: use CSS containment to speed up render
...
https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Containment
This affected layout a little and required adjustments to the CSS to
keep spacing the same. In particular, the margins of adjacent items
usually overlap with each other. However, when an item has contain:
layout, any margins of child nodes push out the size of the item itself.
This was making spacing between items a little too big. To solve that, I
removed margins in some places: in particular for certain classes that
often occur at the end of a `details.rustdoc-toggle` block, I removed
their bottom margin. Generally, the margins provided by the next item
down are sufficient.
Also remove an unnecessary margin-top on .code-header.
2022-09-27 09:21:24 -07:00
Takayuki Maeda
d7b6bd8f13
improve errors for incomplete functions in struct definitions
2022-09-28 01:03:18 +09:00
Urgau
9ad2f00f6a
Stabilize bench_black_box
2022-09-27 17:38:51 +02:00
Ralf Jung
67fd09d3b8
also query type_uninhabited_from
2022-09-27 16:20:23 +02:00
Arthur Cohen
99d57ee23d
core: Mark all safe intrinsics with #[rustc_safe_intrinsic]
2022-09-27 15:55:42 +02:00
Arthur Cohen
0ab2c91a2d
attributes: Add #[rustc_safe_intrinsic] builtin
2022-09-27 15:55:42 +02:00
Deadbeef
27b280e1b5
Fix ICE in const_trait check code
...
This fixes #102156 .
2022-09-27 13:47:32 +00:00
Mara Bos
20bb600849
Remove confusing drop.
2022-09-27 13:31:52 +02:00
Mara Bos
ba7bf1d8ef
Update doc comments.
2022-09-27 13:31:52 +02:00
Mara Bos
cf53fef0d6
Turn format arguments Vec into its own struct.
...
With efficient lookup through a hash map.
2022-09-27 13:31:52 +02:00
Mara Bos
14065639ca
Update test.
2022-09-27 13:31:51 +02:00
Mara Bos
c1c6e3ae7c
Add clarifying comments.
2022-09-27 13:31:51 +02:00
Mara Bos
8d9a5881ea
Flatten if-let and match into one.
2022-09-27 13:31:51 +02:00
Mara Bos
15754f5ea1
Move enum definition closer to its usage.
2022-09-27 13:31:51 +02:00
Mara Bos
df7fd119d2
Use if let chain.
2022-09-27 13:31:51 +02:00
Mara Bos
e65c96e4ad
Tweak comments.
2022-09-27 13:31:51 +02:00
Mara Bos
ae238efe91
Prefer new_v1_formatted instead of new_v1 with duplicates.
2022-09-27 13:31:51 +02:00
Mara Bos
00074926bb
Fix typo.
2022-09-27 13:31:51 +02:00
Mara Bos
8efc383047
Move FormatArgs structure to its own module.
2022-09-27 13:31:51 +02:00
Mara Bos
3ffcb65518
Update tests.
2022-09-27 13:31:50 +02:00
Mara Bos
9bec0de397
Rewrite and refactor format_args!() builtin macro.
2022-09-27 13:13:08 +02:00
bors
57ee5cf5a9
Auto merge of #102306 - lcnr:rustc_hir_analysis, r=compiler-errors
...
rename rustc_typeck to rustc_hir_analysis
first part of https://github.com/rust-lang/compiler-team/issues/529
r? `@compiler-errors`
2022-09-27 10:45:57 +00:00
David Wood
2286888ef9
session: remove now-unnecessary lint #[allow]
s
...
In #101230 , the internal diagnostic migration lints -
`diagnostic_outside_of_impl` and `untranslatable_diagnostic` - were
modified so that they wouldn't trigger on functions annotated with
`#[rustc_lint_diagnostics]`. However, this change has to make it into
the bootstrap compiler before the `#[allow]` annotations that it aims to
remove can be removed, which is possible now that #102051 has landed.
Signed-off-by: David Wood <david.wood@huawei.com>
2022-09-27 11:01:49 +01:00
lcnr
1fc86a63f4
rustc_typeck to rustc_hir_analysis
2022-09-27 10:37:23 +02:00
bors
d9297d22ad
Auto merge of #102314 - TaKO8Ki:add-label-to-struct-enum-union-ident, r=estebank
...
Add a label to struct/enum/union ident name
Based on https://github.com/rust-lang/rust/pull/94996#discussion_r831694150
cc: `@estebank`
2022-09-27 07:30:11 +00:00
Nicholas Nethercote
b69c335327
Tweak FulfillProcessor
.
...
Avoids some unnecessary references and lifetimes.
2022-09-27 16:37:00 +10:00
Nicholas Nethercote
c91c64708b
Fix an incorrect comment.
...
If a `\x` escape occurs in a non-byte literals (e.g. char literal,
string literal), it must be <= 0xff.
2022-09-27 15:25:34 +10:00
bors
de0b511daa
Auto merge of #102189 - davidtwco:translation-derive-enums, r=compiler-errors
...
macros: diagnostic derive on enums
Part of #100717 .
Extends `#[derive(Diagnostic)]` to work on enums too where each variant acts like a distinct diagnostic - being able to represent diagnostics this way can be quite a bit simpler for some parts of the compiler.
r? `@compiler-errors`
cc `@Xiretza`
2022-09-27 04:39:25 +00:00
John Millikin
259bbfbc3d
Add negation methods for signed non-zero integers.
2022-09-27 13:15:55 +09:00
Ellis Hoag
6d01c6d9c8
lint and remove unused diagnostic
2022-09-26 19:57:40 -07:00
Michael Goulet
594134d873
Structured suggestion for missing mut/const in pointer
2022-09-27 02:47:07 +00:00
Nicholas Nethercote
7f7e2165b1
Rename some variables.
...
These make the delimiter processing clearer.
2022-09-27 12:04:03 +10:00
bors
cd4d9d934f
Auto merge of #102331 - notriddle:rollup-dmefd2d, r=notriddle
...
Rollup of 6 pull requests
Successful merges:
- #102283 (Improve code example for Option::unwrap_or_default)
- #102319 (rustdoc: merge CSS `table` rules into `.docblock`)
- #102321 ( Rustdoc-Json: List impls for primitives)
- #102322 (Document that Display automatically implements ToString)
- #102325 (rustdoc: give `.line-number` / `.line-numbers` meaningful names)
- #102326 (rustdoc: Update doc comment for splitn_mut to include mutable in the …)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
2022-09-27 01:58:36 +00:00
Takayuki Maeda
5d05908c70
fix a ui test
2022-09-27 10:28:53 +09:00
Takayuki Maeda
4f44dee501
add a label to struct/enum/union ident name
2022-09-27 10:28:50 +09:00
Takayuki Maeda
e123a61297
create a new local var
2022-09-27 10:22:46 +09:00
Matthew Kelly
0d9c01480b
remove implied link bound per review
...
also update .stderr outputs
2022-09-26 20:50:33 -04:00
Matthew Kelly
24aab524cb
Merge remote-tracking branch 'origin/master' into mpk/add-long-error-message-for-E0311
2022-09-26 19:59:52 -04:00