Commit Graph

25669 Commits

Author SHA1 Message Date
bors
0841a84935 Auto merge of #15184 - HKalbasi:mir, r=HKalbasi
Disable mir interpreter for targets with different pointer size from host

fix #15182
2023-06-30 17:53:11 +00:00
hkalbasi
45828cdb54 Disable mir interpreter for targets with different pointer size from host 2023-06-30 21:21:52 +03:30
bors
76bcd9946a Auto merge of #15169 - lowr:patch/impl-header-anon-lifetime, r=HKalbasi
Use anonymous lifetime where possible

Because anonymous lifetimes are *super* cool.

More seriously, I believe anonymous lifetimes, especially those in impl headers, reduce cognitive load to a certain extent because they usually signify that they are not relevant in the signature of the methods within (or that we can apply the usual lifetime elision rules even if they are relevant).
2023-06-30 16:57:20 +00:00
Ryo Yoshida
5db0e1a346
Restructure ImportMap collection 2023-07-01 00:18:23 +09:00
Ryo Yoshida
2b106648a7
Only store item name instead of full path 2023-07-01 00:17:57 +09:00
bors
7a3991a544 Auto merge of #15180 - alibektas:15176, r=Veykril
Purge of unwraps

Removes unnecessary unwraps that I have overlooked in #15101 ( fixes #15176 )
2023-06-30 14:46:49 +00:00
Ryo Yoshida
860628af7c
Remove SearchMode:Contains
Also micro-optimizes fuzzy search.
2023-06-30 23:37:23 +09:00
Ryo Yoshida
8cd4e9f7ec
Merge assoc_items_only and exclude_import_kinds into assoc_mode 2023-06-30 23:37:10 +09:00
Ryo Yoshida
97b725e269
Remove name_only from import map query 2023-06-30 23:35:55 +09:00
Ali Bektas
cfbeb66a63 Purge of unwrap version 2 2023-06-30 16:31:20 +02:00
Ali Bektas
72aeaef5f3 Purge of unwraps 2023-06-30 15:47:17 +02:00
bors
f96442aa90 Auto merge of #15177 - rust-lang:Veykril-patch-1, r=Veykril
Fix panic in `handle_code_action`

🤞 that CI is happy with this, edited this via github
2023-06-30 06:56:21 +00:00
Lukas Wirth
7e7f401a81
Fix panic in handle_code_action 2023-06-30 08:42:46 +02:00
Lukas Wirth
60d046f567
Fix panic in handle_code_action 2023-06-30 08:38:44 +02:00
bors
d597369253 Auto merge of #15175 - lnicola:cross-env, r=Veykril
internal: Drop `cross-env` npm dep
2023-06-30 06:35:09 +00:00
Laurențiu Nicola
477a75d671 Drop cross-env npm dep 2023-06-30 09:20:02 +03:00
bors
40b2a68381 Auto merge of #15174 - tetsuharuohzeki:switch-to-use-vscode-vcse, r=Veykril
editor/code: Switch to `@vscode/vsce`

This follows up https://github.com/rust-lang/rust-analyzer/pull/15151

`vsce` was renamed to ``@vscode/vsce`.` We should switch to it now.

- https://code.visualstudio.com/updates/v1_74#_extension-authoring
- https://www.npmjs.com/package/`@vscode/vsce`
2023-06-30 05:48:47 +00:00
Tetsuharu Ohzeki
0500b1d5f8 editor/code: Switch to @vscode/vsce
`vsce` was renamed to `@vscode/vsce`.
We should switch to it now.

- https://code.visualstudio.com/updates/v1_74#_extension-authoring
- https://www.npmjs.com/package/@vscode/vsce
2023-06-30 09:55:43 +09:00
bors
769c80dc62 Auto merge of #15173 - HKalbasi:mir, r=HKalbasi
Fix data layout of reference to nested unsized structs
2023-06-29 20:25:42 +00:00
hkalbasi
302bb3c871 Fix data layout of reference to nested unsized structs 2023-06-29 23:38:13 +03:30
bors
b9c3d091ca Auto merge of #15172 - HKalbasi:mir, r=HKalbasi
Support #[derive_const(Trait)]

