Commit Graph

67068 Commits

Author SHA1 Message Date
Oliver Schneider
9346fe9d6e Upgrade a comment to a doc comment 2017-08-17 16:21:55 +02:00
Oliver Schneider
7f5f92218a Upgrade a comment to a doc comment 2017-08-17 16:15:40 +02:00
Seiichi Uchida
567b9b761b Update ui tests 2017-08-17 21:59:19 +09:00
Seiichi Uchida
ceb2c240a6 Include the closing paren to the span of ast::NestedMetaItem 2017-08-17 21:58:01 +09:00
Seiichi Uchida
ea222160d0 Use respan() 2017-08-17 21:24:19 +09:00
bors
dd39ecf368 Auto merge of #43902 - michaelwoerister:fix-mir-passes-promoted, r=arielb1
Run MIR passes on promoted temporaries again.

This seems to have been broken some time in the past (maybe here: 9c154a67bf (diff-2f8e8805126c84b2be3f0967ffa0af28L162)).

r? @arielb1
2017-08-17 10:58:12 +00:00
pravic
cb4a2d5078 Fix ES5 regression with shorthand names.
Reverts 1b6c9605e4.
2017-08-17 12:41:57 +03:00
gaurikholkar
fe9c68a051 Adding E0623 for structs 2017-08-17 15:06:32 +05:30
Anthony Clays
fa346fc5d6
Fixed typo in RefCell::get_mut 2017-08-17 10:57:17 +02:00
Michael Zapata
3ffe01f40a
refactor(mir): remove unused argument
Small cleanup that shouldn't have any impact
2017-08-17 19:01:59 +12:00
bors
a7e001833e Auto merge of #43878 - kennytm:fix-43869-put-impl-trait-out-of-the-loop, r=alexcrichton
Exclude `impl Trait` functions from everybody_loops.

Fixes #43869.

cc #34511.
2017-08-17 06:19:38 +00:00
Corey Farwell
1065ad418e Minor rewrite of char primitive unicode intro.
Opened primarily to address #36998.
2017-08-17 00:36:30 -04:00
bors
e407206534 Auto merge of #43867 - GuillaumeGomez:useless-help, r=nikomatsakis
Remove useless help part

Part of #32658.

I think this error should be splitted into two parts, each more specific (`anonymous function` vs `type method`).
2017-08-17 03:42:26 +00:00
Ian Douglas Scott
872f532641
Enable unwinding panics on Redox 2017-08-16 17:21:50 -07:00
Hunter Praska
ff047a8a25
Use direct references to CompilerDesugaringKind 2017-08-16 18:46:48 -05:00
bors
be0f77dc8a Auto merge of #43864 - GuillaumeGomez:static-method-invalid-use, r=eddyb
Add help for static method invalid use

Fixes #30391.
2017-08-16 23:40:01 +00:00
Anthony Defranceschi
d6cdefc4e0 added whitespace 2017-08-17 01:39:23 +02:00
Carol (Nichols || Goulding)
5be97beeea Implement a temp redirect for cargo docs
As discussed in
https://github.com/rust-lang/cargo/issues/4040#issuecomment-321639074

This is a redirect meant to be replaced once cargo docs have been
converted to mdbook. We just want *a* URL to ride the trains for now so
that we can print doc.rust-lang.org/cargo in the paper book and
guarantee that it will go *somewhere* useful by the time the book is
printed.

Implemented as a meta redirect in HTML because we don't currently have
any google juice at doc.rust-lang.org/cargo to lose.
2017-08-16 19:08:33 -04:00
adrian5
c9f9992419 Fix typo in doc 2017-08-17 00:46:30 +02:00
bors
7ac979d8cb Auto merge of #43838 - eddyb:stable-rvalue-promotion, r=arielb1
Stabilize rvalue promotion to 'static.

Closes #38865.

Documentation PR at rust-lang-nursery/reference#98.
2017-08-16 21:00:21 +00:00
Anthony Defranceschi
fe06b70b2a E0106: field lifetimes
I've added an example for custom type lifetimes located in another `struct` fields.
2017-08-16 22:49:18 +02:00
steveklabnik
010f59750f Update the books for next release 2017-08-16 16:08:08 -04:00
arthurprs
519cf15ea6 Update jemalloc to 4.5.0 2017-08-16 22:06:05 +02:00
Alex Crichton
63477fdece Fix merge conflicts 2017-08-16 13:05:48 -07:00
Alex Crichton
5f4a99fa8b Merge remote-tracking branch 'origin/master' into gen 2017-08-16 11:33:10 -07:00
bors
3f94b7103b Auto merge of #43884 - kennytm:fix-43881-do-not-test-i586-msvc, r=alexcrichton
Stop testing `i586-pc-windows-msvc` on AppVeyor.

Fixes #43881. Reduces AppVeyor test time back to ~2 hours on average.

