Mark
e572d85e00
Merge branch 'master' into master
2017-08-31 12:49:48 -04:00
Alex Crichton
2972687d10
Update bootstrap compiler
...
This commit updates the bootstrap compiler and clears out a number
of #[cfg(stage0)] annotations and related business
2017-08-31 06:58:58 -07:00
MarkMcCaskey
1d69c985be
update unimplemented! docs
2017-08-30 22:26:54 -04:00
Alex Crichton
c0812c8458
Rollup merge of #44160 - AndyGauge:api-docs-macros, r=steveklabnik
...
API docs: macros. Standard Documentation Checklist
Fixes #29381
r? @steveklabnik
2017-08-30 13:17:05 -07:00
Chris Stankus
e15a07ad64
Remove Borrow bound from SliceExt::binary_search
2017-08-30 12:02:25 -05:00
Jimmy Cuadra
414ee9a254
Remove test case that assumes FromStr provides TryFrom<&'a str>.
...
See https://travis-ci.org/rust-lang/rust/jobs/269861252
2017-08-30 04:43:09 -07:00
Jimmy Cuadra
b0edfce950
Implement TryFrom explicitly for infallible numeric conversions.
...
See https://github.com/rust-lang/rust/pull/44174#discussion_r135982787
2017-08-30 04:42:25 -07:00
bors
c66e7fa8de
Auto merge of #43903 - oli-obk:alignto, r=aturon
...
Add align_offset intrinsic
see https://github.com/rust-lang/rfcs/pull/2043 for details and the plan towards stabilization (reexport in `core::mem` via various convenience functions)
as per @scottmcm 's [comment](https://github.com/rust-lang/rfcs/pull/2043#issuecomment-316818169 ), this is just the intrinsic (which is obviously unstable).
2017-08-30 08:06:42 +00:00
Jimmy Cuadra
80e3f8941d
Add blanket TryFrom impl when From is implemented.
...
Adds `impl<T, U> TryFrom<T> for U where U: From<T>`.
Removes `impl<'a, T> TryFrom<&'a str> for T where T: FromStr` due to
overlapping impls caused by the new blanket impl. This removal is to
be discussed further on the tracking issue for TryFrom.
Refs #33417 .
2017-08-29 22:13:21 -07:00
Ariel Ben-Yehuda
be0ac0124c
Rollup merge of #44158 - dtolnay:zero48, r=sfackler
...
Use a byte literal ASCII 0 instead of its decimal value
@SimonSapin noticed this in https://github.com/dtolnay/itoa/pull/8 .
2017-08-29 21:41:04 +00:00
Ariel Ben-Yehuda
11e75fd115
Rollup merge of #43705 - panicbit:option_ref_mut_cloned, r=aturon
...
libcore: Implement cloned() for Option<&mut T>
None
2017-08-29 21:40:53 +00:00
Andy Gauge
b9b654924e
API docs: macros. Part of #29329 Standard Library Documentation Checklist.
2017-08-29 10:30:19 -07:00
David Tolnay
4312ed765a
Use a byte literal ASCII 0 instead of its decimal value
2017-08-29 10:01:12 -07:00
John Kåre Alsaker
d29af37999
Merge branch 'master' of https://github.com/rust-lang/rust into gen
2017-08-28 02:41:16 +02:00
Tatsuyuki Ishi
611b111139
Move unused-extern-crate to late pass
2017-08-27 19:02:24 +09:00
Jacob Kiesel
c589f867f8
Add clamp functions
2017-08-26 10:21:17 -06:00
Corey Farwell
7e8753d1c1
Rollup merge of #44072 - lukaramu:fix-doc-headings, r=steveklabnik
...
Fix inconsistent doc headings
This fixes headings reading "Unsafety" and "Example", they should be "Safety" and "Examples" according to RFC 1574.
r? @steveklabnik
2017-08-26 06:46:34 -07:00
Tamir Duberstein
b3f50caee0
*: remove crate_{name,type} attributes
...
Fixes #41701 .
2017-08-25 16:18:21 -04:00
Alex Crichton
c872f47276
Merge remote-tracking branch 'origin/master' into gen
2017-08-25 07:15:12 -07:00
bors
ba65645c78
Auto merge of #44031 - scottmcm:swap_with_slice, r=alexcrichton
...
Add [T]::swap_with_slice
The safe version of a method from `ptr`, like `[T]::copy_from_slice` is.
Tracking issue: https://github.com/rust-lang/rust/issues/44030
2017-08-25 10:20:15 +00:00
lukaramu
49ee9f3f08
Fix inconsistent doc headings
...
This fixes headings reading "Unsafety" and "Example", they should be
"Safety" and "Examples" according to RFC 1574.
2017-08-24 18:42:53 +02:00
Oliver Schneider
be96ad2c85
Update intrinsics.rs
2017-08-22 12:48:20 +02:00
Scott McMurray
c4cb2d1f2e
Add [T]::swap_with_slice
...
The safe version of a method from ptr, like [T]::copy_from_slice
2017-08-21 22:20:00 -07:00
Alex Crichton
04c66c30a7
Merge remote-tracking branch 'origin/master' into gen
2017-08-21 21:47:07 -07:00
bors
942711e115
Auto merge of #43690 - scalexm:issue-28229, r=nikomatsakis
...
Generate builtin impls for `Clone`
This fixes a long-standing ICE and limitation where some builtin types implement `Copy` but not `Clone` (whereas `Clone` is a super trait of `Copy`).
However, this PR has a few side-effects:
* `Clone` is now marked as a lang item.
* `[T; N]` is now `Clone` if `T: Clone` (currently, only if `T: Copy` and for `N <= 32`).
* `fn foo<'a>() where &'a mut (): Clone { }` won't compile anymore because of how bounds for builtin traits are handled (e.g. same thing currently if you replace `Clone` by `Copy` in this example). Of course this function is unusable anyway, an error would pop as soon as it is called.
Hence, I'm wondering wether this PR would need an RFC...
Also, cc-ing @nikomatsakis, @arielb1.
Related issues: #28229 , #24000 .
2017-08-22 01:34:54 +00:00
Alex Crichton
b31998ec93
Merge remote-tracking branch 'origin/master' into gen
2017-08-21 10:41:56 -07:00
Oliver Schneider
1dc3a2b5fa
Add align_offset intrinsic
...
see https://github.com/rust-lang/rfcs/pull/2043 for details
2017-08-21 15:57:21 +02:00
bors
c1111dfcac
Auto merge of #43996 - shanavas786:fix-typo, r=frewsxcv
...
Fix typo in doc
2017-08-20 15:58:05 +00:00
bors
3d9f57a292
Auto merge of #43978 - GuillaumeGomez:missing-links, r=frewsxcv
...
Missing links
r? @rust-lang/docs
2017-08-20 13:28:18 +00:00
Shanavas M
ee3463eb7f
Fix typo in doc
2017-08-20 11:07:42 +03:00
Corey Farwell
aac3008d12
Minor Iterator::filter_map description rewording.
...
Fixes https://github.com/rust-lang/rust/issues/39294 .
2017-08-18 21:19:30 -04:00
Guillaume Gomez
a5a1739945
Add missing urls for Result struct
2017-08-18 16:48:07 +02:00
Alex Crichton
4b5f330c70
Merge remote-tracking branch 'origin/master' into gen
2017-08-17 13:23:20 -07:00
Corey Farwell
58f3041eca
Rollup merge of #43928 - anthonyclays:anthonyclays-refcell-docfix, r=QuietMisdreavus
...
Fixed typo in RefCell::get_mut
"[...] is usually not you want." => "[...] is usually not what you want."
2017-08-17 10:44:14 -04:00
Corey Farwell
1512e44c17
Rollup merge of #43905 - partim:master, r=steveklabnik
...
Document that `std:#️⃣ :Hasher::finish()` does not reset the hasher.
Clarifies the fact that `finish()` doesn’t in fact end or reset the hasher. This was surprising to me …
Follows up on and fixes #43763
2017-08-17 10:44:08 -04:00
Corey Farwell
a4387d54dc
Rollup merge of #43891 - Fourchaux:master, r=steveklabnik
...
Fix typos & us spellings
Fixing some typos and non en-US spellings.
(Update of PR https://github.com/rust-lang/rust/pull/42812 )
2017-08-17 10:44:07 -04:00
Anthony Clays
fa346fc5d6
Fixed typo in RefCell::get_mut
2017-08-17 10:57:17 +02:00
Alex Crichton
1210ebff43
Merge remote-tracking branch 'origin/master' into gen
2017-08-16 10:03:47 -07:00
Martin Hoffmann
02aaa1180e
Document that std: #️⃣ :Hasher::finish() does not reset the hasher.
2017-08-16 17:02:39 +02:00
Zack M. Davis
1b6c9605e4
use field init shorthand EVERYWHERE
...
Like #43008 (f668999 ), but _much more aggressive_.
2017-08-15 15:29:17 -07:00
Fourchaux
c7104be1a3
Fix typos & us spellings
2017-08-15 21:56:30 +02:00
Alex Crichton
1413253a41
Merge remote-tracking branch 'origin/master' into gen
2017-08-14 19:36:13 -07:00
Corey Farwell
1259db2fa4
Rollup merge of #43868 - lukaramu:issue-43866, r=steveklabnik
...
Add missing newline in Deref docs to fix rendering
Fixes #43866 .
(Verified locally.)
r? @steveklabnik
2017-08-14 20:28:48 -04:00
lukaramu
879107f1a8
Add missing newline in Deref docs to fix rendering
...
Fixes #43866 .
2017-08-14 22:12:33 +02:00
bors
f1ca76c497
Auto merge of #43574 - notriddle:master, r=sfackler
...
Implement `RefCell::replace` and `RefCell::swap`
Tracking issue: #43570
2017-08-14 17:05:02 +00:00
scalexm
0c3ac648f8
Make Clone a lang item and generate builtin impls.
...
Fixes #28229 .
Fixes #24000 .
2017-08-14 15:07:21 +02:00
bors
b1ff235490
Auto merge of #43856 - sfackler:no-inline-debug, r=alexcrichton
...
Don't inline debug methods
The inner methods aren't inlined, so this puts more pressure on LLVM for
literally no benefit.
Closes #43843
2017-08-14 07:50:36 +00:00
Steven Fackler
81f481d3c6
Don't inline debug methods
...
The inner methods aren't inlined, so this puts more pressure on LLVM for
literally no benefit.
Closes #43843
2017-08-13 17:06:17 -07:00
bors
f3cf206201
Auto merge of #43836 - taleks:issue-39827, r=arielb1
...
Fix for issue #39827
*Cause of the issue*
While preparing for `trans_intrinsic_call()` invoke arguments are processed with `trans_argument()` method which excludes zero-sized types from argument list (to be more correct - all arguments for which `ArgKind` is `Ignore` are filtered out). As result `volatile_store()` intrinsic gets one argument instead of expected address and value.
*How it is fixed*
Modification of the `trans_argument()` method may cause side effects, therefore change was implemented in `volatile_store()` intrinsic building code itself. Now it checks function signature and if it was specialised with zero-sized type, then emits `C_nil()` instead of accessing non-existing second argument.
2017-08-13 23:33:18 +00:00
Alexey Tarasov
faf6b84304
Addresses comments in PR #43836
...
- removes warnings introduced in changeset 0cd3587
- makes documentation more neat and grammatically correct
2017-08-13 19:28:04 +10:00