Mark Rousskov
2870015b7b
Bootstrap compiler update for 1.35 release
2019-03-02 09:05:34 -07:00
Ralf Jung
811af4289c
fix link
2019-02-21 17:18:18 +01:00
Ralf Jung
2db0e0d65c
tweaks and fix weird space
2019-02-21 15:30:31 +01:00
Mazdak Farrokhzad
e61a8a94f7
Apply suggestions from code review
...
Co-Authored-By: RalfJung <post@ralfj.de>
2019-02-21 15:28:46 +01:00
Ralf Jung
9c241aa714
expand Unpin example
2019-02-19 21:27:48 +01:00
Ralf Jung
3040380206
rewrite pin module intro
2019-02-19 20:50:16 +01:00
Ralf Jung
442c486736
separate section for doubly-linked list, reword projections intro
2019-02-19 20:17:20 +01:00
Ralf Jung
a8d18b9560
apply some of the feedback
2019-02-19 19:46:33 +01:00
Ralf Jung
4059889539
improve Pin documentation
2019-02-19 13:24:17 +01:00
Mazdak Farrokhzad
aa896f30bb
Rollup merge of #57856 - lzutao:fix-old-first-edition, r=steveklabnik
...
Convert old first edition links to current edition one
r? @steveklabnik
2019-02-14 02:41:16 +01:00
Lzu Tao
e7f8e63ed4
Convert old doc links to current edition
...
Use footnote style to bypass the tidy check
2019-02-13 14:39:25 +00:00
Wim Looman
730b18b6e5
Mark static generators as !Unpin
2019-01-27 22:58:59 +01:00
Corey Farwell
d2c91a1a6d
Fix broken links to second edition TRPL.
...
Fixes https://github.com/rust-lang/rust/issues/57104 .
2019-01-01 12:53:07 -05:00
Mark Rousskov
2a663555dd
Remove licenses
2018-12-25 21:08:33 -07:00
Taylor Cramer
3005bf360d
Pin stabilization: fix doctests
2018-12-21 20:42:50 -08:00
Taylor Cramer
610bcaf6f3
Stabilize Pin
2018-12-21 20:42:50 -08:00
Taylor Cramer
709b7515e7
Rename Pinned marker type to PhantomPinned
2018-12-12 12:23:58 -08:00
Alexander Regueiro
ee89c088b0
Various minor/cosmetic improvements to code
2018-12-07 23:53:34 +00:00
Oliver Scherer
1894a5fe2c
Also make immutable references to non-freeze restricted value range types unsafe
2018-12-04 10:17:36 +01:00
Mazdak Farrokhzad
5e7b7f2ae6
make PhantomData #[structural_match].
2018-11-10 03:39:42 +01:00
Esteban Küber
ed10a3faae
Custom E0277 diagnostic for Path
2018-10-10 17:30:10 -07:00
Scott McMurray
0a3bd9b6ab
Use impl_header_lifetime_elision in libcore
2018-09-29 21:33:35 -07:00
Without Boats
974bdc80fe
Update to a new pinning API.
2018-09-01 06:57:58 +02:00
Niv Kaminer
b26cce5ec0
link to items in pin module to std docs
2018-08-23 10:16:58 +03:00
Niv Kaminer
3683bf279d
adjust PinMut import in Unpin docs
2018-08-23 02:13:02 +03:00
Niv Kaminer
c3fd65ba23
link Unpin to pin module documentation
2018-08-23 02:13:02 +03:00
Niv Kaminer
bfed149020
reexport Unpin into pin module
2018-08-23 02:13:01 +03:00
Niv Kaminer
c1103885fe
fix link to PinMut
2018-08-23 01:37:03 +03:00
kennytm
0dd88c9797
Rollup merge of #53329 - frewsxcv:frewsxcv-ptr-add-sub, r=RalfJung
...
Replace usages of ptr::offset with ptr::{add,sub}.
Rust provides these helper methods – so let's use them!
2018-08-21 22:05:30 +08:00
kennytm
dc8e9fb2b1
Rollup merge of #53104 - nivkner:unpin_doc, r=RalfJung
...
expand the documentation on the `Unpin` trait
provides an overview of the Pin API which the trait is for,
and show how it can be used in making self referencial structs
part of #49150
2018-08-21 17:52:01 +08:00
Corey Farwell
993fb93464
Replace usages of ptr::offset with ptr::{add,sub}.
2018-08-20 07:28:34 -04:00
Niv Kaminer
6ae915b29e
clarify use of Unpin and pinning types
2018-08-17 22:28:05 +03:00
Niv Kaminer
03530fa5e6
add example for moving out of pointer
2018-08-16 13:56:08 +03:00
Niv Kaminer
68e766afab
remove general pinning information from Unpin trait
2018-08-07 21:14:57 +03:00
Niv Kaminer
87bbd2eeef
fix style issues in doc comment
2018-08-07 00:00:51 +03:00
Niv Kaminer
9b7d71067b
fix link to PinBox
2018-08-06 14:01:49 +03:00
Niv Kaminer
6845dc43cd
correct explenation on the usage of NonNull
2018-08-06 12:02:46 +03:00
Niv Kaminer
038ce659e3
expand the documentation on the Unpin trait
...
provides an overview of the Pin API which the trait is for,
and show how it can be used in making self referencial structs
part of #49150
2018-08-06 10:52:35 +03:00
Felix Rabe
c74415872c
Fix doc link (again)
...
Similar to #52404 . The link for comparison:
- https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-sized (broken)
- https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait (correct, stable 2nd ed)
- https://doc.rust-lang.org/nightly/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait (correct, nightly 2nd ed)
- https://doc.rust-lang.org/nightly/book/2018-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait (correct, nightly 2018 ed)
This commit is the result of (first) searching via ripgrep (0.8.1 -SIMD -AVX):
rg -l dynamically-sized-types-and-sized
and then replacing all relevant occurrences via:
find src/{libcore,test/ui} -type f -print0 | xargs -0 sed -i.bak \
s/dynamically-sized-types-and-sized/dynamically-sized-types-and-the-sized-trait/g
find src/{libcore,test/ui} -type f -name '*.bak' -print0 | xargs -0 rm
(Note: Tested on on macOS 10.13 (BSD). `sed -i.bak` should work on Linux
(GNU sed) as well, but not tested.)
2018-08-05 07:52:29 +02:00
Felix Rabe
88e9af0375
Fix doc link
...
The link for comparison:
- https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types--sized (broken)
- https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-sized (fixed)
This commit is the result of (first) searching via:
find src -type f -print0 | xargs -0 fgrep -l dynamically-sized-types--sized
and then replacing all relevant occurrences via:
find src/{libcore,test/ui} -type f -print0 | xargs -0 sed -i.bak \
s/dynamically-sized-types--sized/dynamically-sized-types-and-sized/g
find src/{libcore,test/ui} -type f -name '*.bak' -print0 | xargs -0 rm
(Note: Commands run on macOS 10.13 (BSD). `sed -i.bak` should work on
GNU/Linux as well, but not tested.)
2018-07-17 14:10:11 +02:00
Rémy Rakic
b8c96ce530
Fix typo in error message E0277
2018-07-10 23:10:13 +02:00
Taylor Cramer
2ce61c0aed
Implement Unpin for references
...
These don'town the backing storage for their data,
so projecting `PinMut` into their fields is already unsound.
2018-06-29 19:31:55 -07:00
Esteban Küber
d4bfae1319
Update message for !Sized types
2018-06-19 17:32:33 -07:00
Esteban Küber
f1dee43887
Add link to book for Sized errors
2018-06-19 15:19:15 -07:00
Esteban Küber
776544f011
Add message to rustc_on_unimplemented attributes in core
2018-06-19 15:19:13 -07:00
CrLF0710
8e90a2d02f
Replace if with if and only if in the definition dox of Sync
...
The old text was: "The precise definition is: a type T is Sync if &T is Send."
Since we've also got
```
impl<'a, T> Send for &'a T
where
T: Sync + ?Sized,
```
I purpose we can change the `if` to `if and only if` to make it more precise.
2018-06-01 09:37:05 +08:00
Taylor Cramer
640f6f0749
Add Pinned type for opting out of Unpin on stable
2018-05-22 17:24:49 -07:00
Taylor Cramer
a44abfdc29
Make Unpin safe to implement
2018-05-22 17:24:49 -07:00
Mark Simulacrum
9e3432447a
Switch to 1.26 bootstrap compiler
2018-05-17 08:47:25 -06:00
Ralf Jung
939c25a522
Unpin: Fix references to Pin type
2018-05-07 14:30:29 +02:00