The i586 libstd was never tested before Aug 13th, so this PR brings the situation back to the previous status-quo.
2017-08-16 18:24:59 +00:00
Eduard-Mihai Burtescu
014333fbd4 Stabilize rvalue promotion to 'static. 2017-08-16 20:30:56 +03:00
Alex Crichton
0697e4b17a Fix merge conflict 2017-08-16 10:27:20 -07:00
Alex Crichton
1210ebff43 Merge remote-tracking branch 'origin/master' into gen 2017-08-16 10:03:47 -07:00
Andy Russell
88bac1f745
remove procsrv module 2017-08-16 11:45:08 -04:00
Andy Russell
6f21239fa5
remove extra_args argument 2017-08-16 11:45:07 -04:00
Andy Russell
04dee08501
return Command from make_compile_args 2017-08-16 11:45:07 -04:00
Andy Russell
90a87be9cb
make compose_and_run_compiler take Command 2017-08-16 11:45:06 -04:00
Andy Russell
0a666f87ca
remove working_dir argument 2017-08-16 11:45:06 -04:00
Andy Russell
e385bc5bcc
let compose_and_run take a Command 2017-08-16 11:45:05 -04:00
Andy Russell
6601ffca07
replace procsrv functions with Command 2017-08-16 11:45:05 -04:00
bors
00a6797f05 Auto merge of #43108 - pnkfelix:mir-borrowck3c, r=arielb1
MIR borrow check (under debug flag)

Here is the current state of MIR borrow check.

It consists of (1.) some refactoring, (2.) a dataflow analysis to identify the borrows themselves, and (3.) a mir "transform" that does the borrow check itself based on the aforementioned dataflow results.

(There's also a drive-by fix to dataflow that I can factor into a separate PR if necessary. Interestingly I could not find a way to observe the bug outside of MIR borrowck.)

To be clear, this branch is not ready to be used as the default borrow check. Thus the code is guarded: To get mir-borrowck to run, you need to either supply an attribute `#[rustc_mir_borrowck]` or a debug flag `-Z borrowck-mir`.

Here are the main issues with the current MIR borrowck as it stands in this PR:

 * No Notes emitted yet, just errors. (So the feedback is definitely inferior compared to AST borrowck today)
 * Lvalue rendering differs between Ast and Mir. (Mostly minor, but replacement of field names with indices is very bad; big priority for me to fix ASAP.)
 * Lots of ICEs (presumably because some MIR operations used here have well-formedness assumptions that are violated in borrowck-broken code)
 * Conflates lots of cases that are distinguished by AST-borrowck
 * Conflates "uninitialized" with "moved" (special case of previous bullet, one that I think should be fixed ASAP)

 (I am hoping to fix as many of the above issues as I can in the near term, but I also would like to land this even if they are *not* all fixed, because the rebasing effort is getting to be a real drag.)
2017-08-16 15:36:00 +00:00
Martin Hoffmann
02aaa1180e Document that std:#️⃣:Hasher::finish() does not reset the hasher. 2017-08-16 17:02:39 +02:00
Seiichi Uchida
0bfe4178af Eat open paren when parsing list 2017-08-16 23:40:06 +09:00
Felix S. Klock II
8738a087ff Moved mir-borrowck pass down to where comments say it should be.
Added two fixmes: The `SimplifyBranches` pass cannot stay where it is,
and `BorrowckMir` should be a query, not a pass. But I am going to
leave those changes to a future PR.
2017-08-16 16:08:39 +02:00
Felix S. Klock II
6d6280e00c Address review comment: StatementKind::StorageDead has an effect (running dtors) relevant to borrowck. 2017-08-16 16:08:39 +02:00
Felix S. Klock II
b6528f073f Cleanup: Every BitDenotation is a DataflowOperator, so build that in.
Post-rebase: ariel confirmed `SetDiscriminant` should indeed be a mutate.
2017-08-16 16:08:39 +02:00
Felix S. Klock II
15c411d7c1 Added some documentation for the struct BlockSets in rustc_mir::dataflow. 2017-08-16 16:08:39 +02:00
Felix S. Klock II
018784afc9 MIR based borrow check (opt-in).
One can either use `-Z borrowck-mir` or add the `#[rustc_mir_borrowck]` attribute
to opt into MIR based borrow checking.

Note that regardless of whether one opts in or not, AST-based borrow
check will still run as well.  The errors emitted from AST-based
borrow check will include a "(Ast)" suffix in their error message,
while the errors emitted from MIR-based borrow check will include a
"(Mir)" suffix.

post-rebase: removed check for intra-statement mutual conflict;
replaced with assertion checking that at most one borrow is generated
per statement.

post-rebase: removed dead code: `IdxSet::pairs` and supporting stuff.
2017-08-16 16:08:28 +02:00
Felix S. Klock II
869f05a521 Factored MoveData construction code into builder submodule. 2017-08-16 15:53:27 +02:00
Felix S. Klock II
9b8b8c6aeb Move DataFlowState::{each_bit,interpret_set} method definitions to parent module.
Refactored `each_bit`, which traverses a `IdxSet`, so that the bulk of
its implementation lives in `rustc_data_structures`.
2017-08-16 15:53:27 +02:00
Felix S. Klock II
3ef1afcf6b remove now unnecessary constraint on BitDenotation for fn do_dataflow. 2017-08-16 15:53:27 +02:00
Felix S. Klock II
e8ebc902e8 Migrated some code out of dataflow::drop_flag_effects and into its parent module.
(This code is more general purpose than just supporting drop flag elaboration.)
2017-08-16 15:53:27 +02:00
Felix S. Klock II
9f6ef669d6 Added dataflow analysis for Borrows.
post-rebase: addressed review comment: rename `loc_map`/`location_map` and `rgn_map`/`region_map`.

post-rebase: remove now unnecessary `mut` decl.

post-rebase: address comments: bind iterator expr, and alpha-rename `loc`/`location` and `idx`/`index`.
2017-08-16 15:53:27 +02:00
Felix S. Klock II
cff060b960 Refactor trait BitDenotation to take Location instead of BasicBlock/usize argument pairs. 2017-08-16 15:53:27 +02:00