about summary refs log tree commit diff
path: root/src/doc
AgeCommit message (Collapse)AuthorLines
2020-11-24Update bootstrap documentation with the new envvars for RUSTFLAGSGabriel de Perthuis-6/+2
This follows <https://github.com/rust-lang/rust/pull/63722>.
2020-11-24Rollup merge of #76858 - rcvalle:rust-lang-exploit-mitigations, r=steveklabnikJonas Schievink-0/+694
Add exploit mitigations chapter to the rustc book This section documents the exploit mitigations applicable to the Rust compiler when building programs for the Linux operating system on the AMD64 architecture and equivalent. This was done for a project I'm currently working on, and I hope it'll also be helpful to others.
2020-11-23Add exploit mitigations chapter to the rustc bookRamon de C Valle-0/+694
This section documents the exploit mitigations applicable to the Rust compiler when building programs for the Linux operating system on the AMD64 architecture and equivalent.
2020-11-23don't use cache while running PR buildsmark-2/+2
2020-11-23Update `param_env` linkCamelid-1/+1
`rustc_ty` was recently [renamed] to `rustc_ty_utils`, so this link has to be updated. [renamed]: https://github.com/rust-lang/rust/commit/f59d03038c8601a66bd165a2f1980109665d077c
2020-11-23Rename `optin_builtin_traits` to `auto_traits`Camelid-3/+3
They were originally called "opt-in, built-in traits" (OIBITs), but people realized that the name was too confusing and a mouthful, and so they were renamed to just "auto traits". The feature flag's name wasn't updated, though, so that's what this PR does. There are some other spots in the compiler that still refer to OIBITs, but I don't think changing those now is worth it since they are internal and not particularly relevant to this PR. Also see <https://rust-lang.zulipchat.com/#narrow/stream/131828-t-compiler/topic/opt-in.2C.20built-in.20traits.20(auto.20traits).20feature.20name>.
2020-11-22Drop support for cloudabi targetsLzu Tao-4/+0
2020-11-22add small explanation of why fuel can be useful for debuggingcjkenn-2/+4
2020-11-22add mir-opt section for optimization fuelcjkenn-0/+21
2020-11-16updated link for Citizen Code of Conduct (#959)Tobias-36/+1
* remove the code of conduct; instead link to https://www.rust-lang.org/conduct.html
2020-11-16Rollup merge of #78714 - m-ou-se:simplify-local-streams, r=KodrAusMara Bos-6/+1
Simplify output capturing This is a sequence of incremental improvements to the unstable/internal `set_panic` and `set_print` mechanism used by the `test` crate: 1. Remove the `LocalOutput` trait and use `Arc<Mutex<dyn Write>>` instead of `Box<dyn LocalOutput>`. In practice, all implementations of `LocalOutput` were just `Arc<Mutex<..>>`. This simplifies some logic and removes all custom `Sink` implementations such as `library/test/src/helpers/sink.rs`. Also removes a layer of indirection, as the outermost `Box` is now gone. It also means that locking now happens per `write_fmt`, not per individual `write` within. (So `"{} {}\n"` now results in one `lock()`, not four or more.) 2. Since in all cases the `dyn Write`s were just `Vec<u8>`s, replace the type with `Arc<Mutex<Vec<u8>>>`. This simplifies things more, as error handling and flushing can be removed now. This also removes the hack needed in the default panic handler to make this work with `::realstd`, as (unlike `Write`) `Vec<u8>` is from `alloc`, not `std`. 3. Replace the `RefCell`s by regular `Cell`s. The `RefCell`s were mostly used as `mem::replace(&mut *cell.borrow_mut(), something)`, which is just `Cell::replace`. This removes an unecessary bookkeeping and makes the code a bit easier to read. 4. Merge `set_panic` and `set_print` into a single `set_output_capture`. Neither the test crate nor rustc (the only users of this feature) have a use for using these separately. Merging them simplifies things even more. This uses a new function name and feature name, to make it clearer this is internal and not supposed to be used by other crates. Might be easier to review per commit.
2020-11-15add string interning wikipedia link (#960)hosseind88-1/+5
2020-11-12Provide a brief example of a data-flow analysisCamelid-0/+26
2020-11-12Explain the purpose of the bottom valueCamelid-2/+6
2020-11-12Add a section on data-flow convergenceCamelid-1/+15
2020-11-11Update booksEric Huss-0/+0
2020-11-11Links to htmldocck/@has/matches for searchabilityAlexis Bourget-1/+6
2020-11-11Update src/compiler-debugging.mdOlivier FAURE-1/+1
Co-authored-by: Joshua Nelson <joshua@yottadb.com>
2020-11-11Update link in compiler-debugging.mdOlivier FAURE-2/+6
Link didn't point to latest version of `env_logger` crate. Add an explanation to disambiguate the RUSTC_LOG syntax.
2020-11-10Add some more examples of using the compilerJoshua Nelson-3/+15
2020-11-10Merge set_panic and set_print into set_output_capture.Mara Bos-6/+1
There were no use cases for setting them separately. Merging them simplifies some things.
2020-11-09Rollup merge of #78746 - pietroalbini:i686-freebsd, r=Mark-SimulacrumDylan DPC-1/+1
Demote i686-unknown-freebsd to tier 2 compiler target While technically the `i686-unknown-freebsd` target has been a tier 2 development platform for a long time, with full toolchain tarballs available on static.rust-lang.org, due to a bug in the manifest generation the target was never available for download through rustup. The infrastructure team privately inquired the FreeBSD package maintainers, and they weren't relying on those tarballs either, so it's a fair assumption to say practically nobody is using those tarballs. This PR then removes the CI builder that produces full tarballs for the target, and moves the compilation of `rust-std` for the target in `dist-various-2`. The `x86_64-unknown-freebsd` target is *not* affected. cc `@rust-lang/infra` `@rust-lang/compiler` `@rust-lang/release` r? `@Mark-Simulacrum`
2020-11-09Add `#[cfg(panic = "...")]`David Hewitt-0/+38
2020-11-09Update src/building/how-to-build-and-run.mdCasey Rodarmor-1/+1
Co-authored-by: Joshua Nelson <joshua@yottadb.com>
2020-11-09Fix install commandCasey Rodarmor-1/+1
2020-11-09Document `src/tools/x`, an `x.py` wrapperCasey Rodarmor-0/+8
Document the newly added `x` binary that wraps `x.py`, which can be installed system-wide, and can be run from any subdirectory of a rust repo checkout.
2020-11-09Rollup merge of #78228 - pietroalbini:finally, r=Mark-SimulacrumDylan DPC-1/+7
Promote aarch64-unknown-linux-gnu to Tier 1 This PR promotes the `aarch64-unknown-linux-gnu` target to Tier 1, as proposed by [RFC 2959]: * The `aarch64-gnu` CI job is moved from `auto-fallible` to `auto`. * The platform support documentation is updated, uplifting the target to Tiert 1 with a note about missing stack probes support. * Building the documentation is enabled for the target, as we produce the `rust-docs` component for all Tier 1 platforms. [RFC 2959]: https://github.com/rust-lang/rfcs/pull/2959
2020-11-08correct minor grammar mistake (#944)Joshua Nitschke-1/+1
correct `a lots to `a lot` on implementing_new_features.md
2020-11-06Use `provide_both` link instead of `provide(_extern)`Yuki Okushi-5/+3
2020-11-06Auto merge of #75778 - AndyGauge:75521-rustdoc-book-improvements, r=jyn514bors-31/+282
75521 rustdoc book improvements Added some guidelines about documenting with rustdoc Fixes #75521
2020-11-07Rollup merge of #78726 - GuillaumeGomez:back-link-to-main-website, ↵Yuki Okushi-1/+2
r=steveklabnik Add link to rust website Fixes #30838 This doesn't fix the issue as suggested but it at least adds a link to allow to go back to the rust website. r? `@steveklabnik`
2020-11-05doc/rustc: promote aarch64-unknown-linux-gnu to tier 1Pietro Albini-1/+7
This also adds a note about missing stack probes support, per the discussion on RFC 2959.
2020-11-05Rename lint to non_autolinksGuillaume Gomez-2/+2
2020-11-05Update URLs used in the lint exampleGuillaume Gomez-14/+15
2020-11-05Rename automatic_links to url_improvementsGuillaume Gomez-1/+1
2020-11-05Improve automatic_links globallyGuillaume Gomez-10/+3
2020-11-05Extend automatic_links lint to take into account URLs without link syntaxGuillaume Gomez-9/+13
2020-11-05Add documentation for automatic_links lintGuillaume Gomez-0/+40
2020-11-04Added Rustdoc book sections for linting and embedding more examplesAndrew Gauger-31/+282
Co-authored-by: Joshua Nelson <joshua@yottadb.com>
2020-11-04ci: demote i686-unknown-freebsd to tier 2 compiler targetPietro Albini-1/+1
While technically the i686-unknown-freebsd target has been a tier 2 development platform for a long time, with full toolchain tarballs available on static.rust-lang.org, due to a bug in the manifest generation the target was never available for download through rustup. The infrastructure team privately inquired the FreeBSD package maintainers, and they weren't relying on those tarballs either, so it's a fair assumption to say practically nobody is using those tarballs. This PR then removes the CI builder that produces full tarballs for the target, and moves the compilation of rust-std for the target in dist-various-2. The x86_64-unknown-freebsd target is *not* affected.
2020-11-04Add link to rust websiteGuillaume Gomez-1/+2
2020-11-03Rollup merge of #77950 - arlosi:sha256, r=eddybMara Bos-1/+1
Add support for SHA256 source file hashing Adds support for `-Z src-hash-algorithm sha256`, which became available in LLVM 11. Using an older version of LLVM will cause an error `invalid checksum kind` if the hash algorithm is set to sha256. r? `@eddyb` cc #70401 `@est31`
2020-11-03Rollup merge of #78676 - kiffie:embedded-bare-mipsr2, r=jonas-schievinkYuki Okushi-0/+1
add mipsel-unknown-none target This adds a target for bare MIPS32r2, little endian, softfloat. This target can be used for PIC32 microcontrollers (or possibly for other devices that have a MIPS MCU core such as the M4K core). Tried to find a name for the target that is in line with the naming scheme apparently used for the other MIPS targets. r? `@jonas-schievink`
2020-11-03Rollup merge of #78616 - richkadel:unstable-book-instr-cov, r=tmandryYuki Okushi-0/+169
Document -Zinstrument-coverage r? ``@tmandry`` FYI ``@wesleywiser`` Here is my proposed document for LLVM source-based code coverage. I based it on the `profile.md` page, in the same directory, and on the Clang guide for LLVM source-based coverage.
2020-11-02add mipsel-unknown-none targetStephan-0/+1
2020-11-02addressed feedbackRich Kadel-15/+24
2020-11-01Document -Zinstrument-coverageRich Kadel-0/+160
2020-10-29Rollup merge of #78492 - ehuss:update-books, r=ehussYuki Okushi-0/+0
Update books ## nomicon 7 commits in 6e57e64501f61873ab80cb78a07180a22751a5d6..69333eddb1de92fd17e272ce4677cc983d3bd71d 2020-09-14 11:40:23 -0400 to 2020-10-17 15:44:12 -0700 - Tweak GHA config (rust-lang-nursery/nomicon#240) - Fix link for `[T]` (rust-lang-nursery/nomicon#239) - Update casts.md (rust-lang-nursery/nomicon#232) - [WIP] Add more links (rust-lang-nursery/nomicon#180) - Data Race definition should be more precise (rust-lang-nursery/nomicon#219) - Update the diagnostic of `error[E0597]` in dropck.md (rust-lang-nursery/nomicon#157) - fix typo in Lifetimes mutable reference aliasing section (rust-lang-nursery/nomicon#225) ## reference 3 commits in 1b78182e71709169dc0f1c3acdc4541b6860e1c4..10c16caebe475d0d11bec0531b95d7697856c13c 2020-10-11 13:53:47 -0700 to 2020-10-25 20:51:26 -0700 - Add `unsafe` for `mod` and `extern`. (rust-lang-nursery/reference#898) - mention how unions interact with dropping (rust-lang-nursery/reference#897) - Add `move_ref_pattern` docs (rust-lang-nursery/reference#881) ## book 2 commits in 451a1e30f2dd137aa04e142414eafb8d05f87f84..13e1c05420bca86ecc79e4ba5b6d02de9bd53c62 2020-10-05 09:11:18 -0500 to 2020-10-20 14:57:32 -0500 - Referencing to Appendix B (rust-lang/book#2481) - Use GITHUB_PATH instead of add-path (rust-lang/book#2477) ## rust-by-example 2 commits in 152475937a8d8a1f508d8eeb57db79139bc803d9..99eafee0cb14e6ec641bf02a69d7b30f6058349a 2020-10-09 09:29:50 -0300 to 2020-10-21 14:21:55 -0300 - Formatting footer items. (rust-lang/rust-by-example#1385) - Add partial moves example for `move_ref_pattern` stabilization (rust-lang/rust-by-example#1377) ## edition-guide 3 commits in 81f16863014de60b53de401d71ff904d163ee030..7bc9b7a5e800f79df62947cb7d566fd2fbaf19fe 2020-08-27 13:56:31 -0700 to 2020-10-23 18:31:23 -0500 - A few small updates. (rust-lang/edition-guide#221) - Clarify the limitation of ? in main and tests (rust-lang/edition-guide#219) - Update deprecated GitHub Actions commands. (rust-lang/edition-guide#220)
2020-10-28Use new-style mdBook internal links in glossaryCamelid-30/+30
2020-10-28Put `TyCtxt` at the right positionCamelid-2/+2
It should now be at its alphabetical position. Also fixed link to `TyCtxt` anchor.