Commit Graph

135949 Commits

Author SHA1 Message Date
C
d24a27797d refactor: moving SpecFromIter into spec_from_iter.rs 2020-12-29 14:03:30 +00:00
C
56d82b3dcc refactor: moved SpecFromIterNested to spec_from_iter_nested.rs 2020-12-29 14:03:30 +00:00
C
9e08ce7190 refactor: moved InPlaceDrop into in_place_drop.rs 2020-12-29 14:03:30 +00:00
C
a3f3fc5aed refactor: moved SetLenOnDrop to set_len_on_drop 2020-12-29 14:03:30 +00:00
C
a2f4bc0d18 refactor: moved SpecFromElem to spec_from_elem.rs 2020-12-29 14:03:30 +00:00
C
dc46013248 refactor: moved PartialEq into partial_eq 2020-12-29 14:03:30 +00:00
C
5ac6709b95 refactor: moving SourceIterMarker into source_iter_marker.rs 2020-12-29 14:03:30 +00:00
C
840c4e2873 refactor: moved IsZero into is_zero.rs 2020-12-29 14:03:30 +00:00
C
2a1248976a refactor: moving AsIntoIter into into_iter.rs 2020-12-29 14:03:29 +00:00
C
93613901d0 refactor: moved IntoIter into into_iter.rs 2020-12-29 14:03:29 +00:00
C
2580822b91 refactor: moved Vec impl Cow into cow.rs 2020-12-29 14:03:29 +00:00
C
6bf9608f9f refactor: moving Drain into drain.rs 2020-12-29 14:03:29 +00:00
C
17593f258b refactor: moving Splice into splice.rs 2020-12-29 14:03:29 +00:00
C
434e5d1422 refactor: moving DrainFilter into drain_filter.rs 2020-12-29 14:03:29 +00:00
C
5182776c6c refactor: moving vec.rs to vec/mod.rs 2020-12-29 14:03:29 +00:00
Pietro Albini
d0d0ee0b5d
ci: stop producing gzip-compressed dist tarballs 2020-12-29 11:56:25 +01:00
Pietro Albini
0a2034dca4
bootstrap: add the dist.compression-formats option
The option allows to add or remove compression formats used while
producing dist tarballs.
2020-12-29 11:56:25 +01:00
bors
158f8d034b Auto merge of #80014 - jyn514:box-item-kind, r=nnethercote
[rustdoc] Box ItemKind to reduce the size of `Item`

This brings the size of `Item` from

```
[src/librustdoc/lib.rs:103] std::mem::size_of::<Item>() = 536
```

to

```
[src/librustdoc/lib.rs:103] std::mem::size_of::<Item>() = 136
```

This is an alternative to https://github.com/rust-lang/rust/pull/79967; I don't think it makes sense to make both changes.

Helps with #79103.
2020-12-29 10:41:01 +00:00
BlackHoleFox
5449a42a1c Fix small typo in time comment 2020-12-29 02:10:29 -06:00
bors
e2a2592885 Auto merge of #79084 - simonvandel:instcombine-perf, r=oli-obk
Small perf changes for InstCombine
2020-12-29 06:21:18 +00:00
Joshua Nelson
5fce0dd787 Add static assertion for the size of ItemKind 2020-12-29 00:43:25 -05:00
Ikko Ashimine
02db77c2d1
Fix typo in ffi-pure.md
accesing -> accessing
2020-12-29 13:37:21 +09:00
LingMan
3dae414cb6 Use Option::map_or instead of open coding it 2020-12-29 04:27:37 +01:00
bors
d75f48e04d Auto merge of #80449 - m-ou-se:rollup-kp2e5n8, r=m-ou-se
Rollup of 11 pull requests

Successful merges:

 - #80383 (clarify wrapping ptr arithmetic docs)
 - #80390 (BTreeMap: rename the area access methods)
 - #80393 (Add links to the source for the rustc and rustdoc books.)
 - #80398 (Use raw version of align_of in rc data_offset)
 - #80402 (Document `InferTy` & co.)
 - #80403 (fix: small typo error in chalk/mod.rs)
 - #80410 (rustdoc book: fix example)
 - #80419 (Add regression test for #80375)
 - #80430 (Add "length" as doc alias to len methods)
 - #80431 (Add "chr" as doc alias to char::from_u32)
 - #80448 (Fix stabilization version of deque_range feature.)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2020-12-29 00:16:54 +00:00
