| Age | Commit message (Collapse) | Author | Lines |
|
|
|
Fix `unused_import_braces` lint false positive on `use prefix::{self as rename}`
|
|
|
|
|
|
|
|
Implement multiple patterns with `|` in `if let` and `while let` (RFC 2175)
cc https://github.com/rust-lang/rust/issues/48215
|
|
save-analysis: power through bracket mis-counts
Closes #47981
This is pretty unsatisfying since it is working around a span bug. However, I can't track down the span bug and it could be in the parser, proc macro expansion, the user macro, or Syn (or any other library that can manipulate spans). Given that user code can cause this error, I think we need to be more robust here.
r? @eddyb
|
|
|
|
|
|
|
|
Closes #47981
This is pretty unsatisfying since it is working around a span bug. However, I can't track down the span bug and it could be in the parser, proc macro expansion, the user macro, or Syn (or any other library that can manipulate spans). Given that user code can cause this error, I think we need to be more robust here.
|
|
|
|
save-analysis: avoid implicit unwrap
When looking up a field defintion, since the name might be incorrect in the field init shorthand case.
cc https://github.com/rust-lang-nursery/rls/issues/699
r? @eddyb
|
|
add documentation from doc(include) to analysis data
cc #44732
Currently save-analysis only loads docs from plain doc comments and doc attributes. Since `#[doc(include="filename.md")]` doesn't create a plain doc attribute when it loads the file, we need to be sure to pick up this info for the analysis data.
|
|
When looking up a field defintion, since the name might be incorrect in the field init shorthand case.
cc https://github.com/rust-lang-nursery/rls/issues/699
|
|
across suspension points to borrowck. Fixes #44197, #45259 and #45093.
|
|
|
|
No longer parse it.
Remove AutoTrait variant from AST and HIR.
Remove backwards compatibility lint.
Remove coherence checks, they make no sense for the new syntax.
Remove from rustdoc.
|
|
Use DefIndex encoding that works better with on-disk variable length integer representations.
Use the least instead of the most significant bit for representing the address space.
r? @eddyb
|
|
Fix nested imports not included in the save_analysis output
This PR fixes #46823.
The bug was caused by the old access level checking code, which checked against the root UseTree even for nested trees. The problem with that is, for nested trees the root is lowered as an empty `ListStem`, which is not reachable by definition. The new code computes the access level with each tree's own ID, and with the root tree's visibility.
I tested this manually and it works, but I'm not really satisfied with that. I looked at the existing tests though, and no one checked for the save_analysis output as far as I can see. How should I proceed with that? I think having a test about this would be really nice.
|
|
|
|
rustc::ty: Rename struct_variant to non_enum_variant
r? @eddyb
|
|
length integer encodings.
|
|
It is also intended for use with unions.
|
|
Upgrade `log` to `0.4` in multiple crates.
|
|
|
|
The Generics now contain one Vec of an enum for the generic parameters,
rather than two separate Vec's for lifetime and type parameters.
Additionally, places that previously used Vec<LifetimeDef> now use
Vec<GenericParam> instead.
|
|
|
|
|
|
|
|
|
|
|
|
This commit adds support for nested groups inside `use` declarations,
such as `use foo::{bar, sub::{baz::Foo, *}};`.
|
|
|
|
|
|
|
|
|
|
This just handles a missing entry, doesn't try to recover, because I couldn't actually find a test case.
cc https://github.com/rust-lang-nursery/rls/issues/558
|
|
closes https://github.com/nrc/rls-analysis/issues/117
|
|
Use the span we save in the PathSegment for a method call, rather than searching for it in the text.
Fixes https://github.com/nrc/rls-analysis/issues/111
|
|
|
|
Fix a bunch of minor save-analysis bugs
r? @eddyb
|
|
Adds an `IsAuto` field to `ItemTrait` which flags if the trait was
declared as an `auto trait`.
Auto traits cannot have generics nor super traits.
|
|
DefaultImpl is a highly confusing name for what we now call auto impls,
as in `impl Send for ..`. The name auto impl is not formally decided
but for sanity anything is better than `DefaultImpl` which refers
neither to `default impl` nor to `impl Default`.
|
|
save-analysis: support unions
r? @eddyb
|
|
Emit crate disambiguators in save-analysis data
Needed for https://github.com/nrc/rls-analysis/issues/93.
Blocked by https://github.com/nrc/rls-data/pull/11. (For now, this pulls my branch [rls-data/crate-source](https://github.com/Xanewok/rls-data/tree/crate-source))
This will allow to disambiguate different crates types/versions when indexing resulting save-analysis data (most importantly allow to support bin+lib and different crate versions).
r? @nrc
|
|
Fixes https://github.com/nrc/rls-analysis/issues/78
|
|
Fixes https://github.com/nrc/rls-analysis/issues/77
|
|
fixes https://github.com/nrc/rls-analysis/issues/52
|
|
This special cases the function type sugar in paths and deals with traits bounds as just the path parts. That required refactoring the path collector to distinguish between variable decls and references in patterns, basically just to please the borrow checker.
cc https://github.com/nrc/rls-analysis/issues/37
|