Commit Graph

140199 Commits

Author SHA1 Message Date
Alex Huang
00f98e6810 ./configure script should only show blocks (and associated comments) where it is not default 2023-03-03 17:27:29 -05:00
Guillaume Gomez
51e976948d Emit an error for unclosed generic 2023-03-03 20:49:25 +01:00
Matthias Krüger
dadfbb6a4b
Rollup merge of #108647 - nikic:pgo-sh, r=jyn514
Remove dead pgo.sh file

This has been replaced by stage-build.py.
2023-03-03 20:45:01 +01:00
Matthias Krüger
7a0fc8e35e
Rollup merge of #108634 - SUPERCILEX:patch-1, r=JohnTitor
Add link to component dashboard

It's a pain to find otherwise.
2023-03-03 20:45:01 +01:00
Matthias Krüger
a8b9f47638
Rollup merge of #104549 - folkertdev:unstable-book-export-executable-symbols, r=WaffleLapkin
add -Zexport-executable-symbols to unstable book

This flag has been extremely useful to me, but it's hard to discover. The text contains a bunch of terms that hopefully a search engine will pick up on when someone searches for this functionality.
2023-03-03 20:44:59 +01:00
Matthias Krüger
f9b122a7d8
Rollup merge of #108674 - flip1995:clippy_backport, r=Manishearth
Clippy Fix array-size-threshold config deserialization error

Complementary PR to https://github.com/rust-lang/rust/pull/108673 in order to also get this into the **next** beta.

r? ``@Mark-Simulacrum``
2023-03-03 20:06:28 +01:00
Matthias Krüger
8a21bcee25
Rollup merge of #108644 - KittyBorgX:hashmap-toml, r=albertlarsan68
Allow setting hashmap toml values in `./configure`

Fixes https://github.com/rust-lang/rust/issues/108621
2023-03-02 23:05:30 +01:00
Matthias Krüger
0dc12b9dec
Rollup merge of #108584 - GuillaumeGomez:rustdoc-search-background, r=notriddle
Put backtick content from rustdoc search errors into a <code> elements

Some screenshots of the result:

![Screenshot from 2023-02-28 22-37-09](https://user-images.githubusercontent.com/3050060/221990290-fa84f1cf-5a64-4ce5-8433-ee36cedf4c00.png)
![Screenshot from 2023-02-28 22-36-59](https://user-images.githubusercontent.com/3050060/221990298-f8177eeb-894b-4fce-a6fc-06d17c8b7ca2.png)
![Screenshot from 2023-02-28 22-36-51](https://user-images.githubusercontent.com/3050060/221990301-41bffd64-d041-41f1-995a-983925b1fbb1.png)

You can test it [here](https://rustdoc.crud.net/imperio/rustdoc-search-background/foo/index.html?search=%22).

r? ```@notriddle```
2023-03-02 23:05:29 +01:00
Matthias Krüger
a27a4e4c7a
Rollup merge of #108367 - compiler-errors:xl-builders-again, r=pietroalbini
Re-apply "switch to the macos-12-xl builder"

This reverts commit e63ec2e140, essentially re-applying fcbae989ae.

r? ````@pietroalbini````
2023-03-02 23:05:28 +01:00
Matthias Krüger
f75f440bbf
Rollup merge of #108022 - CraftSpider:align-bytes, r=oli-obk
Support allocations with non-Box<[u8]> bytes

This is prep work for allowing miri to support passing pointers to C code, which will require `Allocation`s to be correctly aligned. Currently, it just makes `Allocation` generic and plumbs the necessary changes through the right places.

The follow-up to this will be adding a type in the miri interpreter which correctly aligns the bytes, using that for the Miri engine, then allowing Miri to pass pointers into these allocations to C calls.

Based off of #100467, credit to ```@emarteca``` for the code
2023-03-02 23:05:27 +01:00
Alex Macleod
23d47573f6
Fix array-size-threshold config deserialization error 2023-03-02 21:42:11 +01:00
Vadim Petrochenkov
c83553da31 rustc_middle: Remove trait DefIdTree
This trait was a way to generalize over both `TyCtxt` and `Resolver`, but now `Resolver` has access to `TyCtxt`, so this trait is no longer necessary.
2023-03-02 23:46:44 +04:00
bors
7e966bcd03 Auto merge of #108640 - matthiaskrgr:rollup-rii4t5t, r=matthiaskrgr
Rollup of 5 pull requests

Successful merges:

 - #108516 (Restrict `#[rustc_box]` to `Box::new` calls)
 - #108575 (Erase **all** regions when probing for associated types on ambiguity in astconv)
 - #108585 (Run compiler test suite in parallel on Fuchsia)
 - #108606 (Add test case for mismatched open/close delims)
 - #108609 (Highlight whole expression for E0599)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2023-03-02 14:04:22 +00:00
KittyBorgX
a6580baa6c Allow setting hashmap toml values in ./configure 2023-03-02 19:00:26 +05:30
Guillaume Gomez
6b0b65424a Update rustdoc-js test tool 2023-03-02 12:59:04 +01:00
Guillaume Gomez
4e560d7d0b Put backtick content from rustdoc search errors into a <code> elements 2023-03-02 12:59:04 +01:00
Nikita Popov
e958198e22 Remove dead pgo.sh file
This has been replaced by stage-build.py.
2023-03-02 11:05:49 +01:00
Matthias Krüger
832987bb1e
Rollup merge of #108609 - clubby789:e0599-highlight, r=estebank
Highlight whole expression for E0599

Fixes #108603

This adds a secondary label to highlight the whole expression leading to the error. It also prevents empty labels being recognised as 'unexpected' by compiletest - otherwise, tests with NOTE annotations would pick up empty labels.

`@rustbot` label +A-diagnostics
2023-03-02 07:24:02 +01:00
Matthias Krüger
478d530af4
Rollup merge of #108585 - djkoloski:parallel_fuchsia_test_runner, r=tmandry
Run compiler test suite in parallel on Fuchsia

This also adds file locking around calls to `pm publish` as these calls are not thread-safe.
2023-03-02 07:24:01 +01:00
Matthias Krüger
c9c9283c6a
Rollup merge of #108516 - clubby789:rustc-box-restrict, r=compiler-errors
Restrict `#[rustc_box]` to `Box::new` calls

Currently, `#[rustc_box]` can be applied to any call expression with a single argument. This PR only allows it to be applied to calls to `Box::new`
2023-03-02 07:24:00 +01:00
bors
18caf88956 Auto merge of #107879 - icedrocket:update-llvm, r=cuviper
Update LLVM submodule

Fixes #105626
2023-03-02 05:27:32 +00:00
clubby789
d845769557 Restrict #[rustc_box] to Box::new calls 2023-03-02 02:42:19 +00:00
bors
864b6258fc Auto merge of #106673 - flba-eb:add_qnx_nto_stdlib, r=workingjubilee
Add support for QNX Neutrino to standard library

This change:

- adds standard library support for QNX Neutrino (7.1).
- upgrades `libc` to version `0.2.139` which supports QNX Neutrino

`@gh-tr`

⚠️ Backtraces on QNX require https://github.com/rust-lang/backtrace-rs/pull/507 which is not yet merged! (But everything else works without these changes) ⚠️

Tested mainly with a x86_64 virtual machine (see qnx-nto.md) and partially with an aarch64 hardware (some tests fail due to constrained resources).
2023-03-02 02:41:42 +00:00
Alex Saveau
70b608dad5
Add link to component dashboard 2023-03-01 18:30:35 -08:00
David Koloski
c9f1a541b3 Run compiler test suite in parallel on Fuchsia 2023-03-01 15:35:00 -05:00
Dylan DPC
38461f8b8a
Rollup merge of #108394 - ferrocene:pa-open, r=ozkanonur
Make `x doc --open` work on every book

Before this PR, the `--open` flag had to be configured explicitly for every book, and most of them didn't configure it, resulting in the flag silently failing in all but two books.

In this PR, the code to check for the `--open` flag is in the underlying `RustbookSrc` step rather than all the individual steps. This is done by passing the parent step as a field of `RustbookSrc`, so that we can check for the correct step in `maybe_open_in_browser`.

This was part of a larger change that in the end wasn't worth it. Still, I think it could be useful as-is.
2023-03-01 23:40:19 +05:30
Dylan DPC
f03e5345aa
Rollup merge of #108143 - notriddle:notriddle/filter-exclamation-macro, r=GuillaumeGomez
rustdoc: search by macro when query ends with `!`

Related to #96399

Note: the `never` type alias is tested in [`/tests/rustdoc-js-std/alias-3.js`](08ad401633/tests/rustdoc-js-std/alias-3.js)

## Before

![image](https://user-images.githubusercontent.com/1593513/219504192-54cc0753-ff97-4a37-ad4a-8ae915181325.png)

## After

![image](https://user-images.githubusercontent.com/1593513/219504251-589a7e11-1e7b-4b7b-879d-1b564080017c.png)
2023-03-01 23:40:18 +05:30
KittyBorgX
a90e7d4658 Rename src/etc/vscode_settings.json to rust_analyzer_settings.json 2023-03-01 22:58:05 +05:30
clubby789
6c2a952b56 Highlight whole expression for E0599 2023-03-01 16:57:11 +00:00
Joshua Nelson
daf99a437e Remove llvm.skip-rebuild option
This was added to in 2019 to speed up rebuild times when LLVM was
modified. Now that download-ci-llvm exists, I don't think it makes sense
to support an unsound option like this that can lead to miscompiles; and
the code cleanup is nice too.
2023-03-01 10:49:28 -06:00
Michael Woerister
422208ae52 Use UnordSet instead of FxHashSet for names_imported_by_glob_use query. 2023-03-01 10:20:43 +01:00
Michael Woerister
f0eadbafd4 Use LocalDefIdSet instead of FxHashSet for reachable_set query. 2023-03-01 10:19:25 +01:00
bors
bcb610da7f Auto merge of #108587 - matthiaskrgr:rollup-rw6po59, r=matthiaskrgr
Rollup of 10 pull requests

Successful merges:

 - #108376 (compiler/rustc_session: fix sysroot detection logic)
 - #108400 (add llvm cgu instructions stats to perf)
 - #108496 (fix #108495, postfix decrement and prefix decrement has no warning)
 - #108505 (Further unify validity intrinsics)
 - #108520 (Small cleanup to `one_bound_for_assoc_type`)
 - #108560 (Some `infer/mod.rs` cleanups)
 - #108563 (Make mailmap more correct)
 - #108564 (Fix `x clean` with specific paths)
 - #108571 (Add contains_key to SortedIndexMultiMap)
 - #108578 (Update Fuchsia platform team members)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2023-03-01 06:23:19 +00:00
bors
5983a3a99e Auto merge of #108586 - matthiaskrgr:rollup-ry9u2ou, r=matthiaskrgr
Rollup of 8 pull requests

Successful merges:

 - #108297 (Exit when there are unmatched delims to avoid noisy diagnostics)
 - #108531 (rustdoc: Show that repeated expression arrays can be made with constant values)
 - #108536 (Update books)
 - #108550 (Remove the `capture_disjoint_fields` feature)
 - #108551 (Descriptive error when users try to combine RPITIT/AFIT with specialization)
 - #108554 (Only look for param in item's generics if it actually comes from generics)
 - #108555 (Fix a race in the query system)
 - #108558 (add missing feature in core/tests)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2023-03-01 03:11:44 +00:00
Matthias Krüger
cd5352dbce
Rollup merge of #108578 - djkoloski:update_fuchsia_team, r=tmandry
Update Fuchsia platform team members

r? `@tmandry`
2023-03-01 01:22:00 +01:00
Matthias Krüger
58576663db
Rollup merge of #108536 - rustbot:docs-update, r=ehuss
Update books

## rust-lang/book

1 commits in d94e03a18a2590ed3f1c67b859cb11528d2a2d5c..21a2ed14f4480dab62438dcc1130291bebc65379
2023-02-13 19:45:29 UTC to 2023-02-13 19:45:29 UTC

- Removed "," typo on ch03-01 line 85 (rust-lang/book#3537)

## rust-lang/reference

1 commits in e5adb99c04817b7fbe08f4ffce5b36702667345f..a9afb04b47a84a6753e4dc657348c324c876102c
2023-02-14 14:57:15 UTC to 2023-02-14 14:57:15 UTC

- Document the `efiapi` ABI (rust-lang/reference#1309)

## rust-lang/rust-by-example

1 commits in efe23c4fe12e06351b8dc8c3d18312c761455109..af0998b7473839ca75563ba3d3e7fd0160bef235
2023-02-15 18:17:20 UTC to 2023-02-15 18:17:20 UTC

- Typographical mistake in tuples.md (rust-lang/rust-by-example#1685)

## rust-lang/rustc-dev-guide

30 commits in 41a96ab971cb45e2a184df20619ad1829765c990..b06dab84083390e0ee1e998f466545a8a1a76a9f
2023-02-26 22:30:52 UTC to 2023-02-14 05:16:01 UTC

- Fixed typing errors (rust-lang/rustc-dev-guide#1622)
- this remains true (rust-lang/rustc-dev-guide#1620)
- diagnostics: small fixes/improvements (rust-lang/rustc-dev-guide#1618)
- typo (rust-lang/rustc-dev-guide#1616)
- typo (rust-lang/rustc-dev-guide#1617)
- keep "grey area" lint summary green (rust-lang/rustc-dev-guide#1619)
- new solver: write canonicalization chapter (rust-lang/rustc-dev-guide#1595)
- bootstrap now creates a usable toolchain when building stage0 std (rust-lang/rustc-dev-guide#1615)
- llvm 13 is now not supported (rust-lang/rustc-dev-guide#1612)
- enable AND search (rust-lang/rustc-dev-guide#1607)
- Vetting deps datecheck (rust-lang/rustc-dev-guide#1614)
- mention Dev desktops, to help with LLVM builds (rust-lang/rustc-dev-guide#1613)
- fix and clarify llvm bugfix policy (rust-lang/rustc-dev-guide#1611)
- lower-case "Compiler" in headings, for consistency (and looks) (rust-lang/rustc-dev-guide#1605)
- Explain what the rest of the backend agnostic page is about (rust-lang/rustc-dev-guide#1609)
- Bump dependencies to fix CI (rust-lang/rustc-dev-guide#1610)
- rustc_codegen_ssa feels permanent enough not to need date-check (rust-lang/rustc-dev-guide#1606)
- make use of the `host` symlink in the build directory, to ease things (rust-lang/rustc-dev-guide#1608)
- have checkboxes only point to date-check lines in files (rust-lang/rustc-dev-guide#1603)
- remove stray text (rust-lang/rustc-dev-guide#1604)
- Typo (rust-lang/rustc-dev-guide#1601)
- Typo (rust-lang/rustc-dev-guide#1602)
- Add link to vscode settings in Rust repo (rust-lang/rustc-dev-guide#1591)
- avoid code duplication by including files in docs (rust-lang/rustc-dev-guide#1598)
- howto run the examples (rust-lang/rustc-dev-guide#1593)
- Add sample CodeLLDB launch.json (rust-lang/rustc-dev-guide#1482)
- typo (rust-lang/rustc-dev-guide#1600)
- use actual names (rust-lang/rustc-dev-guide#1594)
- Fix a typo (rust-lang/rustc-dev-guide#1597)
- Add Neovim configuration information (rust-lang/rustc-dev-guide#1545)
2023-03-01 01:20:23 +01:00
Matthias Krüger
371904bba6
Rollup merge of #108297 - chenyukang:yukang/delim-error-exit, r=petrochenkov
Exit when there are unmatched delims to avoid noisy diagnostics

From https://github.com/rust-lang/rust/pull/104012#issuecomment-1311764832
r? ``@petrochenkov``
2023-03-01 01:20:22 +01:00
Weihang Lo
741f1afdd5
Update cargo
10 commits in 9d5b32f503fc099c4064298465add14d4bce11e6..9880b408a3af50c08fab3dbf4aa2a972df71e951
2023-02-22 23:04:16 +0000 to 2023-02-28 19:39:39 +0000

- bump jobserver to respect `--jobserver-auth=fifo:PATH` (rust-lang/cargo#11767)
- Addition of support for -F as an alias for --features (rust-lang/cargo#11774)
- Added documentation for the configuration discovery of `cargo install` to the man pages (rust-lang/cargo#11763)
- Fix Cargo removing the sparse+ prefix from sparse URLs in .crates.toml (rust-lang/cargo#11756)
- Fix warning with tempfile (rust-lang/cargo#11771)
- Error message for transitive artifact dependencies with targets the package doesn't directly interact with (rust-lang/cargo#11643)
- Fix tests with nondeterministic ordering (rust-lang/cargo#11766)
- Make some blocking tests non-blocking (rust-lang/cargo#11650)
- Suggest cargo add when installing library crate (rust-lang/cargo#11410)
- chore: bump is-terminal to 0.4.4 (rust-lang/cargo#11759)
2023-02-28 21:10:55 +00:00
James Farrell
848f6f9b0d Add a new config flag, dist.include-mingw-linker.
The flag controls whether to copy the linker, DLLs, and various
libraries from MinGW into the rustc toolchain.

It applies only when the host or target is pc-windows-gnu.

The flag is true by default to preserve existing behavior.
2023-02-28 20:37:05 +00:00
Josh Stone
565de58dd7 Skip test download_ci_llvm with modified LLVM 2023-02-28 12:02:14 -08:00
David Koloski
8c6c8b14b8 Update Fuchsia platform team members 2023-02-28 14:40:13 -05:00
Florian Bartels
f1a399cc40
Mark stdlib for QNX as fully available 2023-02-28 15:59:53 +01:00
Florian Bartels
3ce2cd059f
Add QNX Neutrino support to libstd
Co-authored-by: gh-tr <troach@qnx.com>
2023-02-28 15:59:47 +01:00
clubby789
a321013f3e
Fix x clean with specific paths 2023-02-28 14:53:36 +00:00
yukang
f01d0c02e7 Exit when there are unmatched delims to avoid noisy diagnostics 2023-02-28 07:55:19 +00:00
bors
5157d938c4 Auto merge of #108098 - notriddle:notriddle/rustdoc-tooltip-alloc, r=GuillaumeGomez
rustdoc: reduce allocations when generating tooltips

An attempt to reduce the perf regression in
https://github.com/rust-lang/rust/pull/108052#issuecomment-1430631861
2023-02-28 07:27:32 +00:00
Matthias Krüger
2375d7f386
Rollup merge of #108308 - bjorn3:faster_bootstrap_build, r=albertlarsan68
Allow building serde and serde_derive in parallel

This reduces build time of bootstrap by ~6s
2023-02-27 18:48:48 +01:00
rustbot
8732fcd0c9 Update books 2023-02-27 12:00:26 -05:00
bjorn3
fdbc3c2dcf Allow building serde and serde_derive in parallel
This reduces build time of bootstrap by ~6s
2023-02-27 11:19:02 +00:00
Matthias Krüger
37338b8d99
Rollup merge of #108500 - RalfJung:miri, r=RalfJung
update Miri

r? ``@ghost``
2023-02-27 06:11:54 +01:00
Matthias Krüger
c813994f7a
Rollup merge of #108494 - GuillaumeGomez:cleanup-js, r=notriddle
Clean up JS files code a bit

I mostly moved values closer to where they are used to make the code reading easier.

r? ```@notriddle```
2023-02-27 06:11:54 +01:00
Matthias Krüger
2f6ba7b4da
Rollup merge of #108463 - clubby789:update-check-output, r=albertlarsan68
bootstrap: Update the output of the `check` descriptions

This should bring the output from `x check` in line with the changes in #108171
2023-02-27 06:11:52 +01:00
Guillaume Gomez
27db688203 Clean up JS files code a bit 2023-02-26 20:58:36 +01:00
bors
d962ea5789 Auto merge of #108474 - Jarcho:clippyup, r=Manishearth
Update Clippy

Seems like `@flip1995` so this is a couple days late.

r? `@Manishearth`
2023-02-26 18:45:47 +00:00
Ralf Jung
cb45103358 Merge from rustc 2023-02-26 18:13:57 +01:00
Ralf Jung
9fb185210e Preparing for merge from rustc 2023-02-26 18:13:46 +01:00
Matthias Krüger
9c27fc7d34
Rollup merge of #108484 - Nilstrieb:˂DiagnosticItem˂FromFn˃ as From˂˂LangItemFromFn˃˃˃꞉꞉from, r=cjgillot
Remove `from` lang item

It was probably a leftover from the old `?` desugaring but anyways, it's unused now except for clippy, which can just use a diagnostics item.
2023-02-26 12:05:01 +01:00
Matthias Krüger
edd27cf4ca
Rollup merge of #108482 - Ezrashaw:force-error-docs, r=GuillaumeGomez
statically guarantee that current error codes are documented

Closes #61137 (that's right!)

Pretty simple refactor (often just a change from `Result<Option<&str>>` to `Result<&str>`)

r? `@GuillaumeGomez` (could you specially look at 53044158eff0d64673a6100f701c57b484232aca? I believe you wrote that in the first place, just want to make sure you're happy with the change)
2023-02-26 12:05:00 +01:00
Matthias Krüger
19b8685b06
Rollup merge of #108379 - compiler-errors:hir-error-guaranteed, r=cjgillot
Add `ErrorGuaranteed` to `hir::{Expr,Ty}Kind::Err` variants

First step in making the `Err` variants of `ExprKind` and `TyKind` require an `ErrorGuaranteed` during parsing. Making the corresponding AST versions require `ErrorGuaranteed` is a bit harder, whereas it was pretty easy to do this for HIR, so let's do that first.

The only weird thing about this PR is that `ErrorGuaranteed` is moved to `rustc_span`. This is *certainly* not the right place to put it, but `rustc_hir` cannot depend on `rustc_error` because the latter already depends on the former. Should I just pull out some of the error machinery from `rustc_error` into an even more minimal crate that `rustc_hir` can depend on? Advice would be appreciated.
2023-02-26 12:04:58 +01:00
Nilstrieb
312020ef6a Remove from_fn lang item
It was probably a leftover from the old `?` desugaring but anyways, it's
unused now except for clippy, which can just use a diagnostics item.
2023-02-26 09:15:54 +00:00
Ezra Shaw
53044158ef
refactor: improve error-index-generator dependency 2023-02-26 20:13:06 +13:00
Ezra Shaw
90677edcba
refactor: statically guarantee that current error codes are documented 2023-02-26 20:12:36 +13:00
bors
70fd012439 Auto merge of #108473 - matthiaskrgr:rollup-qjyae58, r=matthiaskrgr
Rollup of 8 pull requests

Successful merges:

 - #107062 (Do some cleanup of doc/index.md)
 - #107890 (Lint against `Iterator::map` receiving a callable that returns `()`)
 - #108431 (Add regression test for #107918)
 - #108432 (test: drop unused deps)
 - #108436 (make "proc macro panicked" translatable)
 - #108444 (docs/test: add UI test and docs for `E0476`)
 - #108449 (Do not lint ineffective unstable trait impl for unresolved trait)
 - #108456 (Complete migrating `ast_passes` to derive diagnostics)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2023-02-26 02:04:23 +00:00
Jason Newcomb
4a2de63ae3 Merge commit '149392b0baa4730c68f3c3eadf5c6ed7b16b85a4' into clippyup 2023-02-25 19:28:50 -05:00
Matthias Krüger
65eecc6b59
Rollup merge of #108444 - Ezrashaw:add-test+docs-for-e0476, r=GuillaumeGomez
docs/test: add UI test and docs for `E0476`

Final undocumented error code. Not entirely sure about wording in the docs.

Part of https://github.com/rust-lang/rust/issues/61137.

r? ```@compiler-errors```

cc ```@compiler-errors```
2023-02-26 00:46:28 +01:00
Matthias Krüger
f840799385
Rollup merge of #107062 - tgross35:update-doc-index, r=ehuss
Do some cleanup of doc/index.md

I think a lot of people get to this landing page from `rustup doc`, and it's a bit tricky to find some useful information. I attempted to clean it up here a bit, from the commit message:

- Add quick link to API docs
- Add marker for external links, to help offline users
- Add information about using 'cargo doc' and the playground
- Clean up some of the wording
- Update body & header style to match rustdoc defaults
- Bump heading levels so main page header is 1, others are 2 (all were level 1 before)
2023-02-26 00:46:25 +01:00
Jason Newcomb
bc184e9c7d Merge branch 'master' into rustup 2023-02-25 17:43:19 -05:00
Michael Goulet
0b6b373f48
Rollup merge of #108229 - lionellloh:issue-107049, r=Mark-Simulacrum
[107049] Recognise top level keys in config.toml.example

Closes #107049

Test Plan

Configure changelog-seen
```
lionellloh@lionellloh-mbp rust % ./configure --set changelog-seen=1
configure: processing command line
configure:
configure: changelog-seen       := 1
configure: build.configure-args := ['--set', 'changelog-seen=1']
configure:
configure: writing `config.toml` in current directory
configure:
configure: run `python /Users/lionellloh/rust/x.py --help`
lionellloh@lionellloh-mbp rust % diff config.toml config.toml.example
16c16
< changelog-seen = 1
---
> changelog-seen = 2
331c331
< configure-args = ['--set', 'changelog-seen=1']
---
> #configure-args = []
675c675
< [target.x86_64-apple-darwin]
---
> [target.x86_64-unknown-linux-gnu]
809d808
<
```

Configure profile

```
lionellloh@lionellloh-mbp rust % ./configure --set profile=xyz
configure: processing command line
configure:
configure: profile              := xyz
configure: build.configure-args := ['--set', 'profile=xyz']
configure:
configure: writing `config.toml` in current directory
configure:
configure: run `python /Users/lionellloh/rust/x.py --help`
lionellloh@lionellloh-mbp rust % diff config.toml config.toml.example
26c26
< profile = xyz
---
> #profile = <none>
331c331
< configure-args = ['--set', 'profile=xyz']
---
> #configure-args = []
675c675
< [target.x86_64-apple-darwin]
---
> [target.x86_64-unknown-linux-gnu]
809d808
<
```
2023-02-25 11:53:10 -08:00
Michael Goulet
390551716a
Rollup merge of #107848 - clubby789:x-setup-options, r=Mark-Simulacrum
Split `x setup` sub-actions to CLI arguments

Closes #107846

This adds a new `none` profile option which simply skips the `config.toml` step. It also adds `hook` and `vscode` subcommands, for installing the pre-push hook and getting `settings.json` respectively.
2023-02-25 11:53:09 -08:00
Michael Goulet
b90a385f26
Rollup merge of #105736 - chenyukang:yukang/add-mir-opt-level-testing, r=jyn514
Test that the compiler/library builds with validate-mir

Fixes #105706
2023-02-25 11:53:08 -08:00
Michael Goulet
0f4a7d174e Make clippy happy 2023-02-25 19:46:36 +00:00
Michael Goulet
a772a6fc2a Add ErrorGuaranteed to HIR TyKind::Err 2023-02-25 19:46:36 +00:00
clubby789
b30d0da6f3 Update the output of the check descriptions 2023-02-25 19:18:51 +00:00
bors
31448badfd Auto merge of #108450 - matthiaskrgr:rollup-rqvfgu3, r=matthiaskrgr
Rollup of 7 pull requests

Successful merges:

 - #108354 (Update `fuchsia-test-runner.py` and docs)
 - #108404 (support `x fmt` for sub and outside of rust directories)
 - #108407 (docs: use intra-doc links for `Vec::get(_mut)`)
 - #108410 (rustdoc: avoid including `<li>` tags in item table short desc)
 - #108412 (Fix GUI test navigation bug)
 - #108433 (Wrap missing provider message correctly)
 - #108434 (Migrate `rustc_hir_analysis` to session diagnostic [Part One])

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2023-02-25 16:48:04 +00:00
bors
ffd12f67cf Auto merge of #2798 - LevitatingLion:master, r=oli-obk
Get Miri working on ARM

- Add a shim for `llvm.arm.hint`, which is required by `core::hint::spin_loop` on `arm` targets. The shim simply calls `yield_active_thread` on a YIELD hint, just like the shim for `llvm.aarch64.isb` that's already present.
- Change the signature of `miri_host_to_target_path` to use `c_char` instead of `i8`, to make it compatible with `CStr` on targets where `c_char` is unsigned. The implementation of `miri_host_to_target_path` accesses the memory as bytes and does not need to be adjusted.
- Enable ARM targets in CI. Specifically, `aarch64-unknown-linux-gnu` and `arm-unknown-linux-gnueabi` on the Linux host.

Since all tests also pass for `aarch64-unknown-linux-gnu` I took the liberty of adding that target to CI as well.

Fixes #2791
2023-02-25 16:45:50 +00:00
Michael Howell
96e6fb6c57
Update search eBNF with ! moved
Co-Authored-By: GuillaumeGomez <guillaume1.gomez@gmail.com>
2023-02-25 08:20:53 -07:00
Matthias Krüger
47c7d53fe6
Rollup merge of #108412 - GuillaumeGomez:fix-gui-test-navigation-bug, r=notriddle
Fix GUI test navigation bug

Following https://github.com/GuillaumeGomez/browser-UI-test/pull/438, we can now remove this `wait-for`.

Should help with #93784.

r? ``@notriddle``
2023-02-25 11:31:34 +01:00
Matthias Krüger
da90fd5a33
Rollup merge of #108410 - notriddle:notriddle/tag-item-summary, r=GuillaumeGomez
rustdoc: avoid including `<li>` tags in item table short desc

Fixes a bug seen at https://docs.rs/gl_constants/0.1.1/gl_constants/index.html
2023-02-25 11:31:34 +01:00
Matthias Krüger
91a8496b64
Rollup merge of #108404 - ozkanonur:108004, r=jyn514
support `x fmt` for sub and outside of rust directories

This PR makes `x fmt` to be succesfully work from sub or outside dir of rust.

The following cases are tested and the results were successful.
```sh
# from rust/library directory
../x fmt compiler --check
../x fmt compiler/rustc

# from outside of rust directory
../../rust/x fmt library/std library/core --check
../../rust/x fmt library/std
```

Resolves #108004

r? ``@albertlarsan68``
2023-02-25 11:31:33 +01:00
Matthias Krüger
94a783524c
Rollup merge of #108354 - djkoloski:update_fuchsia_test_runner, r=djkoloski
Update `fuchsia-test-runner.py` and docs

This updates the test runner to the latest version of the SDK and fixes debugging support for Rust source code.

r? ``@tmandry``
2023-02-25 11:31:32 +01:00
Ezra Shaw
3b51e9fde8
fix: fix issue in macro 2023-02-25 22:12:30 +13:00
Ezra Shaw
9f876cc900
docs/test: add UI test and docs for E0476 2023-02-25 19:31:02 +13:00
yukang
001bceeb1e check is default to all targets now 2023-02-25 03:11:38 +00:00
yukang
15813cf646 enable validate-mir-opts in mingw-check 2023-02-24 22:40:39 +00:00
David Koloski
6e7902bc3d Update fuchsia-test-runner.py and docs
This updates the test runner to the latest version of the SDK and fixes
debugging support for Rust source code.
2023-02-24 15:39:58 -05:00
Trevor Gross
4ecf14372f doc: cleanup of doc/index.md
- Add quick link to API docs
- Add marker for external links, to help offline users
- Add information about using 'cargo doc' and the playground
- Clean up some of the wording
- Update body & header style to match rustdoc defaults
2023-02-24 13:21:02 -05:00
LevitatingLion
9cb27d2604 CI: Move arm-unknown-linux-gnueabi tests to Windows host 2023-02-24 14:30:11 +01:00
LevitatingLion
e81ebb947c
Use full path to c_char in README
Co-authored-by: Ralf Jung <post@ralfj.de>
2023-02-24 14:27:46 +01:00
klensy
9a32db7e17 use setup_version_info! 2023-02-24 16:14:49 +03:00
klensy
47aeaba8b3 bump rustc_tools_util 2023-02-24 16:05:50 +03:00
yukang
34813e2051 Test that the compiler/library builds with -Zmir-opt-level=3 -Zvalidate-mir 2023-02-24 08:07:43 +00:00
LevitatingLion
04b2aab141 Add ARM targets to CI
Specifically `aarch64-unknown-linux-gnu` and `arm-unknown-linux-gnueabi`
2023-02-24 04:18:38 +01:00
LevitatingLion
d4d7edfdf3 Use pointers to c_char instead of i8 in miri_host_to_target_path
This makes sure that the interface of `miri_host_to_target_path` is compatible with `CStr` for targets where `c_char` is unsigned (such as ARM). This commit changes the signature of `miri_host_to_target_path` in the README and in all test cases.
2023-02-24 04:18:38 +01:00
LevitatingLion
a80f5272c6 Add shim for llvm.arm.hint
This shim is required for `core::hint::spin_loop` on `arm` targets
2023-02-24 02:59:58 +01:00
Guillaume Gomez
b6e0efe655 Update browser-ui-test version 2023-02-23 22:04:19 +01:00
Michael Howell
5a9a3df312 rustdoc: avoid including <li> tags in item table short desc
Fixes a bug seen at https://docs.rs/gl_constants/0.1.1/gl_constants/index.html
2023-02-23 13:53:27 -07:00
Nicholas Nethercote
08f28f9447 Use List::empty() instead of mk_substs(&[]). 2023-02-24 07:33:02 +11:00
Nicholas Nethercote
2200911616 Rename many interner functions.
(This is a large commit. The changes to
`compiler/rustc_middle/src/ty/context.rs` are the most important ones.)

The current naming scheme is a mess, with a mix of `_intern_`, `intern_`
and `mk_` prefixes, with little consistency. In particular, in many
cases it's easy to use an iterator interner when a (preferable) slice
interner is available.

The guiding principles of the new naming system:
- No `_intern_` prefixes.
- The `intern_` prefix is for internal operations.
- The `mk_` prefix is for external operations.
- For cases where there is a slice interner and an iterator interner,
  the former is `mk_foo` and the latter is `mk_foo_from_iter`.

Also, `slice_interners!` and `direct_interners!` can now be `pub` or
non-`pub`, which helps enforce the internal/external operations
division.

It's not perfect, but I think it's a clear improvement.

The following lists show everything that was renamed.

slice_interners
- const_list
  - mk_const_list -> mk_const_list_from_iter
  - intern_const_list -> mk_const_list
- substs
  - mk_substs -> mk_substs_from_iter
  - intern_substs -> mk_substs
  - check_substs -> check_and_mk_substs (this is a weird one)
- canonical_var_infos
  - intern_canonical_var_infos -> mk_canonical_var_infos
- poly_existential_predicates
  - mk_poly_existential_predicates -> mk_poly_existential_predicates_from_iter
  - intern_poly_existential_predicates -> mk_poly_existential_predicates
  - _intern_poly_existential_predicates -> intern_poly_existential_predicates
- predicates
  - mk_predicates -> mk_predicates_from_iter
  - intern_predicates -> mk_predicates
  - _intern_predicates -> intern_predicates
- projs
  - intern_projs -> mk_projs
- place_elems
  - mk_place_elems -> mk_place_elems_from_iter
  - intern_place_elems -> mk_place_elems
- bound_variable_kinds
  - mk_bound_variable_kinds -> mk_bound_variable_kinds_from_iter
  - intern_bound_variable_kinds -> mk_bound_variable_kinds

direct_interners
- region
  - intern_region (unchanged)
- const
  - mk_const_internal -> intern_const
- const_allocation
  - intern_const_alloc -> mk_const_alloc
- layout
  - intern_layout -> mk_layout
- adt_def
  - intern_adt_def -> mk_adt_def_from_data (unusual case, hard to avoid)
  - alloc_adt_def(!) -> mk_adt_def
- external_constraints
  - intern_external_constraints -> mk_external_constraints

Other
- type_list
  - mk_type_list -> mk_type_list_from_iter
  - intern_type_list -> mk_type_list
- tup
  - mk_tup -> mk_tup_from_iter
  - intern_tup -> mk_tup
2023-02-24 07:32:24 +11:00
ozkanonur
49516b3f57 support x fmt for sub and outside of rust directories
Signed-off-by: ozkanonur <work@onurozkan.dev>
2023-02-23 21:35:41 +03:00
Pietro Albini
317be6172a
make --open work on all books 2023-02-23 13:11:45 +01:00