about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorLines
2019-01-18Rollup merge of #57357 - frewsxcv:frewsxcv-partial-eq, r=QuietMisdreavusMazdak Farrokhzad-16/+22
Cleanup PartialEq docs. - Cleanup the `impl PartialEq<BookFormat> for Book` implementation - Implement `impl PartialEq<Book> for BookFormat` so it’s symmetric - Fixes https://github.com/rust-lang/rust/issues/53844. - Removes the last example since it appears to be redundant with the previous two examples.
2019-01-18Rollup merge of #57340 - eqrion:doc/c_variadic, r=Mark-SimulacrumMazdak Farrokhzad-12/+12
Use correct tracking issue for c_variadic Fixes #57306
2019-01-18Rollup merge of #56594 - sdroege:c_void-is-not-never, r=TimNNMazdak Farrokhzad-7/+10
Remove confusing comment about ideally using `!` for `c_void` Using `!` for `c_void` would have the problem that pointers and potentially references to an uninhabited type would be created, and at least for references this is UB. In addition document that newtype wrappers around `c_void` can be used safely in place of `extern type` until the latter is stabilized. ---- I'm not 100% sure about the usage for opaque types as the [nomicon](https://doc.rust-lang.org/nomicon/ffi.html#representing-opaque-structs) still recommends using `#[repr(C)] pub struct Foo { _private: [u8; 0] }` but it seems like these two should be equivalent in the end? Also the `#[repr(C)]` (in both cases) should be unneeded because such types never being passed by value, never being dereferenced but only passed around as pointer or reference, so the representation of (*values* of) the type itself should not matter at all? Also in context of `c_void` and `!` the second unresolved question in the [`extern type`](https://github.com/rust-lang/rust/issues/43467) stabilization ticket seems relevant > In [std's](https://github.com/rust-lang/rust/blob/164619a8cfe6d376d25bd3a6a9a5f2856c8de64d/src/libstd/os/raw.rs#L59-L64) source, it is mentioned that LLVM expects i8* for C's void*. > We'd need to continue to hack this for the two c_voids in std and libc. > But perhaps this should be done across-the-board for all extern types? > Somebody should check what Clang does. Please correct me if my understanding is wrong and everything's actually fine as is.
2019-01-18Auto merge of #56189 - rep-nop:keep_doc_test_executable, r=QuietMisdreavusbors-8/+73
rustdoc: Add option to persist doc test executables Fixes #37048. This is the initial version of the code so the doctest executables can be used for stuff like code coverage (specifically https://github.com/xd009642/tarpaulin/issues/13) the folders it goes into were just a first idea, so any better ones are welcome. Right now it creates a directory structure like: ``` given_path/ |_____ <filename>_rs_<linenum>/ |_____ ... |_____ <filename>_rs_<linenum>/ |_____ rust_out ``` I couldn't figure out where it actually outputs the file w/ the name, I suspect its somewhere deeper in the compiler. It also adds the unstable `--persist-doctests` flag to `rustdoc` that enables this behavior.
2019-01-18Remove delay_span_bug from qualify_min_const_fnPhilipp Hansch-7/+1
This is causing issues with a new Clippy lint that will be able to detect possible const functions. As per https://github.com/rust-lang/rust-clippy/pull/3648#discussion_r247927450
2019-01-18Allow evaluating trivial drop glue in constantsOliver Scherer-13/+29
2019-01-18Merge visitors in AST validationJohn Kåre Alsaker-144/+111
2019-01-18Auto merge of #57065 - Zoxc:graph-tweaks, r=michaelwoeristerbors-113/+117
Optimize try_mark_green and eliminate the lock on dep node colors Blocked on https://github.com/rust-lang/rust/pull/56614 r? @michaelwoerister
2019-01-18Manually inline a function that was only used onceOliver Scherer-15/+5
2019-01-18Point at return type when appropriateEsteban Küber-5/+30
2019-01-18Auto merge of #56996 - clarcharr:spin_loop_hint, r=KodrAusbors-9/+27
Move spin_loop_hint to core::hint module As mentioned in #55002. The new name is kept unstable to decide whether the function should have `_hint` in its name.
2019-01-17Fix test after rebaseEsteban Küber-4/+6
2019-01-17Correct error location indicated by commentsKevin Leimkuhler-4/+4
2019-01-17Override `Iterator::is_sorted_by` in `slice::Iter` implLukas Kalbertodt-27/+26
Additionally, the root implementation was changed a bit: it now uses `all` instead of coding that logic manually. To avoid duplicate code, the inherent `[T]::is_sorted_by` method now calls `self.iter().is_sorted_by(...)`. This should always be inlined and not result in overhead.
2019-01-17Compare pairs with `slice::windows`Kevin Leimkuhler-8/+9
2019-01-17Improve documentation and slice implKevin Leimkuhler-11/+18
2019-01-17Add is_sorted unstable documentationKevin Leimkuhler-3/+41
2019-01-17Add is_sorted impl for [T]Kevin Leimkuhler-22/+110
2019-01-17Add initial impl of is_sorted to IteratorKevin Leimkuhler-0/+134
2019-01-17Fix tidy errorEsteban Küber-1/+1
2019-01-17Point at more cases involving return typesEsteban Küber-2/+9
2019-01-17Avoid pointing at multiple places on return type errorEsteban Küber-19/+23
2019-01-17Point more places where expectation comes fromEsteban Küber-5/+10
2019-01-17Do not give incorrect label for return type mismatchEsteban Küber-3/+142
2019-01-17Use structured suggestion to surround struct literal with parenthesisEsteban Küber-8/+46
2019-01-17fix compat-mode ui testMark Mansi-1/+1
2019-01-17Update testsMark Mansi-93/+88
2019-01-17better lifetime error messageMark Mansi-1/+1
2019-01-17Update cargoEric Huss-0/+0
2019-01-18Fix suggestions given mulitple bad lifetimesDan Robertson-21/+69
When given multiple lifetimes prior to type parameters in generic parameters, do not ICE and print the correct suggestion.
2019-01-18Inline `expand_node`.Nicholas Nethercote-9/+14
This requires restructuring things a little so that there is only one callsite, ensuring that inlinining doesn't cause unnecessary code bloat. This reduces instruction counts for the `unicode_normalization` benchmark by up to 4%.
2019-01-18Remove unneeded `origin` arg from `iterate_until_fixed_point`'s closure.Nicholas Nethercote-7/+6
2019-01-17Bless test.Wesley Norris-3/+11
Bless test, remove submodule, and fix book entry. bless test again? maybe it'll work this time...
2019-01-17Add book section and fix typo.Wesley Norris-1/+7
2019-01-17Minor changes to wording and formatting.Wesley Norris-6/+7
2019-01-17Bless test.Wesley Norris-2/+3
2019-01-17Fix tidy error.Wesley Norris-2/+10
2019-01-17Persist doc test executables to given path.Wesley Norris-6/+47
2019-01-18privacy: Account for associated existential typesVadim Petrochenkov-23/+59
2019-01-17Fix non-clickable urlsGuillaume Gomez-4/+0
2019-01-18Fix testsYuki Okushi-11/+67
2019-01-18Add token::ErrYuki Okushi-1/+1
2019-01-18Change from mk_lit! to cx.exprYuki Okushi-1/+1
2019-01-18Continue chekingYuki Okushi-1/+1
2019-01-18Change from error to invalidYuki Okushi-1/+1
2019-01-17Fix typo: 'rust-gdbgui' instead of 'rust-gdbui'Nicolas Bigaouette-1/+1
2019-01-17Install missing 'rust-gdbui''Nicolas Bigaouette-0/+2
See https://github.com/rust-lang/rust/pull/53774#issuecomment-419704939
2019-01-17Simplify Debug implementation of MutexGuard.Mara Bos-7/+1
Just transparently print the guarded data, instead of wrapping it in `MutexGuard { lock: Mutex { data: ... } }`.
2019-01-17Update bootstrap.pylenoil98-0/+3
Add PowerPC64 support on FreeBSD
2019-01-17Make MutexGuard's Debug implementation more useful.Mara Bos-3/+7
Fixes #57702.