Commit Graph

51637 Commits

Author SHA1 Message Date
Steve Klabnik
b2dfb7c0a2 Rollup merge of #32464 - GuillaumeGomez:patch-6, r=steveklabnik
Improve some Option code example

Part of #29366.

r? @steveklabnik
2016-03-24 10:37:24 -04:00
Steve Klabnik
bce02a207a Rollup merge of #32462 - tclfs:patch-1, r=steveklabnik
Docs: some tiny corrections

TNT->`tnt`
firecracker->`firecracker`
2016-03-24 10:37:24 -04:00
Steve Klabnik
38c6593592 Rollup merge of #32459 - nrc:json-err-text, r=nikomatsakis
Include source text in JSON errors
2016-03-24 10:37:24 -04:00
Steve Klabnik
a3b9b42d44 Rollup merge of #32452 - GuillaumeGomez:patch-5, r=steveklabnik
Add code examples for libstd/time

Fixes #29379.

r? @steveklabnik
2016-03-24 10:37:24 -04:00
Steve Klabnik
7a38ac8e87 Rollup merge of #32416 - GuillaumeGomez:patch-3, r=steveklabnik
Add doc example to clone trait

Fixes #29346.

r? @steveklabnik
2016-03-24 10:37:23 -04:00
Steve Klabnik
87aee45988 Rollup merge of #32276 - brson:doc, r=alexcrichton
doc: Stdin is not writable
2016-03-24 10:37:23 -04:00
Guillaume Gomez
b922d1a405 Improve some Option code example 2016-03-24 13:24:39 +01:00
Tang Chenglong
ceaf5dfdc1 Docs: some tiny corrections
TNT->`tnt`
firecracker->`firecracker`
2016-03-24 14:49:40 +08:00
Nick Cameron
9757516f12 Include source text in JSON errors 2016-03-24 15:32:42 +13:00
Brian Anderson
b013ad55aa doc: Stdin is locked for reads, not writes 2016-03-23 23:39:01 +00:00
bors
43843d06ea Auto merge of #32455 - TimNN:patch-1, r=alexcrichton
add naked function tracking issue # to feature gate definition
2016-03-23 16:24:39 -07:00
bors
98f0a9128f Auto merge of #32454 - eddyb:rollup, r=eddyb
Rollup of 11 pull requests

- Successful merges: #32404, #32420, #32423, #32425, #32429, #32430, #32431, #32434, #32437, #32441, #32443
- Failed merges:
2016-03-23 12:33:04 -07:00
Tim Neumann
7027521daa add naked function tracking issue # to feature gate definition 2016-03-23 17:14:19 +01:00
Eduard-Mihai Burtescu
2e9b40f576 Rollup merge of #32443 - tclfs:patch-8, r=steveklabnik
Docs: Change "statements" to "expressions" on `match`

I apt to use `expressions` over `statements`, because `match` is a expression in essence, though it can become a statement when followed a semicolon.
2016-03-23 17:59:16 +02:00
Eduard-Mihai Burtescu
7f2612e66c Rollup merge of #32441 - tshepang:doc-primitive, r=steveklabnik
doc: small char improvements
2016-03-23 17:59:16 +02:00
Eduard-Mihai Burtescu
3fd144db0d Rollup merge of #32437 - eddyb:orbital-msvc, r=alexcrichton
Annotate run-pass/backtrace with #[rustc_no_mir] on MSVC.

Fixes #32384 by not using MIR on MSVC for the functions in the path of the backtrace.
This is the known blocker for the MSVC MIR builder, hopefully the only one overall.
r? @alexcrichton Confirmed to work on a nightly, by @retep998.
2016-03-23 17:59:16 +02:00
Eduard-Mihai Burtescu
2acad9c17e Rollup merge of #32434 - mitaa:rdoc-no-inline, r=alexcrichton
rustdoc: Consider `doc(no_inline)` in crate-local inlining

Imports with `doc(no_inline)` will not be inlined, even when `doc(inline)` is present.

fixes #32343

r? @alexcrichton
2016-03-23 17:59:16 +02:00
Eduard-Mihai Burtescu
d7bf3d3284 Rollup merge of #32431 - nicholasf:tweak/improve-expression, r=steveklabnik
Simplifying some of the phrasing explaining lifetime elision

Just simplifying some of the language expressing what kind of inference Rust can and can't do on function signatures.
2016-03-23 17:59:15 +02:00
Eduard-Mihai Burtescu
12e54bba21 Rollup merge of #32430 - sanxiyn:const-trans, r=arielb1
Fix const trans

Fix #30615.

The idea was that when there are N autoderefs, first do N-1 derefs and check for autoref. If there is autoref, done, if not, do one more deref. But when N is zero, doing one more deref is wrong.
2016-03-23 17:59:15 +02:00
Eduard-Mihai Burtescu
c028b1c02c Rollup merge of #32429 - alexcrichton:scope-id-hton, r=aturon
std: Store flowinfo/scope_id in host byte order

Apparently these aren't supposed to be stored in network byte order, so doing so
ends up causing failures when it would otherwise succeed when stored in the host
byte order.

Closes #32424
2016-03-23 17:59:15 +02:00
Eduard-Mihai Burtescu
0c424f9825 Rollup merge of #32425 - ituxbag:master, r=alexcrichton
Added version 7.3* for Apple's clang compiler

The recent 7.3 clang version was missing.

Closes #32442
2016-03-23 17:59:15 +02:00
Eduard-Mihai Burtescu
46b2a99db3 Rollup merge of #32423 - mitaa:rdoc-vstruct-fields, r=alexcrichton
rustdoc: Omit `pub` for inlined variant-struct fields

fixes #32395

r? @alexcrichton
2016-03-23 17:59:15 +02:00
Eduard-Mihai Burtescu
6b4b65afad Rollup merge of #32420 - frewsxcv:regression-test-26997, r=alexcrichton
Add regression test for Issue 26997.

https://github.com/rust-lang/rust/issues/26997
2016-03-23 17:59:14 +02:00
Eduard-Mihai Burtescu
2de428e1a2 Rollup merge of #32404 - WiSaGaN:feature/osstring-implement-default, r=aturon
Implement Default trait for OsString/OsStr

Fixes #32385
2016-03-23 17:59:14 +02:00
bors
b76f818cad Auto merge of #32390 - japaric:untry, r=pnkfelix
convert 99.9% of `try!`s to `?`s

The first commit is an automated conversion using the [untry] tool and the following command:

```
$ find -name '*.rs' -type f | xargs untry
```

at the root of the Rust repo.

[untry]: https://github.com/japaric/untry

cc @rust-lang/lang @alexcrichton @brson
2016-03-23 08:59:10 -07:00
Guillaume Gomez
ca609cc674 Add code examples for libstd/time 2016-03-23 15:39:27 +01:00
Jorge Aparicio
c063c5153f add back & that was deleted by mistake 2016-03-23 06:17:29 -05:00
bors
26cfc269a0 Auto merge of #32410 - Ticki:master, r=eddyb
Add support for naked functions

See https://github.com/rust-lang/rfcs/pull/1201#issuecomment-199442239

This PR adds `#[naked]` for marking naked functions.
2016-03-23 03:49:02 -07:00
bors
d6af19b89c Auto merge of #32348 - brson:cargotest, r=alexcrichton
Introduce 'cargotest' and the check-cargotest buildstep

This is a new suite of tests that verifies that the compiler builds specific revisions of select crates from crates.io.

It does not run by default. It is intended that bors runs these tests against all PRs, and gates on them. In this way we will make it harder still to break important swaths of the ecosystem, even on nightly.

This is a very basic implementation intended for feedback. The biggest thing it probably should do but doesn't is use a lockfile for every project it builds.

