rust/src/libcore
Mazdak Farrokhzad 088c99410b
Rollup merge of #60443 - RalfJung:as_ptr, r=SimonSapin
as_ptr returns a read-only pointer

Add comments to `as_ptr` methods to warn that these are read-only pointers, and writing to them is UB.

[It was pointed out](https://internals.rust-lang.org/t/as-ptr-vs-as-mut-ptr/9940) that `CStr` does not even have an `as_mut_ptr`. I originally was going to add one, but there is no method at all that would mutate a `CStr`. Was that a deliberate choice or should I add an `as_mut_ptr` (similar to [what I did for `str`](https://github.com/rust-lang/rust/pull/58200))?
2019-05-14 22:00:11 +02:00
..
benches libcore => 2018 2019-04-18 14:47:35 +09:00
char libcore: deny more... 2019-04-19 01:37:12 +02:00
fmt libcore: deny more... 2019-04-19 01:37:12 +02:00
future Stabilize futures_api 2019-04-23 16:13:53 -07:00
hash libcore: deny more... 2019-04-19 01:37:12 +02:00
iter Rollup merge of #60130 - khuey:efficient_last, r=sfackler 2019-05-14 22:00:09 +02:00
num to_xe_bytes for isize and usize returns an array of different size 2019-05-05 23:07:14 +01:00
ops Remove double trailing newlines 2019-04-22 16:57:01 +01:00
prelude libcore => 2018 2019-04-18 14:47:35 +09:00
slice Rollup merge of #60443 - RalfJung:as_ptr, r=SimonSapin 2019-05-14 22:00:11 +02:00
str Rollup merge of #60443 - RalfJung:as_ptr, r=SimonSapin 2019-05-14 22:00:11 +02:00
sync libcore: deny more... 2019-04-19 01:37:12 +02:00
task Stabilize futures_api 2019-04-23 16:13:53 -07:00
tests Rollup merge of #60201 - RalfJung:core-tests, r=alexcrichton 2019-05-13 21:36:51 +02:00
unicode libcore => 2018 2019-04-18 14:47:35 +09:00
alloc.rs libcore: deny more... 2019-04-19 01:37:12 +02:00
any.rs libcore: deny more... 2019-04-19 01:37:12 +02:00
array.rs Auto merge of #60318 - jethrogb:jb/try-from-slice-to-infallible, r=sfackler 2019-05-11 19:13:12 +00:00
ascii.rs Add implementations of last in terms of next_back on a bunch of DoubleEndedIterators. 2019-04-19 21:52:43 -07:00
borrow.rs be more direct about borrow requirenments 2019-04-03 11:41:24 +03:00
Cargo.toml libcore => 2018 2019-04-18 14:47:35 +09:00
cell.rs libcore: deny more... 2019-04-19 01:37:12 +02:00
clone.rs libcore => 2018 2019-04-18 14:47:35 +09:00
cmp.rs libcore => 2018 2019-04-18 14:47:35 +09:00
convert.rs libcore => 2018 2019-04-18 14:47:35 +09:00
default.rs libs: doc comments 2019-02-10 23:57:25 +00:00
ffi.rs libcore: deny more... 2019-04-19 01:37:12 +02:00
hint.rs libcore => 2018 2019-04-18 14:47:35 +09:00
internal_macros.rs libcore => 2018 2019-04-18 14:47:35 +09:00
intrinsics.rs libcore => 2018 2019-04-18 14:47:35 +09:00
iter_private.rs Remove licenses 2018-12-25 21:08:33 -07:00
lib.rs libcore: deny more... 2019-04-19 01:37:12 +02:00
macros.rs Rollup merge of #59448 - benesch:macro-doc, r=Centril 2019-03-28 08:43:39 +01:00
marker.rs libcore => 2018 2019-04-18 14:47:35 +09:00
mem.rs Rollup merge of #60609 - spastorino:be-explicit-on-mem-replace-doc, r=Centril 2019-05-07 19:30:11 +02:00
option.rs Add flatten option for Option<Option<T>> 2019-04-26 16:59:12 +01:00
panic.rs libcore: deny more... 2019-04-19 01:37:12 +02:00
panicking.rs libcore: deny more... 2019-04-19 01:37:12 +02:00
pin.rs pin: make the to-module link more visible 2019-05-08 17:21:05 +02:00
ptr.rs Auto merge of #60244 - SimonSapin:dangling, r=oli-obk 2019-05-12 14:32:11 +00:00
raw.rs Remove licenses 2018-12-25 21:08:33 -07:00
result.rs libcore: deny more... 2019-04-19 01:37:12 +02:00
time.rs libcore: deny more... 2019-04-19 01:37:12 +02:00
tuple.rs libcore => 2018 2019-04-18 14:47:35 +09:00
unit.rs libcore => 2018 2019-04-18 14:47:35 +09:00