about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorLines
2015-04-26IMO better borrow_mut() documentation on RefCellgareins-1/+1
Previous borrow() is enough to make borrow_mut() panic, no need to have borrow_mut() twice. [This](http://is.gd/woKKAW)
2015-04-26Auto merge of #24829 - jooert:fix22673, r=pnkfelixbors-0/+16
2015-04-26Auto merge of #24828 - jooert:fix23253, r=pnkfelixbors-0/+16
r? @alexcrichton
2015-04-26Auto merge of #24807 - luqmana:nullable-enum-opt-dst-raw-pointers, r=jakub-bors-0/+28
Fixes #23433.
2015-04-26Auto merge of #23085 - goffrie:interpolating-quote, r=huonwbors-725/+257
This changes the `ToTokens` implementations for expressions, statements, etc. with almost-trivial ones that produce `Interpolated(*Nt(...))` pseudo-tokens. In this way, quasiquote now works the same way as macros do: already-parsed AST fragments are used as-is, not reparsed. The `ToSource` trait is removed. Quasiquote no longer involves pretty-printing at all, which removes the need for the `encode_with_hygiene` hack. All associated machinery is removed. New `Nonterminal`s are added: NtArm, NtImplItem, and NtTraitItem. These are just for quasiquote, not macros. `ToTokens` is no longer implemented for `Arg` (although this could be added again) and `Generics` (which I don't think makes sense). This breaks any compiler extensions that relied on the ability of `ToTokens` to turn AST fragments back into inspectable token trees. For this reason, this closes #16987. As such, this is a [breaking-change]. Fixes #16472. Fixes #15962. Fixes #17397. Fixes #16617.
2015-04-26Auto merge of #24367 - ebfull:fix_ice_cat_expr, r=pnkfelixbors-11/+87
An actual typeck error is the cause of many failed compilations but an unrelated bug is being reported instead. It is triggered because a typeck error is presumably not yet identified during compiler execution, which would normally bypass an invariant in the presence of other errors. In this particular situation, we delay the reporting of the bug until abort_if_errors(). Closes #23827, closes #24356, closes #23041, closes #22897, closes #23966, closes #24013, and closes #23729 **There is at least one situation where this bug may still be genuinely triggered (#23437).**
2015-04-26Remove FakeExtCtxt from qquote tests.Geoffry Song-56/+30
Instead create an ExtCtxt structure.
2015-04-26Auto merge of #24825 - rkruppe:reference-audit, r=steveklabnikbors-30/+21
Transplant the relevant changes (turns out to be all of them) to `grammar.md`, and remove all grammar talk from `reference.md`. Sorry for the chaos. The second commit, further below, goes over the comments and whitespace sections. r? @steveklabnik
2015-04-25Remove remaining tests for hygiene-encoded identifiers.Geoffry Song-126/+0
Such things no longer exist.
2015-04-25Interpolate AST nodes in quasiquote.Geoffry Song-543/+227
This changes the `ToTokens` implementations for expressions, statements, etc. with almost-trivial ones that produce `Interpolated(*Nt(...))` pseudo-tokens. In this way, quasiquote now works the same way as macros do: already-parsed AST fragments are used as-is, not reparsed. The `ToSource` trait is removed. Quasiquote no longer involves pretty-printing at all, which removes the need for the `encode_with_hygiene` hack. All associated machinery is removed. A new `Nonterminal` is added, NtArm, which the parser now interpolates. This is just for quasiquote, not macros (although it could be in the future). `ToTokens` is no longer implemented for `Arg` (although this could be added again) and `Generics` (which I don't think makes sense). This breaks any compiler extensions that relied on the ability of `ToTokens` to turn AST fragments back into inspectable token trees. For this reason, this closes #16987. As such, this is a [breaking-change]. Fixes #16472. Fixes #15962. Fixes #17397. Fixes #16617.
2015-04-26Auto merge of #24815 - heejongahn:master, r=steveklabnikbors-0/+1
At https://doc.rust-lang.org/book/vectors.html, there should be a link to Generics page but the link address is ommitted and thus link is not functioning well. So I added a link definition to the vectors.md. r? @steveklabnik
2015-04-26Reference audit: comments and whitespace sectionsRobin Kruppe-9/+12
2015-04-25Auto merge of #24718 - tamird:fix-quote-tests, r=alexcrichtonbors-206/+158
Sniped from @rprichard's work in #24537. r? @alexcrichton
2015-04-26Add regression test for #22673.Johannes Oertel-0/+16
2015-04-26Add regression test for #23253.Johannes Oertel-0/+16
2015-04-25Auto merge of #24547 - bombless:comma, r=pnkfelixbors-2/+507
Closes #20616 It breaks code such as <https://github.com/rust-lang/rust/blob/c64feb63418fd05bd6e5adc6f9ad763aa6a594b1/src/librustc_typeck/check/method/suggest.rs#L367>, so this is a [breaking-change], you have to add missing comma after the last lifetime arguement now.
2015-04-25`qquote-2.rs` -> `run-fail/qquote.rs`Tamir Duberstein-63/+57
Re-enables the test.
2015-04-25`qquote-1.rs` -> `compile-fail-fulldeps/qquote.rs`Tamir Duberstein-70/+55
Re-enables the test.
2015-04-25Re-enable testTamir Duberstein-13/+14
2015-04-25Unrot and re-enable `run-pass-fulldeps/qquote.rs`Tamir Duberstein-60/+32
2015-04-25Redo PR #24811 properlyRobin Kruppe-21/+9
Transplant the grammar-related changes to grammar.md, and remove all grammar talk from reference.md
2015-04-26Added a link address to Vectors page of the bookHeejong Ahn-0/+1
At https://doc.rust-lang.org/book/vectors.html, there should be a link to Generics page but the link address is ommitted and thus link is not functioning well. So I added a link definition to the vectors.md. r? @steveklabnik
2015-04-25add import (fixup #24649)Manish Goregaokar-0/+2
2015-04-25Rollup merge of #24812 - jest:master, r=steveklabnikManish Goregaokar-8/+8
Conflicts: src/doc/trpl/variable-bindings.md
2015-04-25Rollup merge of #24811 - rkruppe:reference-audit, r=steveklabnikManish Goregaokar-5/+5
Mention `non_ascii_idents` feature gate and remove unused productions. r? @steveklabnik
2015-04-25Rollup merge of #24809 - conradkleinespel:master, r=ManishearthManish Goregaokar-2/+2
The reference has broken links. This should fix it.
2015-04-25Rollup merge of #24806 - FuGangqiang:doc, r=ManishearthManish Goregaokar-10/+10
2015-04-25Rollup merge of #24649 - nham:path_new_examples, r=steveklabnikManish Goregaokar-0/+8
2015-04-25A number of spell-checking corrections.Przemysław Wesołek-8/+8
2015-04-25Auto merge of #24803 - SkylerLipthay:patch-2, r=huonwbors-4/+5
The description of the syntax for single byte literals is missing the preceding `b` distinction.
2015-04-25Audit reference manual: 3.2 Special unicode productionsRobin Kruppe-5/+5
Mention non_ascii_idents feature gate and remove unused productions
2015-04-25librustc_trans: Don't ICE on unsized type behind raw pointer in nullable ↵Luqman Aden-0/+28
pointer opt.
2015-04-25fix compiler plugins path in doc/reference.mdConrad Kleinespel-2/+2
2015-04-25Auto merge of #24783 - jooert:unittestguidelines, r=alexcrichtonbors-59/+59
Changes the style guidelines regarding unit tests to recommend using a sub-module named "tests" instead of "test" for unit tests as "test" might clash with imports of libtest (see #23870, #24030 and http://users.rust-lang.org/t/guidelines-naming-of-unit-test-module/1078 for previous discussions). r? @alexcrichton
2015-04-25fix docFuGangqiang-10/+10
2015-04-24Reference manual 3.5.2.3.1Skyler-4/+5
The description of the syntax for single byte literals is missing the preceding `b` distinction.
2015-04-25Auto merge of #24724 - alexcrichton:symlink-stable, r=aturonbors-0/+3
These functions were intended to be introduced as `#[stable]` as a stable API was deprecated in favor of them, but they just erroneously forgot the stability attributes.
2015-04-25Fix #20616York Xiang-2/+507
2015-04-24More small syntax changes in reference.mdMichael Rosenberg-2/+2
2015-04-24Rollup merge of #24790 - jooert:fix24774, r=steveklabnikSteve Klabnik-1/+1
Fixes #24774. r? @steveklabnik
2015-04-24Rollup merge of #24775 - mbrubeck:reference, r=steveklabnikSteve Klabnik-4/+4
Update 7.2.20 (`for` expressions): * `for` loops now use `IntoIterator` instead of just `Iterator` * Simplify the example by removing unnecessary `Vec::iter` call. ...and a fix for a minor formatting error. r? @steveklabnik
2015-04-24Rollup merge of #24772 - steveklabnik:gh24712, r=alexcrichtonSteve Klabnik-1/+1
FIxes #24712
2015-04-24Rollup merge of #24766 - nwin:patch-1, r=steveklabnikSteve Klabnik-1/+1
Changed in #22838. audited (raw) byte string literals @ #16676
2015-04-24Rollup merge of #24751 - lstat:feature-gate-22820-dups, r=brsonSteve Klabnik-48/+0
As part of the audit for #22820 the following duplicate feature gate tests were removed: * `box_patterns` * `simd_ffi` These tests for `box_patterns` and `simd_ffi` were added in #23578, however there were existing tests in #20723 and #21233 respectively. r? @nrc
2015-04-24Rollup merge of #24749 - lstat:feature-gate-22820, r=nrcSteve Klabnik-2/+142
As part of the audit for #22820 the following feature gate tests have been added: * `negate_unsigned` * `on_unimplemented` * `optin_builtin_traits` * `plugin` * `rustc_attrs` * `rustc_diagnostic_macros` * `slice_patterns` In addition some feature gate error message typos fixed.
2015-04-24Rollup merge of #24736 - steveklabnik:doc_mutability, r=alexcrichtonSteve Klabnik-1/+177
Okay, last chapter other than ownership stuff. :confetti_ball:
2015-04-24Rollup merge of #24729 - mdinger:reference_grammar, r=steveklabnikSteve Klabnik-348/+32
From https://github.com/rust-lang/rust/issues/24723#issuecomment-95636827 : > Yes, I've been meaning to just remove it in favor of GRAMMAR.md > - steveklabnik
2015-04-24Rollup merge of #24725 - steveklabnik:doc_operators_and_overloading, ↵Steve Klabnik-2/+82
r=alexcrichton I forgot these heavily use associated types, so move it after that as well.
2015-04-24Rollup merge of #24722 - steveklabnik:doc_deref, r=alexcrichtonSteve Klabnik-5/+121
r? @alexcrichton
2015-04-24Rollup merge of #24662 - steveklabnik:gh24656, r=steveklabnikSteve Klabnik-5/+62
Fixes #24656 r? @pnkfelix I just added the examples, but if the wording needs expanded too, let me know what you think should be added :)