mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-27 04:19:13 +00:00
Merge #1154
1154: Initial support for lang items (and str completion) r=flodiebold a=marcogroppo This PR adds partial support for lang items. For now, the only supported lang items are the ones that target an impl block. Lang items are now resolved during type inference - this means that `str` completion now works. Fixes #1139. (thanks Florian Diebold for the help!) Co-authored-by: Marco Groppo <marco.groppo@gmail.com>
This commit is contained in:
commit
4ad2e4ce4e
11 changed files with 174 additions and 19 deletions
|
@ -1325,6 +1325,7 @@ impl ToOwned for ImplBlock {
|
|||
|
||||
|
||||
impl ast::TypeParamsOwner for ImplBlock {}
|
||||
impl ast::AttrsOwner for ImplBlock {}
|
||||
impl ImplBlock {
|
||||
pub fn item_list(&self) -> Option<&ItemList> {
|
||||
super::child_opt(self)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue