about summary refs log tree commit diff
path: root/src/doc
AgeCommit message (Collapse)AuthorLines
2018-06-03s/panic_fmt/panic_impl/g in docsJorge Aparicio-17/+18
2018-05-27Auto merge of #51066 - est31:master, r=sfacklerbors-2/+2
Point to the current box syntax tracking issue The issue was used for both box syntax as well as placement new. It got closed due to placement new being unapproved. So a new one got created for box syntax, yet neither the unstable book nor feature_gate.rs got updated. We are doing this now. r? @aidanhs
2018-05-26Point to the current box syntax tracking issueest31-2/+2
The issue was used for both box syntax as well as placement new. It got closed due to placement new being unapproved. So a new one got created for box syntax, yet neither the unstable book nor feature_gate.rs got updated. We are doing this now.
2018-05-26Add `Ident::as_str` helperVadim Petrochenkov-1/+1
2018-05-26Auto merge of #50070 - toidiu:ak-2093-outlives, r=nikomatsakisbors-0/+67
2093 infer outlives requirements Tracking issue: #44493 RFC: https://github.com/rust-lang/rfcs/pull/2093 - [x] add `rustc_attrs` flag - [x] use `RequirePredicates` type - [x] handle explicit predicates on `dyn` Trait - [x] handle explicit predicates on projections - [x] more tests - [x] remove `unused`, `dead_code` and etc.. - [x] documentation
2018-05-25Implement outlives requirements inference for dyn and projections.toidiu-0/+67
Add tests, documentation and attr for feature.
2018-05-25Fix naming conventions for new lintsVadim Petrochenkov-1/+1
2018-05-22build the 2018 editionsteveklabnik-0/+0
2018-05-20Rollup merge of #50858 - robinkrahl:rustdoc-fix-order, r=steveklabnikkennytm-8/+8
Reorder description for snippets in rustdoc documentation The example code snippets for the `no_run` and `compile_fail` attributes in the rustdoc documentation were followed by the description for the wrong attribute. This patch reorders the descriptions to match the code snippets.
2018-05-19Auto merge of #50760 - petrochenkov:legimp, r=nikomatsakisbors-37/+0
Turn deprecation lint `legacy_imports` into a hard error Closes https://github.com/rust-lang/rust/issues/38260 The lint was introduced in Dec 2016, then made deny-by-default in Jun 2017 when crater run found 0 regressions caused by it. This lint requires some not entirely trivial amount of import resolution logic that (surprisingly or not) interacts with `feature(use_extern_macros)` (https://github.com/rust-lang/rust/issues/35896), so it would be desirable to remove it before stabilizing `use_extern_macros`. In particular, this PR fixes the failing example in https://github.com/rust-lang/rust/issues/50725 (but not the whole issue, `use std::panic::{self}` still can cause other undesirable errors when `use_extern_macros` is enabled).
2018-05-18Reorder description for snippets in rustdoc documentationRobin Krahl-8/+8
The example code snippets for the `no_run` and `compile_fail` attributes in the rustdoc documentation were followed by the description for the wrong attribute. This patch reorders the descriptions to match the code snippets.
2018-05-17Rollup merge of #50839 - glassresistor:master, r=steveklabnikMark Simulacrum-1/+1
Make sure people know the book is free oline I've used the tutorial a number of times to relearn rust basics. When i saw this for a moment I was sad thinking it had been taken offline.
2018-05-17Rollup merge of #50791 - bstrie:null, r=QuietMisdreavusMark Simulacrum-3/+3
Fix null exclusions in grammar docs The grammar documentation incorrectly says that comments, character literals, and string literals may not include null.
2018-05-17Rollup merge of #50790 - bstrie:grammar, r=steveklabnikMark Simulacrum-11/+6
Fix grammar documentation wrt Unicode identifiers The grammar defines identifiers in terms of XID_start and XID_continue, but this is referring to the unstable non_ascii_idents feature. The documentation implies that non_ascii_idents is forthcoming, but this is left over from pre-1.0 documentation; in reality, non_ascii_idents has been without even an RFC for several years now, and will not be stabilized anytime soon. Furthermore, according to the tracking issue at https://github.com/rust-lang/rust/issues/28979 , it's highly questionable whether or not this feature will use XID_start or XID_continue even when or if non_ascii_idents is stabilized. This commit fixes this by respecifying identifiers as the usual [a-zA-Z_][a-zA-Z0-9_]*
2018-05-17Update tutorial.mdMikela-1/+1
2018-05-17Make sure people know the book is free olineMikela-1/+1
2018-05-17Rename trans to codegen everywhere.Irina Popa-1/+1
2018-05-16Null exclusions in grammar docsbstrie-3/+3
The grammar documentation incorrectly says that comments, character literals, and string literals may not include null.
2018-05-16Fix grammar documentation wrt Unicode identifiersbstrie-11/+6
The grammar defines identifiers in terms of XID_start and XID_continue, but this is referring to the unstable non_ascii_idents feature. The documentation implies that non_ascii_idents is forthcoming, but this is left over from pre-1.0 documentation; in reality, non_ascii_idents has been without even an RFC for several years now, and will not be stabilized anytime soon. Furthermore, according to the tracking issue at https://github.com/rust-lang/rust/issues/28979 , it's highly questionable whether or not this feature will use XID_start or XID_continue even when or if non_ascii_idents is stabilized. This commit fixes this by respecifying identifiers as the usual [a-zA-Z_][a-zA-Z0-9_]*
2018-05-15Rollup merge of #50594 - sanxiyn:man-print, r=steveklabnikGuillaume Gomez-1/+1
Update the man page with additional --print options `\:` is a `groff` for `<wbr>` to get better line breaking.
2018-05-15Turn deprecation lint `legacy_imports` into a hard errorVadim Petrochenkov-37/+0
2018-05-13stabilize :lifetimeAlex Burka-14/+0
2018-05-13Macros: Add a 'literal' fragment specifierDan Aloni-0/+17
Implements RFC 1576. See: https://github.com/rust-lang/rfcs/blob/master/text/1576-macros-literal-matcher.md Changes are mostly in libsyntax, docs, and tests. Feature gate is enabled for 1.27.0. Many thanks to Vadim Petrochenkov for following through code reviews and suggestions. Example: ````rust macro_rules! test_literal { ($l:literal) => { println!("literal: {}", $l); }; ($e:expr) => { println!("expr: {}", $e); }; } fn main() { let a = 1; test_literal!(a); test_literal!(2); test_literal!(-3); } ``` Output: ``` expr: 1 literal: 2 literal: -3 ```
2018-05-10Update the man page with additional --print optionsSeo Sanghyeon-1/+1
2018-05-08Auto merge of #50390 - hdhoang:46205_deny_by_default, r=nikomatsakisbors-41/+41
lint: deny incoherent_fundamental_impls by default Warn the ecosystem of the pending intent-to-disallow in #49799. There are 4 ICEs on my machine, look unrelated (having happened before in https://github.com/rust-lang/rust/issues/49146#issuecomment-384473523) ```rust thread 'main' panicked at 'assertion failed: position <= slice.len()', libserialize/leb128.rs:97:1 ``` ``` [run-pass] run-pass/allocator/xcrate-use2.rs [run-pass] run-pass/issue-12133-3.rs [run-pass] run-pass/issue-32518.rs [run-pass] run-pass/trait-default-method-xc-2.rs ``` r? @nikomatsakis
2018-05-05Update books for the next release.Corey Farwell-0/+0
2018-05-03ignore erroneous exampleHoàng Đức Hiếu-1/+1
2018-05-03fix error textHoàng Đức Hiếu-1/+1
2018-05-03doc: move incoherent_fundamental_impls to deny-by-default listingHoàng Đức Hiếu-41/+41
2018-05-02Add tool_attributes feature to unstable bookSeiichi Uchida-0/+26
2018-04-30Auto merge of #48925 - zackmdavis:fn_must_stabilize, r=nikomatsakisbors-30/+0
stabilize `#[must_use]` for functions and must-use comparison operators (RFC 1940) r? @nikomatsakis
2018-04-30Auto merge of #50163 - kornelski:error, r=Kimundibors-0/+0
Bury Error::description() Second attempt of #49536 https://github.com/rust-lang/rfcs/pull/2230 The exact wording of the default implementation is still up in the air, but I think it's a detail that can be amended later.
2018-04-28stabilize `#[must_use]` for functions and must-use operatorsZack M. Davis-30/+0
This is in the matter of RFC 1940 and tracking issue #43302.
2018-04-27Rollup merge of #49707 - steveklabnik:rustc-book, r=QuietMisdreavuskennytm-0/+2512
Add "the Rustc book" This PR introduces a new book into the documentation, "The rustc book". We already have books for Cargo, and for Rustdoc, rustc should have some too. This book is focused on *users* of rustc, and provides a nice place to write documentation for users. I haven't put content here, but plan on scaffolding it out very soon, and wanted this PR open for a few discussions first. One of those is "what exactly should said TOC be?" I plan on having a proposed one up tomorrow, but figured I'd let people know to start thinking about it now. The big one is that we also will want to put https://github.com/rust-lang-nursery/rustc-guide in-tree as well, and the naming is... tough. I'm proposing: * doc.rust-lang.org/rustc is "The Rustc book", to mirror the other tools' books. * doc.rust-lang.org/rustc-contribution is "The Rustc contribution guide", and contains that book @nikomatsakis et al, any thoughts on this? I'm not attached to it in particular, but had to put something together to get this discussion going. I think mirroring the other tools is a good idea for this work, but am not sure where exactly that leaves yours. Fixes https://github.com/rust-docs/team/issues/11
2018-04-25Update book submodule to pass linkchecker testKornel-0/+0
2018-04-24more nitssteveklabnik-3/+3
2018-04-23review nitssteveklabnik-9/+8
2018-04-22Add doc about doc alias featureGuillaume Gomez-0/+39
2018-04-17stabilize `slice_rsplit` featuretinaun-10/+0
2018-04-17Rollup merge of #49994 - frewsxcv:frewsxcv-doc-tests, r=QuietMisdreavuskennytm-19/+19
Remove unnecessary indentation in rustdoc book codeblock. None
2018-04-16write docs for targetssteveklabnik-0/+38
2018-04-16fill out contributingsteveklabnik-0/+5
2018-04-16fill out command line argumentssteveklabnik-2/+61
2018-04-16Remove unnecessary indentation in rustdoc book codeblock.Corey Farwell-19/+19
2018-04-16Auto merge of #49956 - QuietMisdreavus:rustdoc-codegen, r=GuillaumeGomezbors-0/+25
rustdoc: port the -C option from rustc Blocked on https://github.com/rust-lang/rust/pull/49864. The included test won't work without those changes, so this PR includes those commits as well. When documenting items that require certain target features, it helps to be able to force those target features into existence. Rather than include a flag just to parse those features, i instead decided to port the `-C` flag from rustc in its entirety. It takes the same parameters, because it runs through the same parsing function. This has the added benefit of being able to control the codegen of doctests as well. One concern i have with the flag is that i set it to stable here. My rationale is that it is a direct port of functionality on rustc that is currently stable, used only in mechanisms that it is originally used for. If needed, i can set it back to be unstable.
2018-04-14Replace remaining uses of deprecated std::heap with std::allocMike Hommey-1/+1
2018-04-13add -C to the rustdoc bookQuietMisdreavus-0/+25
2018-04-12Rename alloc::Void to alloc::OpaqueSimon Sapin-3/+3
2018-04-12Use NonNull<Void> instead of *mut u8 in the Alloc traitMike Hommey-0/+1
Fixes #49608
2018-04-12Use the GlobalAlloc trait for #[global_allocator]Simon Sapin-4/+4