about summary refs log tree commit diff
path: root/src/librustc_borrowck
AgeCommit message (Collapse)AuthorLines
2016-05-10borrowck: do not suggest to change "&mut self" to "&mut mut self"Georg Brandl-5/+7
Matching the snippet string might not be the cleanest, but matching the AST node instead seems to end in a lot of nested `if let`s... Fixes #31424.
2016-05-09Rollup merge of #33383 - cramertj:E0509, r=ManishearthManish Goregaokar-1/+95
Add detailed error explanation for E0509 Part of #32777
2016-05-09Add detailed error explanation for E0504Taylor Cramer-1/+104
Removed unnecessary use of threads from E0504 Cleaned up line ending on E0504 Added more examples for E0504 Changed to erroneous code wording Switched Rc example to thread/Arc example Added comments describing why errors no longer occur
2016-05-07Rollup merge of #33412 - cramertj:E0389, r=ManishearthSteve Klabnik-1/+64
Add detailed error explanation for E0389 Part of #32777
2016-05-06Add detailed error explanation for E0389Taylor Cramer-1/+64
Cleanup of E0389 Added type-d out version of type in E0389 description
2016-05-06Add detailed error explanation for E0509Taylor Cramer-1/+95
Edited the error explanation for E0509 to clarify dropping of moved fields Edited the error explanation for E0509 to clarify move out of Drop value language Fixed typeo in last commit to E0509 Switched to erroneous code wording
2016-05-04Add detailed error explanation for E0506Taylor Cramer-1/+84
Broke up long lines in E0506 Trimmed E0506 comment to be under max line width Added function example to E0506 Changed example of erroneous code wording on E0506
2016-05-03Rollup merge of #33294 - timothy-mcroy:E0501, r=GuillaumeGomezManish Goregaokar-1/+76
Add detailed error explanation for E0501 r? @GuillaumeGomez Bring on the nits!
2016-05-02replace fileline_{help,note} with {help,note}Niko Matsakis-4/+2
The extra filename and line was mainly there to keep the indentation relative to the main snippet; now that this doesn't include filename/line-number as a prefix, it is distracted.
2016-05-02add borrowck info inline in main snippetNiko Matsakis-186/+145
This uses the new `span_label` APIs
2016-05-01Add error explanation for E0501Timothy McRoy-1/+76
2016-04-24thread tighter span for closures aroundNiko Matsakis-1/+1
Track the span corresponding to the `|...|` part of the closure.
2016-04-06rustc: move middle::{def,def_id,pat_util} to hir.Eduard Burtescu-2/+2
2016-04-06syntax: dismantle ast_util.Eduard Burtescu-2/+2
2016-04-06rustc: dismantle hir::util, mostly moving functions to methods.Eduard Burtescu-2/+1
2016-04-06rustc: move rustc_front to rustc::hir.Eduard Burtescu-19/+17
2016-03-31librustc_borrowck: use bug!(), span_bug!()Benjamin Herr-35/+28
2016-03-27rustc: move cfg, infer, traits and ty from middle to top-level.Eduard Burtescu-21/+21
2016-03-23Update borrowck to use `repr::*` instead of a mixNiko Matsakis-13/+12
We should probably settle on some conventions here. In MIR code, I have generally been importing `*`, but perhaps borrowck does not want to do that.
2016-03-23extend Terminator into a struct so it can have additional fieldsNiko Matsakis-51/+48
2016-03-22enable question_mark feature in rustc_borrowckJorge Aparicio-0/+1
2016-03-22fix alignmentJorge Aparicio-21/+21
2016-03-22try! -> ?Jorge Aparicio-22/+22
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-22Add rustbuild dependency from `rustc_borrowck` upon `rustc_mir` crate.Felix S. Klock II-0/+1
2016-03-21assigning a (MIR) box into an lvalue allocates heap storage that willFelix S. Klock II-1/+5
need to be initialized. create a MoveOut to represent that deref'ed `*lval` path.
2016-03-21remove uses of `RefCell` from move data builder.Felix S. Klock II-37/+26
2016-03-21Make `fn move_path_for` take `&mut self` instead of `&self`. This is aFelix S. Klock II-36/+37
precursor for a number of other simplifying changes (mostly removing uses of `RefCell`). Factor lookup method out of `fn move_path_for`.
2016-03-21dont create MovePathIndex's for individual statics.Felix S. Klock II-29/+63
Instead, create a single MovePathIndex that represents all statics. (An alternative here would be to disallow representing statics at all. I am hesitant to do that right now, in part because it could impose a requirement that I thread checks for static data into the calling code, either as pre- or post-invocation of `fn move_path_for`.)
2016-03-21Switch newtype Index wrappers to use NonZero instead of INVALID constants.Felix S. Klock II-78/+88
2016-03-21factor the wrapped Index newtype definitions into a macro.Felix S. Klock II-28/+22
2016-03-21Add `fn clear_bit` method on BitSlice trait for setting a bit to zero.Felix S. Klock II-82/+111
2016-03-21scaffolding for borrowck on MIR.Felix S. Klock II-10/+1723
emit (via debug!) scary message from `fn borrowck_mir` until basic prototype is in place. Gather children of move paths and set their kill bits in dataflow. (Each node has a link to the child that is first among its siblings.) Hooked in libgraphviz based rendering, including of borrowck dataflow state. doing this well required some refactoring of the code, so I cleaned it up more generally (adding comments to explain what its trying to do and how it is doing it). Update: this newer version addresses most review comments (at least the ones that were largely mechanical changes), but I left the more interesting revisions to separate followup commits (in this same PR).
2016-03-21Expose attached attributes to `FnKind` abstraction so that I can look at ↵Felix S. Klock II-1/+1
them in borrowck.
2016-03-21Switch libgraphviz from type params to associated types for Node/Edge.Felix S. Klock II-2/+6
2016-03-14Move projection_mode to InferContext rather than SelectionContext to reduce ↵Aaron Turon-3/+14
chance of bugs
2016-03-07Auto merge of #31606 - Ms2ger:ClosureKind, r=eddybbors-1/+1
Rename ClosureKind variants and stop re-exporting them.
2016-03-03Rename middle::ty::ctxt to TyCtxtJeffrey Seyfried-25/+25
2016-02-17Rollup merge of #31679 - GuillaumeGomez:long_error_explanation, r=ManishearthSteve Klabnik-6/+14
r? @Manishearth
2016-02-15Global error explanations improvementsggomez-6/+14
2016-02-14Rename hir::Pat_ and its variantsVadim Petrochenkov-2/+2
2016-02-13Auto merge of #31524 - jonas-schievink:autoderef, r=steveklabnikbors-53/+53
2016-02-12Autoderef in librustc_borrowckJonas Schievink-53/+53
2016-02-12Auto merge of #30726 - GuillaumeGomez:compile-fail, r=brsonbors-12/+25
r? @brson cc @alexcrichton I still need to add error code explanation test with this, but I can't figure out a way to generate the `.md` files in order to test example source codes. Will fix #27328.
2016-02-12Rename ClosureKind variants and stop re-exporting them.Ms2ger-1/+1
2016-02-11bootstrap: Add a bunch of Cargo.toml filesAlex Crichton-0/+16
These describe the structure of all our crate dependencies.
2016-02-07Update long error explanationsGuillaume Gomez-12/+25
2016-02-02Rollup merge of #31270 - ruud-v-a:improve-e0507, r=steveklabnikSteve Klabnik-0/+27
E0507 can occur when you try to move out of a member of a mutably borrowed struct, in which case `mem::replace` can help. Mentioning that here hopefully saves future users a trip to Google.
2016-01-28Auto merge of #30411 - mitaa:multispan, r=nrcbors-1/+1
This allows to render multiple spans on one line, or to splice multiple replacements into a code suggestion. fixes #28124
2016-01-28Improve message for rustc --explain E0507Ruud van Asseldonk-0/+27
E0507 can occur when you try to move out of a member of a mutably borrowed struct, in which case `mem::replace` can help. Mentioning that here hopefully saves future users a trip to Google.
2016-01-28Implement MultiSpan error reportingmitaa-1/+1
This allows to render multiple spans on one line, or to splice multiple replacements into a code suggestion.