This is a nightly feature used in the standard library.
2023-06-29 18:17:21 +00:00
hkalbasi
f53f9230f0 Support #[derive_const(Trait)] 2023-06-29 20:58:35 +03:30
Ryo Yoshida
4e793e7859
Use anonymous lifetime where possible 2023-06-29 23:27:28 +09:00
bors
70a01fead5 Auto merge of #15168 - HKalbasi:mir, r=HKalbasi
Fix realloc problem in allocating smaller amounts
2023-06-29 13:59:52 +00:00
hkalbasi
2272803330 Fix realloc problem in allocating smaller amounts 2023-06-29 17:28:48 +03:30
bors
d7f4c21950 Auto merge of #15138 - mohsen-alizadeh:13583-rename-runnableEnv-to-runnables-extraEnv, r=Veykril
13583 rename runnable env to runnables extra env

closes #13583
2023-06-29 07:18:57 +00:00
Mohsen Alizadeh
3f70117d69 fallback to old key 2023-06-28 21:24:28 -07:00
bors
ad434fc4ac Auto merge of #15157 - HKalbasi:tokio-test, r=HKalbasi
Fix runnable detection for `#[tokio::test]`

fix #15141

It is hacky, and it wouldn't work for e.g. this case:
```Rust
use ::core::prelude;

#[prelude::v1::test]
fn foo() {
}
```
But it works for the tokio case. We should use the name resolution here somehow, and after that we should probably also get rid of the ast based `test_related_attribute` function.
2023-06-28 20:02:00 +00:00
hkalbasi
7901538dc8 Fix runnable detection for #[tokio::test] 2023-06-28 23:31:08 +03:30
bors
38dd674eab Auto merge of #15163 - NanthR:fix-ci, r=lnicola
fix(metrics): Push to master branch
2023-06-28 17:43:45 +00:00
Raghul Nanth A
eb85c8f70b
fix(metrics): Push to master branch 2023-06-28 23:11:35 +05:30
bors
ae89ca3fbb Auto merge of #15161 - lowr:patch/fixture-metadata-library, r=Veykril
internal: add `library` fixture meta

Currently, there is no way to specify `CrateOrigin` of a file fixture ([this] might be a bug?). This PR adds `library` meta to explicitly specify the fixture to be `CrateOrigin::Library` and also makes sure crates that belong to a library source root are set `CrateOrigin::Library`.

