about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorLines
2018-03-20Remove outdated commentOliver Schneider-1/+0
2018-03-20Auto merge of #49190 - kennytm:rollup, r=kennytmbors-662/+1033
Rollup of 17 pull requests - Successful merges: #46518, #48810, #48834, #48902, #49004, #49092, #49096, #49099, #49104, #49125, #49139, #49152, #49157, #49161, #49166, #49176, #49184 - Failed merges:
2018-03-20Auto merge of #48516 - petrochenkov:stabsl, r=nikomatsakisbors-226/+124
Stabilize slice patterns without `..` And merge `feature(advanced_slice_patterns)` into `feature(slice_patterns)`. The detailed description can be found in https://github.com/rust-lang/rust/issues/48836. Slice patterns were unstable for long time since before 1.0 due to many bugs in the implementation, now this stabilization is possible primarily due to work of @arielb1 who [wrote the new MIR-based implementation of slice patterns](https://github.com/rust-lang/rust/pull/32202) and @mikhail-m1 who [fixed one remaining class of codegen issues](https://github.com/rust-lang/rust/pull/47926). Reference PR https://github.com/rust-lang-nursery/reference/pull/259 cc https://github.com/rust-lang/rust/issues/23121 fixes #48836
2018-03-20Rollup merge of #49184 - bdrewery:update-beta-freebsd, r=alexcrichtonkennytm-1/+1
Update beta to version with fixed FreeBSD support from #49023. Fixes #42681 r? @alexcrichton
2018-03-20Rollup merge of #49166 - dileepbapat:pr-49133, r=nikomatsakiskennytm-4/+4
#49133 - Reworded the Error message: "`pub` not needed here" message
2018-03-20Rollup merge of #49161 - rust-lang:SimonSapin-patch-1, r=KodrAuskennytm-1/+1
Docs: fix incorrect copy-paste for new `X?` in formatting strings
2018-03-20Rollup merge of #49157 - estebank:const-into, r=oli-obkkennytm-1/+50
Do not suggest `.into()` in `const`s Fix #49100.
2018-03-20Rollup merge of #49152 - GuillaumeGomez:rustdoc-event-handling, ↵kennytm-33/+40
r=QuietMisdreavus Fix events handling in rustdoc Fixes #49075.
2018-03-20Stabilize slice patterns without `..`Vadim Petrochenkov-226/+124
Merge `feature(advanced_slice_patterns)` into `feature(slice_patterns)`
2018-03-20Rollup merge of #49139 - sfackler:bufreader-buffer, r=SimonSapinkennytm-1/+29
Add BufReader::buffer This subsumes the need for an explicit is_empty function, and provides access to the buffered data itself which has been requested from time to time. We could call this `buf` to match `fill_buf`, but I think I'd prefer `fill_buffer` anyways in hindsight.
2018-03-20Rollup merge of #49125 - NovemberZulu:master, r=alexcrichtonkennytm-0/+1
rustbuild: Ship libsynchronization Hot on the heels of #49044 comes similar issue with libsynchronization. Discovered while building clippy: ``` <skipped> Compiling serde_derive v1.0.33 error: linking with `gcc` failed: exit code: 1 <skipped> = note: ld: cannot find -lsynchronization ``` r? @nikomatsakis
2018-03-20Rollup merge of #49104 - csmoe:semicolon_error, r=petrochenkovkennytm-10/+21
improve error message of inner attribute syntax Fixes #49040
2018-03-20Rollup merge of #49099 - glandium:master, r=sfacklerkennytm-17/+15
Use associated consts for GenericRadix base and prefix The trait being private, this does not imply an API change.
2018-03-20Rollup merge of #49096 - alanhdu:master, r=alexcrichtonkennytm-111/+52
Update rustfmt to 0.4.1
2018-03-20Rollup merge of #49092 - mark-i-m:deptrack_readme, r=nikomatsakiskennytm-327/+56
Replace many of the last references to readmes In particular, this removes the dep track readme, so it should not be merged before https://github.com/rust-lang-nursery/rustc-guide/pull/92 Fix #47935 cc #48478 r? @nikomatsakis
2018-03-20Rollup merge of #49004 - wesleywiser:incr_specialization_graph_query, ↵kennytm-1/+6
r=michaelwoerister Cache the specialization_graph query Fixes #48987 r? @michaelwoerister
2018-03-20Rollup merge of #48902 - csmoe:refactor_BorrowckErrors_fn_self, r=nikomatsakiskennytm-94/+94
refactor the `BorrowckErrors` trait to take `fn(self)` Fixes #48783
2018-03-20Rollup merge of #48834 - ysiraichi:suggest-remove-ref, r=estebankkennytm-46/+205
Suggest removing `&`s This implements the error message discussed in #47744. We check whether removing each `&` yields a type that satisfies the requested obligation. Also, it was created a new `NodeId` field in `ObligationCause` in order to iterate through the `&`s. The way it's implemented now, it iterates through the obligation snippet and counts the number of `&`. r? @estebank
2018-03-20Rollup merge of #48810 - Phlosioneer:32463-impl-integer-for-wrapping, r=dtolnaykennytm-0/+309
Implement Integer methods for Wrapping Wrapping<T> now implements: count_ones, count_zeros, leading_zeros, trailing_zeros, rotate_left, rotate_right, swap_bytes, from_be, from_le, to_be, to_le, and pow where T is: u8, u16, u32, u64, usize, i8, i16, i32, i64, or isize. Docs were written for all these methods, as well as examples. The examples mirror the ones on u8, u16, etc... for consistency. Closes #32463
2018-03-20Rollup merge of #46518 - partim:asref-borrow-doc, r=dtolnaykennytm-15/+149
Improve documentation for Borrow This is the first step in improving the documentation for all the reference conversion traits. It proposes new text for the trait documentation of `Borrow`. Since I feel it is a somewhat radical rewrite and includes a stricter contract for `Borrow` then the previous text—namely that *all* shared traits need to behave the same, not just a select few—, I wanted to get some feedback before continuing. Apart from the ‘normative’ description, the new text also includes a fairly extensive explanation of how the trait is used in the examples section. I included it because every time I look at how `HashMap` uses the trait, I need to think for a while as the use is a bit twisted. So, I thought having this thinking written down as part of the trait itself might be useful. One could argue that this should go into The Book, and, while I really like having everything important in the docs, I can see the text moved there, too. So, before I move on: is this new text any good? Do we feel it is correct, useful, comprehensive, and understandable? (This PR is in response to #44868 and #24140.)
2018-03-19Auto merge of #49058 - withoutboats:pin, r=cramertjbors-4/+222
Pin, Unpin, PinBox Implementing rust-lang/rfcs#2349 (do not merge until RFC is merged) @bors r? @cramertj
2018-03-19Okay this is the right way.boats-3/+1
2018-03-19Comment out entire test.boats-1/+3
2018-03-19Ignore properly.boats-3/+1
2018-03-19Comment out flakey test.boats-0/+4
2018-03-19Update beta to version with fixed FreeBSD support from #49023.Bryan Drewery-1/+1
Fixes #42681
2018-03-19Do not suggest `.into()` in `const`sEsteban Küber-1/+50
2018-03-19Update rustfmt to 0.4.1Alan Du-111/+52
2018-03-19#49133 - Reworded the Error message: "`pub` not needed here" messageDileep Bapat-3/+3
2018-03-19#49133 - Reworded the Error message: "`pub` not needed here" messageDileep Bapat-1/+1
2018-03-19Auto merge of #49079 - oli-obk:cross_miri, r=michaelwoeristerbors-126/+212
Cleanup metadata and incremental cache processing of constants fixes #49033 fixes #49081 we really need tests for this. do we have any cross compilation tests? I couldn't find any
2018-03-19Auto merge of #49108 - SimonSapin:sip, r=TimNNbors-55/+23
Remove or hide deprecated unstable SipHasher{13,24} Deprecated since Rust 1.13.0.
2018-03-19Docs: fix incorrect copy-paste for new `X?` in formatting stringsSimon Sapin-1/+1
2018-03-19Fix trailing whitespacePhlosioneer-1/+1
2018-03-19Make Wrapping::pow use wrapping_pow, add examplePhlosioneer-4/+14
2018-03-19Impl Integer methods for WrappingPhlosioneer-0/+299
Wrapping<T> now implements: count_ones, count_zeros, leading_zeros, trailing_zeros, rotate_left, rotate_right, swap_bytes, from_be, from_le, to_be, to_le, and pow where T is: u8, u16, u32, u64, usize, i8, i16, i32, i64, or isize. Docs were written for all these methods, as well as examples. The examples mirror the ones on u8, u16, etc... for consistency. Closes #32463
2018-03-19Auto merge of #49091 - nikomatsakis:issue-49043-ty-infer-hash, ↵bors-3/+72
r=michaelwoerister extend stable hasher to support `CanonicalTy` Fixes #49043 r? @michaelwoerister
2018-03-19Auto merge of #48978 - SimonSapin:debug-hex, r=KodrAusbors-4/+42
Add hexadecimal formatting of integers with fmt::Debug This can be used for integers within a larger types which implements Debug (possibly through derive) but not fmt::UpperHex or fmt::LowerHex. ```rust assert!(format!("{:02x?}", b"Foo\0") == "[46, 6f, 6f, 00]"); assert!(format!("{:02X?}", b"Foo\0") == "[46, 6F, 6F, 00]"); ``` RFC: https://github.com/rust-lang/rfcs/pull/2226 The new formatting string syntax (`x?` and `X?`) is insta-stable in this PR because I don’t know how to change a built-in proc macro’s behavior based of a feature gate. I can look into adding that, but I also strongly suspect that keeping this feature unstable for a time period would not be useful as possibly no-one would use it during that time. This PR does not add the new (public) `fmt::Formatter` proposed in the API because: * There was some skepticism on response to this part of the RFC * It is not possible to implement as-is without larger changes to `fmt`, because `Formatter` at the moment has no easy way to tell apart for example `Octal` from `Binary`: it only has a function pointer for the relevant `fmt()` method. If some integer-like type outside of `std` want to implement this behavior, another RFC will likely need to propose a different public API for `Formatter`.
2018-03-19Auto merge of #49095 - alexcrichton:debug-asmjs, r=kennytmbors-5/+31
Try to reduce amount of time on the asmjs builder This PR has two commits for two separate strategies: * First it disables optimizations for all tests, hopefully saving time by not optimizing the test code. This caused a number of run-pass tests to fail which are switched to being ignored here. * Next it disables a number of test suites which aren't asm.js specific and already run elsewhere cc #48826
2018-03-18Cleaned comments and extras s.Yukio Siraichi-40/+2
2018-03-18CodeMap functions refactored.Yukio Siraichi-50/+38
- Using `span_take_while` to implement others.
2018-03-18Review fixes.Yukio Siraichi-21/+35
- `span_suggestion` changed to `span_suggestion_short`; - `Span` used changed to contain only `&` refs; - Tests passing.
2018-03-18Reporting with `span_suggestion_short`.Yukio Siraichi-15/+5
2018-03-18Rebased with master.Yukio Siraichi-5/+5
2018-03-18Created multiple line test.Yukio Siraichi-0/+43
2018-03-18Keeping code formatting.Yukio Siraichi-3/+8
Suggesting snippet without changing the original formatting of the code.
2018-03-18Review fixes.Yukio Siraichi-5/+9
- `suggest_snippet` handling space between refs; - Suggest message changing according to the number of refs that should be removed.
2018-03-18New test added.Yukio Siraichi-2/+35
2018-03-18Test added.Yukio Siraichi-0/+33
2018-03-18Refactored with high-order functions.Yukio Siraichi-21/+21