r? @alexcrichton cc @rust-lang/lang @rust-lang/libs
2016-03-23 01:03:04 -07:00
bors
8ba2ea5fad Auto merge of #32058 - pczarn:hashmap-initial-refactoring, r=apasel422
Basic refactoring of HashMap
2016-03-22 21:21:45 -07:00
Tang Chenglong
ea9ae48662 Docs: Change "statements" to "expressions" on match
I apt to use `expressions` over `statements`, because `match` is a expression in essence, though it can become a statement when followed a semicolon.
2016-03-23 12:03:41 +08:00
Jorge Aparicio
c548eda362 enable question_mark feature in rustc_borrowck 2016-03-22 22:04:10 -05:00
Jorge Aparicio
2628f3cc8f fix alignment 2016-03-22 22:03:54 -05:00
Jorge Aparicio
bd71d11a8f break long line 2016-03-22 22:03:31 -05:00
Jorge Aparicio
acbf386ab4 term: undo conversion of user defined try!s 2016-03-22 22:03:19 -05:00
Jorge Aparicio
f88a1e6f21 std: undo conversion of user defined try!s 2016-03-22 22:03:08 -05:00
Jorge Aparicio
aa7fe93d4a sprinkle feature gates here and there 2016-03-22 22:02:47 -05:00
Jorge Aparicio
0f02309e4b try! -> ?
Automated conversion using the untry tool [1] and the following command:

```
$ find -name '*.rs' -type f | xargs untry
```

at the root of the Rust repo.

[1]: https://github.com/japaric/untry
2016-03-22 22:01:37 -05:00
Eduard Burtescu
424fa432d4 Annotate run-pass/backtrace with #[rustc_no_mir] on MSVC. 2016-03-23 02:59:02 +02:00
bors
0dcc413e42 Auto merge of #32204 - alexcrichton:redesign-char-encoding-types, r=aturon
std: Change `encode_utf{8,16}` to return iterators

Currently these have non-traditional APIs which take a buffer and report how
much was filled in, but they're not necessarily ergonomic to use. Returning an
iterator which *also* exposes an underlying slice shouldn't result in any
performance loss as it's just a lazy version of the same implementation, and
it's also much more ergonomic!

cc #27784
2016-03-22 16:05:39 -07:00
Brian Anderson
3a790acf19 Introduce 'cargotest' and the check-cargotest buildstep
This is a new suite of tests that verifies that the compiler
builds specific revisions of select crates from crates.io.

It does not run by default. It is intended that buildbot
runs these tests against all PRs, and gate on them.
2016-03-22 21:46:21 +00:00
mitaa
4c71347e94 Consider doc(no_inline) in crate-local inlining 2016-03-22 21:11:00 +01:00
nicholasf
45c72d5f5b Simplifying some of the phrasing explaining lifetime elision 2016-03-23 05:00:27 +11:00
Alex Crichton
48d5fe9ec5 std: Change encode_utf{8,16} to return iterators
Currently these have non-traditional APIs which take a buffer and report how
much was filled in, but they're not necessarily ergonomic to use. Returning an
iterator which *also* exposes an underlying slice shouldn't result in any
performance loss as it's just a lazy version of the same implementation, and
it's also much more ergonomic!

cc #27784
2016-03-22 10:25:30 -07:00
Guillaume Gomez
b3aa35e756 Add doc example to clone trait 2016-03-22 18:18:01 +01:00
Seo Sanghyeon
308dc55f78 Fix const trans
Const was dereferenced when autoderefs is zero.
2016-03-23 02:10:09 +09:00
bors
e3f2dfdece Auto merge of #32156 - pnkfelix:borrowck-on-mir-move-analysis, r=nikomatsakis
Move analysis for MIR borrowck

This PR adds code for doing MIR-based gathering of the moves in a `fn` and the dataflow to determine where uninitialized locations flow to, analogous to how the same thing is done in `borrowck`.

It also adds a couple attributes to print out graphviz visualizations of the analyzed MIR that includes the dataflow analysis results.

cc @nikomatsakis
2016-03-22 10:00:12 -07:00
Felix S. Klock II
782c0cf4a2 Add rustbuild dependency from rustc_borrowck upon rustc_mir crate. 2016-03-22 18:09:57 +01:00
Alex Crichton
88506ce5cd std: Store flowinfo/scope_id in host byte order
Apparently these aren't supposed to be stored in network byte order, so doing so
ends up causing failures when it would otherwise succeed when stored in the host
byte order.

Closes #32424
2016-03-22 09:33:36 -07:00
bors
c7bdfd4442 Auto merge of #32341 - frewsxcv:compiletest-enum, r=nikomatsakis
Use enum for message kind in compiletest harness.

None
2016-03-22 08:02:13 -07:00