Tomasz Miąsko
5718cc2f9b Make forget intrinsic safe 2020-12-29 00:00:00 +00:00
Tyler Mandry
8041ccff2c
Add llvm-libunwind change to bootstrap CHANGELOG
From #77703.
2020-12-28 15:57:53 -08:00
Ralf Jung
4a90a58c34 make more matches exhaustive 2020-12-28 23:29:16 +01:00
Camelid
8d5dc8c2f0
Add missing commas to rustc_ast_pretty::pp docs 2020-12-28 14:23:20 -08:00
Simon Vandel Sillesen
0010fc8fec use exhaustive pattern match to prevent future bugs 2020-12-28 23:19:35 +01:00
Ralf Jung
c177e68015 merge two match'es for more exhaustiveness 2020-12-28 22:44:04 +01:00
Ralf Jung
122e91c4fb promotion: factor some common code into validate_ref 2020-12-28 22:09:08 +01:00
Arlie Davis
2f584229d4 Improvements to NatVis support
NatVis files describe how to display types in some Windows debuggers,
such as Visual Studio, WinDbg, and VS Code.

This commit makes several improvements:

* Adds visualizers for Rc<T>, Weak<T>, and Arc<T>.

* Changes [size] to [len], for consistency with the Rust API.
  Visualizers often use [size] to mirror the size() method on C++ STL
  collections.

* Several visualizers used the PVOID and ULONG typedefs. These are part
  of the Windows API; they are not guaranteed to always be defined in a
  pure Rust DLL/EXE. I converted PVOID to `void*` and `ULONG` to
  `unsigned long`.

* Cosmetic change: Removed {} braces around the visualized display
  for `Option` types. They now display simply as `Some(value)` or
  `None`, which reflects what is written in source code.

* The visualizer for `alloc::string::String` makes assumptions about
  the layout of `String` (it casts `String*` to another type), rather
  than using symbolic expressions. This commit changes the visualizer
  so that it simply uses symbolic expressions to access the string
  data and string length.
2020-12-28 12:14:49 -08:00
Mara Bos
e3d26e007c
Rollup merge of #80448 - m-ou-se:deque-range-version, r=m-ou-se
Fix stabilization version of deque_range feature.

See https://github.com/rust-lang/rust/pull/79022#issuecomment-751315315
2020-12-28 19:09:35 +00:00
Mara Bos
5a081620b0
Rollup merge of #80431 - xfix:add-chr-as-doc-alias, r=steveklabnik
Add "chr" as doc alias to char::from_u32

Many programming languages provide a function called `chr` - Perl, Python, PHP, Visual Basic, SQL. This change makes `char::from_u32` easier to discover in the documentation.

`ord` is not added as its name conflicts with `Ord` trait, and it's not exactly clear what it could point to (`<u32 as From<char>>::from`?). I don't think it's exactly necessary, as `char::from_u32` documentation page says you can do reverse conversion with `as` operator anyway.
2020-12-28 19:09:34 +00:00
Mara Bos
e351a3b2ec
Rollup merge of #80430 - xfix:add-length-as-doc-alias, r=steveklabnik
Add "length" as doc alias to len methods

Currently when searching for `length` there are no results: https://doc.rust-lang.org/std/?search=length. This makes `len` methods appear when searching for `length`.
2020-12-28 19:09:32 +00:00
Mara Bos
a570928902
Rollup merge of #80419 - LeSeulArtichaut:80375-test-case, r=lcnr
Add regression test for #80375

This will also make sure that #80375 is handled if #79135 has to be reverted (which won't happen 🤞).

Closes #80375.
r? `@lcnr`
2020-12-28 19:09:31 +00:00
Mara Bos
7800c70fab
Rollup merge of #80410 - MarcoIeni:patch-1, r=jonas-schievink
rustdoc book: fix example

`lib.rs` file is created only if `--lib` flag is specified
2020-12-28 19:09:29 +00:00
Mara Bos
8b43932ae2
Rollup merge of #80403 - 0xflotus:patch-1, r=jyn514
fix: small typo error in chalk/mod.rs
2020-12-28 19:09:27 +00:00
Mara Bos
803b37597e
Rollup merge of #80402 - camelid:inferty-docs, r=matthewjasper
Document `InferTy` & co.

I finally figured out what `TyVid` means! The name is quite opaque, so I
decided to document it and related types.

I don't know that much about `InferTy` & co., but I was able to *infer*
( :) ) from the names and what I know generally about type inference to
add some basic documentation.
2020-12-28 19:09:25 +00:00
Mara Bos
7003537df6
Rollup merge of #80398 - CAD97:fix-80365, r=dtolnay
Use raw version of align_of in rc data_offset

This was missed in #73845 when switching to use the raw operators.
Fixes #80365
2020-12-28 19:09:24 +00:00
Mara Bos
bae6475443
Rollup merge of #80393 - ehuss:doc-git-link, r=jyn514
Add links to the source for the rustc and rustdoc books.

This adds a little icon in the upper-right corner of the books so that readers can find the source if they want to make changes or file issues. This is already included in several of the other books.
2020-12-28 19:09:22 +00:00
Mara Bos
255fde3f46
Rollup merge of #80390 - ssomers:btree_cleanup_slices_2, r=Mark-Simulacrum
BTreeMap: rename the area access methods

r? `@Mark-Simulacrum`
2020-12-28 19:09:20 +00:00
Mara Bos
9fdd95ff7c
Rollup merge of #80383 - RalfJung:wrapping-ptr-arithmetic, r=dtolnay
clarify wrapping ptr arithmetic docs

Fixes https://github.com/rust-lang/rust/issues/80306

`@steffahn` please let me know if this helps avoid the misunderstanding. :)
2020-12-28 19:09:18 +00:00
bors
0d8a27a6f6 Auto merge of #6510 - alex-700:fix-ptr-arg-lint, r=llogiq
don't ignore expression after first not matched method call in PtrCloneVisitor

fixes #6509

changelog: none
2020-12-28 19:04:30 +00:00
Mara Bos
10d6ff71e8 Fix stabilization version of deque_range feature. 2020-12-28 20:04:27 +01:00
bors
2987785df3 Auto merge of #80439 - Dylan-DPC:rollup-rdxcvon, r=Dylan-DPC
Rollup of 11 pull requests

Successful merges:

 - #79662 (Move some more code out of CodegenBackend::{codegen_crate,link})
 - #79815 (Update RELEASES.md for 1.49.0)
 - #80284 (Suggest fn ptr rather than fn item and suggest to use `Fn` trait bounds rather than the unique closure type in E0121)
 - #80331 (Add more comments to trait queries)
 - #80344 (use matches!() macro in more places)
 - #80353 (BTreeMap: test split_off (and append) more thoroughly)
 - #80362 (Document rustc_macros on nightly-rustc)
 - #80399 (Remove FIXME in rustc_privacy)
 - #80408 (Sync rustc_codegen_cranelift)
 - #80411 (rustc_span: Remove `Symbol::with`)
 - #80434 (bootstrap: put the component name in the tarball temp dir path)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2020-12-28 15:57:50 +00:00
Dylan DPC
a4a59a0f17
Rollup merge of #80434 - pietroalbini:tarball-temp-dir, r=Mark-Simulacrum
bootstrap: put the component name in the tarball temp dir path

This should not matter right now, but if we ever parallelize rustbuild this will avoid tarball contents being merged together.

r? `@Mark-Simulacrum`
2020-12-28 14:13:23 +01:00
Dylan DPC
80934aba15
Rollup merge of #80411 - petrochenkov:nosymwith, r=matthewjasper
rustc_span: Remove `Symbol::with`

A subset of https://github.com/rust-lang/rust/pull/79425 that is a pure refactoring.
2020-12-28 14:13:21 +01:00
Dylan DPC
55b52ee339
Rollup merge of #80408 - bjorn3:sync_cg_clif-2020-12-27, r=bjorn3
Sync rustc_codegen_cranelift

The highlight of this sync are two JIT mode improvements. The first is that it is now possible to use JIT mode when using `-Zcodegen-backend` instead of the custom driver using `-Cllvm-args=mode=jit`. The second one is a new JIT mode that lazily compiles functions when they are called the first time: https://github.com/bjorn3/rustc_codegen_cranelift/pull/1120

In addition this includes a few small runtime performance improvements and various fixes for rustc changes that didn't cause compilation to fail.

r? ``@ghost``

``@rustbot`` label +A-codegen +A-cranelift +T-compiler
2020-12-28 14:13:19 +01:00
Dylan DPC
70b1a29b80
Rollup merge of #80399 - jyn514:hir-id-cleanup, r=marmeladema
Remove FIXME in rustc_privacy

#71104 has been fixed.

r? ``@marmeladema`` if you have time, otherwise ``@petrochenkov``
2020-12-28 14:13:17 +01:00