(`library` isn't really the best name. It essentially means that the crate is outside workspace but `non_workspace_member` feels a bit too long. Suggestions for the better name would be appreciated)

Additionally:
- documents the fixture meta syntax as thoroughly as possible
- refactors relevant code

[this]: 4b06d3c595/crates/base-db/src/fixture.rs (L450)
2023-06-28 15:23:32 +00:00
bors
ac4e046c69 Auto merge of #15030 - NanthR:parallel-metrics, r=HKalbasi
ci(metrics): Run measurement functions in parallel

Resolves #14853
2023-06-28 15:02:51 +00:00
Ryo Yoshida
d51536c242
Add library fixture meta
Additionally documents the syntax for fixture meta.
2023-06-28 22:34:14 +09:00
Raghul Nanth A
cf34df020d fix(metrics): Add repo check 2023-06-28 18:13:24 +05:30
bors
4b06d3c595 Auto merge of #15148 - lowr:fix/super-nameres-in-block, r=Veykril
Fix `self` and `super` path resolution in block modules

This PR fixes `self` and `super` path resolution with block modules involved.

Previously, we were just going up the module tree count-of-`super` times without considering block modules in the way, and then if we ended up in a block `DefMap`, we adjust "to the containing crate-rooted module". While this seems to work in most real-world cases, we failed to resolve them within peculiar module structures.

`self` and `super` should actually be resolved to the nearest non-block module, and the paths don't necessarily resolve to a crate-rooted module. This PR makes sure every `self` and `super` segment in paths are resolved to a non-block module.
2023-06-28 10:43:56 +00:00
Ali Bektas
20c877a700 Update crates/ide-assists/src/handlers/generate_trait_from_impl.rs
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2023-06-28 12:38:54 +02:00
bors
77ccd64326 Auto merge of #15136 - mohsen-alizadeh:13908-delete-matching-brace-key-binding, r=Veykril
delete matching brace key binding

closes #13908
2023-06-28 10:28:01 +00:00
bors
021604431c Auto merge of #15125 - lowr:patch/rustc_coinductive, r=Veykril
internal: support `#[rustc_coinductive]`

rust-lang/rust#100386 changed the trait solver so that `Sized` is treated as coinductive trait, just like auto traits. This is now controlled by the perma-unstable `#[rustc_coinductive]` attribute (rust-lang/rust#108033), which this PR adds support for.

In practice, I don't think this matters much if at all. Currently we don't give chalk enough information so chalk cannot precisely (dis)prove `Sized` bounds.
2023-06-28 10:13:31 +00:00
bors
891331c74f Auto merge of #15101 - alibektas:14780, r=Veykril
Check Workspace Edit ResourceOps

PR fixes #14780
2023-06-28 09:57:54 +00:00
Lukas Wirth
f8518a6cfa
Update crates/rust-analyzer/src/handlers/request.rs 2023-06-28 11:57:36 +02:00
bors
c10c6b4029 Auto merge of #15159 - tetsuharuohzeki:enable-noImplicitOverride, r=Veykril
editor/code: Enable `noImplicitOverride` ts option

This enables TypeScript's [`--noImplicitOverride`](https://www.typescriptlang.org/tsconfig#noImplicitOverride) option.
2023-06-28 08:46:38 +00:00
Tetsuharu Ohzeki
8e0efbc2a7 editor/code: Enable noImplicitOverride ts option 2023-06-28 17:40:27 +09:00
bors
89d7056151 Auto merge of #15154 - tetsuharuohzeki:tsconfig-strictest, r=lnicola
editor/code: Use `@tsconfig/strictest` to define type checking rules

Motivation
-----------

This change aims to make it easier to manage tsconfig by [``@tsconfig/strictest`](https://www.npmjs.com/package/@tsconfig/strictest)` and intend to leave to create "ideal" rules about TypeScript's type checking.

Implementation
---------------

This change removes some duplicated rules defined in ``@tsconfig/strictest`` and add disabing some strict rules that fails with the current codebase.
2023-06-28 08:09:55 +00:00
bors
b2ddf14d93 Auto merge of #15153 - tetsuharuohzeki:cleanup-activationEvents, r=lnicola
Clean up `activationEvents` field in vscode extension's package.json

By documents, VSCode v1.74 or later activates the extension automatically according to other configurations.

See:
- https://code.visualstudio.com/api/references/activation-events#onLanguage
    - https://code.visualstudio.com/docs/languages/identifiers
- https://code.visualstudio.com/api/references/activation-events#onCommand
    - https://code.visualstudio.com/api/references/contribution-points#contributes.commands
2023-06-28 07:54:46 +00:00
Tetsuharu Ohzeki
0ddf8b63e9 editor/code: Use @tsconfig/strictest to define type checking rules
Motivation
-----------

This change aims to make it easier to manage tsconfig.
This intend to leave to create "ideal" rules about TypeScript's type checking.

Implementation
---------------

This change removes some duplicated rules defined in `@tsconfig/strictest` and add disabing some strict rules
that fails with the current codebase.
2023-06-28 03:05:04 +09:00
Tetsuharu Ohzeki
682f90cc16 Clean up activationEvents in vscode extension's package.json
By documents, VSCode v1.74 or later activates extension automatically
according to other configurations.

See:
- https://code.visualstudio.com/api/references/activation-events#onLanguage
    - https://code.visualstudio.com/docs/languages/identifiers
- https://code.visualstudio.com/api/references/activation-events#onCommand
    - https://code.visualstudio.com/api/references/contribution-points#contributes.commands
2023-06-28 02:38:06 +09:00
bors
7c8ae35648 Auto merge of #15151 - tetsuharuohzeki:update-deps-code-ext, r=lnicola
Update dependencies for editor/code

This updates dependencies except ``@types/node`.`
2023-06-27 17:12:46 +00:00
Ali Bektas
677151e4e1 Version 1 2023-06-27 18:03:36 +02:00
Tetsuharu Ohzeki
1b228f9a6f Update @types/vscode to v1.78
- https://code.visualstudio.com/updates/v1_67
- https://code.visualstudio.com/updates/v1_68
- https://code.visualstudio.com/updates/v1_69
- https://code.visualstudio.com/updates/v1_70
- https://code.visualstudio.com/updates/v1_71
- https://code.visualstudio.com/updates/v1_72
- https://code.visualstudio.com/updates/v1_73
- https://code.visualstudio.com/updates/v1_74
- https://code.visualstudio.com/updates/v1_75
- https://code.visualstudio.com/updates/v1_76
- https://code.visualstudio.com/updates/v1_77
- https://code.visualstudio.com/updates/v1_78
2023-06-27 23:40:50 +09:00