Niko Matsakis
ed73a3267a
address pnkfelix nits
2018-08-24 13:27:38 -04:00
Niko Matsakis
5778fec665
pacify the mercilous tidy: adt-nullary-enums test
2018-08-24 13:27:38 -04:00
Niko Matsakis
7c3654a722
pacify the mercilous tidy: adt user-ty
2018-08-24 13:27:38 -04:00
Niko Matsakis
fa787454c5
pacify the mercilous tidy: user-ty on rvalue assignments
2018-08-24 13:27:38 -04:00
Niko Matsakis
6f73127458
pacify the mercilous tidy: doc comment for is_identity
2018-08-24 13:27:38 -04:00
Niko Matsakis
beb3374b1c
pacify the mercilous tidy: canonical ignore comments
2018-08-24 13:27:38 -04:00
Niko Matsakis
f8653006d3
ufcs with annot in position 1 and 2
2018-08-24 13:27:38 -04:00
Niko Matsakis
05c1b89308
rename test case
...
the 3 is because the type arguments are in the 3rd position
2018-08-24 13:27:38 -04:00
Niko Matsakis
016ccf8e6e
include ADT user-ty in output
2018-08-24 13:27:38 -04:00
Niko Matsakis
e84db9bc1b
add test for method ufcs notation
2018-08-24 13:27:38 -04:00
Niko Matsakis
56506cfa25
support user-given types in adts
2018-08-24 13:27:38 -04:00
Niko Matsakis
2d1d3fef62
support user annotations in fns, methods
2018-08-24 13:27:38 -04:00
Niko Matsakis
5f1643d2ea
equate the user_ty
of a constant with its declared ty
2018-08-24 13:27:38 -04:00
Niko Matsakis
e23ad83fbc
add a user_ty
annotation to Constant
2018-08-24 13:27:38 -04:00
Niko Matsakis
d7d4d7c8d5
add a user_substs
table and store the annotations in there
2018-08-24 13:27:38 -04:00
Niko Matsakis
1884fe35b6
add a user_substs
map into the typeck tables
2018-08-24 13:27:38 -04:00
bors
727eabd681
Auto merge of #53662 - kennytm:rollup, r=kennytm
...
Rollup of 16 pull requests
Successful merges:
- #53311 (Window Mutex: Document that we properly initialize the SRWLock)
- #53503 (Discourage overuse of mem::forget)
- #53545 (Fix #50865 : ICE on impl-trait returning functions reaching private items)
- #53559 (add macro check for lint)
- #53562 (Lament the invincibility of the Turbofish)
- #53563 (use String::new() instead of String::from(""), "".to_string(), "".to_owned() or "".into())
- #53592 (docs: minor stylistic changes to str/string docs)
- #53594 (Update RELEASES.md to include clippy-preview)
- #53600 (Fix a grammatical mistake in "expected generic arguments" errors)
- #53614 (update nomicon and book)
- #53617 (tidy: Stop requiring a license header)
- #53618 (Add missing fmt examples)
- #53636 (Prefer `.nth(n)` over `.skip(n).next()`.)
- #53644 (Use SmallVec for SmallCStr)
- #53664 (Remove unnecessary closure in rustc_mir/build/mod.rs)
- #53666 (Added rustc_codegen_llvm to compiler documentation.)
2018-08-24 17:02:23 +00:00
kennytm
c6039de546
Rollup merge of #53666 - davidtwco:issue-51737, r=Mark-Simulacrum
...
Added rustc_codegen_llvm to compiler documentation.
Fixes #51737 .
2018-08-24 23:27:57 +08:00
kennytm
a1ec2f76bb
Rollup merge of #53545 - FelixMcFelix:fix-50865-beta, r=petrochenkov
...
Fix #50865 : ICE on impl-trait returning functions reaching private items
Adds a test case as suggested in #50865 , and implements @petrochenkov's suggestion. Fixes #50865 .
Impl-trait-returning functions are marked under a new (low) access level, which they propagate rather than `AccessLevels::Reachable`. `AccessLevels::is_reachable` returns false for such items (leaving stability analysis unaffected), these items may still be visible to the lints phase however.
2018-08-24 23:27:16 +08:00
bors
61b0072707
Auto merge of #53044 - SergioBenitez:stable-attr-literals, r=petrochenkov
...
Stabilize 'attr_literals' feature.
RFC Issue: rust-lang/rfcs#1559
Tracking Issue: rust-lang/rust#34981
Reference PR: https://github.com/rust-lang-nursery/reference/pull/388 .
2018-08-24 14:48:29 +00:00
Matthew Russo
79afc6e9e8
updates tests to use new error code
2018-08-24 08:51:25 -04:00
Matthew Russo
34e76375ce
Removing GenericArgMismatchErrorCode.
2018-08-24 08:50:00 -04:00
Matthew Russo
aa2abeaf34
Merging error code descriptions into E0107 and adding "no longer
...
emitted" messages to the others.
2018-08-24 08:49:56 -04:00
kennytm
62f29c4fb8
Rollup merge of #53664 - IsaacWoods:fix_53608, r=oli-obk
...
Remove unnecessary closure in rustc_mir/build/mod.rs
Fixes #53608
2018-08-24 19:29:59 +08:00
kennytm
0009fad435
Rollup merge of #53644 - llogiq:smallvec-for-small-c-str, r=estebank
...
Use SmallVec for SmallCStr
This reuses the awesome optimizations from Servo's `SmallVec` to speed up `SmallCStr`.
2018-08-24 19:24:45 +08:00
kennytm
9dfb95b11f
Rollup merge of #53636 - frewsxcv:frewsxcv-nth, r=rkruppe
...
Prefer `.nth(n)` over `.skip(n).next()`.
Found by clippy.
2018-08-24 19:24:44 +08:00
kennytm
a37b69da9f
Rollup merge of #53618 - GuillaumeGomez:fmt-examples, r=QuietMisdreavus
...
Add missing fmt examples
r? @QuietMisdreavus
2018-08-24 19:24:42 +08:00
kennytm
cf90fd04dc
Rollup merge of #53617 - joshtriplett:tidy-no-license-header, r=Mark-Simulacrum
...
tidy: Stop requiring a license header
Previously approved in rust-lang/rust#43498 ; update tidy to match.
2018-08-24 19:24:40 +08:00
kennytm
ff4500c389
Rollup merge of #53614 - RalfJung:nomicon, r=kennytm
...
update nomicon and book
2018-08-24 19:24:38 +08:00
kennytm
7d990fa7cd
Rollup merge of #53600 - varkor:expected-generic-arg-s, r=eddyb
...
Fix a grammatical mistake in "expected generic arguments" errors
r? @eddyb
2018-08-24 19:24:37 +08:00
kennytm
3fbd72e66b
Rollup merge of #53594 - rust-lang:Aaronepower-patch-1, r=Mark-Simulacrum
...
Update RELEASES.md to include clippy-preview
[Rendered](https://github.com/rust-lang/rust/blob/Aaronepower-patch-1/RELEASES.md#misc )
r? @Mark-Simulacrum
2018-08-24 19:24:35 +08:00
kennytm
c51903c73e
Rollup merge of #53592 - matthiaskrgr:str_doc, r=alexcrichton
...
docs: minor stylistic changes to str/string docs
std::string::String.repeat(): slightly rephrase to be more in-line with other descriptions.
add ticks around a few keywords in other descriptions.
2018-08-24 19:24:32 +08:00
bors
57e13babe9
Auto merge of #53653 - petrochenkov:moreregr, r=Mark-Simulacrum
...
Address two regressions
Remove assert checking that expansion data is immutable until I have time to investigate why it's firing, cc https://github.com/rust-lang/rust/issues/52363
Turn the error for module-relative access to macro-expanded `macro_export` macros into a deprecation lint, closes https://github.com/rust-lang/rust/issues/53495
2018-08-24 11:22:11 +00:00
David Wood
c802be6f30
Added rustc_codegen_llvm to compiler documentation.
2018-08-24 13:09:34 +02:00
Isaac Woods
b24a30e94d
Remove unnecessary closure in rustc_mir/build/mod.rs
2018-08-24 11:21:15 +01:00
Nicholas Nethercote
626b2987a9
Introduce UnionIntoIdxSet
and SubtractFromIdxSet
traits.
...
They let `union()`, `union_sparse()` and `union_hybrid()` be merged.
Likewise for subtract()`, `subtract_sparse()` and `subtract_hybrid()`.
2018-08-24 19:51:09 +10:00
Nicholas Nethercote
180052d5f7
Rename universe_size
as domain_size
.
...
Because `domain` is a more obvious term than `universe` for this
concept.
2018-08-24 19:51:09 +10:00
kennytm
d13c61208a
Rollup merge of #53563 - matthiaskrgr:String, r=varkor
...
use String::new() instead of String::from(""), "".to_string(), "".to_owned() or "".into()
2018-08-24 16:44:35 +08:00
kennytm
714e5b3c46
Rollup merge of #53562 - varkor:bastion-of-the-turbofish, r=nagisa
...
Lament the invincibility of the Turbofish
Here a test case is added to ensure that any others attempting to drive the Turbofish to extinction have second thoughts. Previously the [entire test suite would succeed](https://github.com/rust-lang/rust/pull/53511 ) if generic arguments were accepted without disambiguation, making for [confusing and heartbreaking circumstances](https://github.com/rust-lang/rfcs/pull/2527 ).
2018-08-24 16:44:34 +08:00
kennytm
7f396bad9e
Rollup merge of #53559 - Dylan-DPC:fix/missing-doc-lint, r=kennytm
...
add macro check for lint
Fixes #53537
2018-08-24 16:44:32 +08:00
kennytm
973428d522
Rollup merge of #53503 - kornelski:master, r=dtolnay
...
Discourage overuse of mem::forget
Some uses of `mem::forget` have been replaced by better methods of `Box`, so I've removed obsoleted use-cases from these docs.
I've removed emphasis on leaking, because it's not obvious `mem::forget` does not guarantee leaking of memory: memory of stack-allocated objects and values partially moved out of `Box` will still be freed. That's a potential error when used to pass objects to FFI, so it's better to direct users to `Box::into_raw` instead.
2018-08-24 16:44:31 +08:00
kennytm
ab5a71b034
Rollup merge of #53311 - RalfJung:windows-mutex, r=retep998
...
Window Mutex: Document that we properly initialize the SRWLock
See https://github.com/rust-lang/rust/issues/35836
2018-08-24 16:44:30 +08:00
Sergio Benitez
ed0bd38cac
Stabilize 'attr_literals' feature.
2018-08-23 19:06:07 -07:00
Vadim Petrochenkov
77f2a2fe35
Turn the error for module-relative access to macro-expanded macro_export
macros into a deprecation lint
2018-08-24 02:51:41 +03:00
Vadim Petrochenkov
7a8b726811
Add a test for reset expansion info
2018-08-24 02:50:34 +03:00
Vadim Petrochenkov
6fdb400ff2
Revert "hygiene: Make sure expansion info is set at most once for a given Mark
"
...
This reverts commit b15785b671
.
2018-08-24 02:21:52 +03:00
bors
63d66494af
Auto merge of #53638 - flip1995:clippy, r=nrc
...
Update clippy
r? @oli-obk @Manishearth
2018-08-23 22:52:29 +00:00
Guillaume Gomez
61fc7f18c3
Add struct keyword doc
2018-08-23 23:50:05 +02:00
flip1995
cd8fcb6140
Update clippy again
2018-08-23 23:31:55 +02:00
Andre Bogus
25a83e3a88
Use SmallVec for SmallCStr
2018-08-23 23:13:14 +02:00