Commit Graph

25908 Commits

Author SHA1 Message Date
bors
81744506ca Auto merge of #15302 - lnicola:sync-from-rust, r=lnicola
minor: Sync from rust
2023-07-17 13:10:31 +00:00
Laurențiu Nicola
71499fcd22 Merge remote-tracking branch 'upstream/master' into sync-from-rust 2023-07-17 16:09:39 +03:00
bors
d824511039 Auto merge of #15297 - HKalbasi:mir, r=HKalbasi
Normalize type alias in projected_ty

fix #15143
2023-07-16 21:47:00 +00:00
hkalbasi
832eb0d94c Normalize type alias in projected_ty 2023-07-17 01:16:26 +03:30
bors
ca797d2f88 Auto merge of #15295 - bernardosulzbach:fix-ssr-help-message, r=lnicola
Fix rust-analzyer ssr help message

It's missing a `>`, so

```
> rust-analyzer ssr '''$a.foo($b) ==> bar($a, $b)'''
can't parse `rule`, Parse error: Cannot find delimiter `==>>`
```

happens.
2023-07-16 10:21:07 +00:00
Bernardo Sulzbach
0e2c68da64
Fix rust-analzyer ssr help message 2023-07-16 12:12:33 +02:00
bors
bc0628c9b4 Auto merge of #15292 - kberov:patch-1, r=lnicola
Update flags.rs

Fixed typo in documentation comment
2023-07-16 07:33:53 +00:00
Красимир Беров
8f169f9642
Update flags.rs
Fixed typo in documentation comment
2023-07-16 10:27:20 +03:00
bors
4fad3301b1 Auto merge of #15280 - lnicola:bump-rust-version, r=lnicola
minor: Bump rust-version to 1.70 and use the workspace one in xtask

CC https://github.com/rust-lang/rust-analyzer/issues/15279
2023-07-16 06:50:43 +00:00
bors
f4b5c7c8bd Auto merge of #15291 - rust-lang:revert-15288-15143, r=lnicola
Revert "Handle TyAlias in projected_ty"

Reverts rust-lang/rust-analyzer#15288
2023-07-16 06:36:33 +00:00
Laurențiu Nicola
467f5f418e
Revert "Handle TyAlias in projected_ty" 2023-07-16 09:34:35 +03:00
bors
996e054f1e Auto merge of #15288 - alibektas:15143, r=lnicola
Handle TyAlias in projected_ty

First of all I still have no idea how MIR works but #15143 has been an issue that constantly made RA crash so I have been looking for a way to make RA stop panicking. I have zero claims that what I want to merge has any sense or is correct 😄  but there isn't any more panicking. Even if it is wrong may this be at least a step towards resolving this issue.
As is customary this PR fixes #15143
2023-07-15 17:14:13 +00:00
Ali Bektas
f8f19c4288 Change names to sth more presentable 2023-07-15 19:04:59 +02:00
Ali Bektas
75f06ce1fb Handle TyAlias in projected_ty 2023-07-15 18:32:21 +02:00
Ryo Yoshida
004971f3f0
Remove crate visibility modifier 2023-07-16 00:01:11 +09:00
bors
789dfd2a25 Auto merge of #15284 - HKalbasi:mir, r=HKalbasi
Enable cfg miri in analysis
2023-07-14 19:30:35 +00:00
hkalbasi
41b8b0b77d Enable cfg miri in analysis 2023-07-14 22:59:46 +03:30
bors
8e5f944317 Auto merge of #15282 - HKalbasi:mir, r=HKalbasi
Give real discriminant_type to chalk
2023-07-14 16:46:35 +00:00
hkalbasi
50559118fb Give real discriminant_type to chalk 2023-07-14 20:15:18 +03:30
hkalbasi
5208bf8f55 implement type_name intrinsic 2023-07-14 16:52:36 +03:30
Laurențiu Nicola
424da10077 Bump rust-version to 1.70 and use the workspace one in xtask 2023-07-14 16:15:26 +03:00
bors
c7ce8add14 Auto merge of #15265 - tetsuharuohzeki:update-dependencies, r=lnicola
editor/code: Update dependencies

This includes:

- Some major changes.
    - [typescript-eslint v6](https://typescript-eslint.io/blog/announcing-typescript-eslint-v6/)
    - [prettier v3](https://prettier.io/blog/2023/07/05/3.0.0.html)
- ~Update ``@types/vscode`` to [1.79](https://code.visualstudio.com/updates/v1_79).~
    - ~[1.80 has been released](https://code.visualstudio.com/updates/v1_80). We can now bump it.~
    - _Update1: I removed this change. See the below comments_
- and some patch/minor updates.
2023-07-13 16:06:42 +00:00
Tetsuharu Ohzeki
085b755123 editor/code: Update esbuild
https://github.com/evanw/esbuild/blob/main/CHANGELOG.md
2023-07-13 22:46:15 +09:00
Tetsuharu Ohzeki
d534180b30 editor/code: Update ESLint
https://eslint.org/blog/category/release-notes/
2023-07-13 22:45:11 +09:00
Tetsuharu Ohzeki
837ded9c9a editor/code: Update ovsx
https://github.com/eclipse/openvsx/blob/master/cli/CHANGELOG.md
2023-07-13 22:45:10 +09:00
Tetsuharu Ohzeki
f7823f3106 editor/code: Re-apply code format 2023-07-13 22:44:29 +09:00
Tetsuharu Ohzeki
9d06aa55b4 editor/code: Update prettier to v3
https://prettier.io/blog/2023/07/05/3.0.0.html
2023-07-13 22:44:29 +09:00
Tetsuharu Ohzeki
eed1888b81 editor/code: Update typescript-eslint to v6
https://typescript-eslint.io/blog/announcing-typescript-eslint-v6/
2023-07-13 22:44:29 +09:00
Tetsuharu Ohzeki
143646d17e editor/code: Update typescript 2023-07-13 22:44:29 +09:00
bors
6acb989448 Auto merge of #15275 - Veykril:ci-metrics, r=Veykril
Default to stable toolchain for metrics workflow

Metrics CI is failing because of a function that was stabilized in 1.70. So for some reason, it's trying to use an older toolchain i seems though I don't understand why it randomly started complaining about that.
2023-07-13 08:55:21 +00:00
Lukas Wirth
415b527855 Default to stable toolchain for metrics workflow 2023-07-13 10:54:24 +02:00
bors
f6ae0c11ac Auto merge of #15270 - ChristianSchott:patch-1, r=HKalbasi
Make fields of mir::Terminator public

When trying to use the RA crate, I am unable to access the fields in `hir_def::mir::Terminator`.
I don't see any reason, why these should be private, especially as the fields of `hir_def::mir::Statement` are `pub`.

I am not sure if the fields in `hir_def::mir::SwitchTargets` should be made `pub` too, but at least they are read-accessible via some public methods..

Sorry if I missed something, this is my first PR.
2023-07-13 07:54:44 +00:00
bors
132ba2cf77 Auto merge of #15248 - Veykril:eager, r=Veykril
Fix eager token mapping panics
2023-07-13 07:39:30 +00:00
Lukas Wirth
6a7b905c86 Fix the eager token maps by re-mapping the textranges between the input and input expansion 2023-07-13 09:22:38 +02:00
bors
215b149a8b Auto merge of #15272 - lnicola:links, r=lnicola
minor: Use a permalink to the SIMD line index code, and add a note on the GitHub API
2023-07-12 23:34:43 +00:00
bors
d16d5fcf68 Auto merge of #15268 - HKalbasi:mir, r=HKalbasi
Add write_bytes and ctlz intrinsics
2023-07-12 23:19:30 +00:00
bors
642420fb60 Auto merge of #15267 - lowr:patch/exceeding-exec-limit-is-slow, r=lnicola
Mark test for MIR execution limit as slow test

The test for MIR execution limit accounts for ~2/3 of total execution time of non-slow hir-ty tests. It significantly slows down edit-and-run-test type of workflow. Can we mark it as a slow test?
2023-07-12 23:04:16 +00:00
bors
584dca4a35 Auto merge of #15266 - tetsuharuohzeki:cleanup-editor-config, r=lnicola
Set .editorconfig default indent size to `4`

We uses `indent_size = 4` for almost files in this repository. This sorts the config to it.
2023-07-12 22:45:28 +00:00
bors
da02dc8a47 Auto merge of #15264 - rust-lang:dependabot/npm_and_yarn/editors/code/semver-5.7.2, r=lnicola
Bump semver from 5.7.1 to 5.7.2 in /editors/code

Bumps [semver](https://github.com/npm/node-semver) from 5.7.1 to 5.7.2.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/npm/node-semver/releases">semver's releases</a>.</em></p>
<blockquote>
<h2>v5.7.2</h2>
<h2><a href="https://github.com/npm/node-semver/compare/v5.7.1...v5.7.2">5.7.2</a> (2023-07-10)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><a href="2f8fd41487"><code>2f8fd41</code></a> <a href="https://redirect.github.com/npm/node-semver/pull/585">#585</a> better handling of whitespace (<a href="https://redirect.github.com/npm/node-semver/issues/585">#585</a>) (<a href="https://github.com/joaomoreno"><code>`@​joaomoreno</code></a>,` <a href="https://github.com/lukekarrys"><code>`@​lukekarrys</code></a>)</li>`
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/npm/node-semver/blob/v5.7.2/CHANGELOG.md">semver's changelog</a>.</em></p>
<blockquote>
<h2><a href="https://github.com/npm/node-semver/compare/v5.7.1...v5.7.2">5.7.2</a> (2023-07-10)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><a href="2f8fd41487"><code>2f8fd41</code></a> <a href="https://redirect.github.com/npm/node-semver/pull/585">#585</a> better handling of whitespace (<a href="https://redirect.github.com/npm/node-semver/issues/585">#585</a>) (<a href="https://github.com/joaomoreno"><code>`@​joaomoreno</code></a>,` <a href="https://github.com/lukekarrys"><code>`@​lukekarrys</code></a>)</li>`
</ul>
<h2>5.7</h2>
<ul>
<li>Add <code>minVersion</code> method</li>
</ul>
<h2>5.6</h2>
<ul>
<li>Move boolean <code>loose</code> param to an options object, with
backwards-compatibility protection.</li>
<li>Add ability to opt out of special prerelease version handling with
the <code>includePrerelease</code> option flag.</li>
</ul>
<h2>5.5</h2>
<ul>
<li>Add version coercion capabilities</li>
</ul>
<h2>5.4</h2>
<ul>
<li>Add intersection checking</li>
</ul>
<h2>5.3</h2>
<ul>
<li>Add <code>minSatisfying</code> method</li>
</ul>
<h2>5.2</h2>
<ul>
<li>Add <code>prerelease(v)</code> that returns prerelease components</li>
</ul>
<h2>5.1</h2>
<ul>
<li>Add Backus-Naur for ranges</li>
<li>Remove excessively cute inspection methods</li>
</ul>
<h2>5.0</h2>
<ul>
<li>Remove AMD/Browserified build artifacts</li>
<li>Fix ltr and gtr when using the <code>*</code> range</li>
<li>Fix for range <code>*</code> with a prerelease identifier</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="f8cc313550"><code>f8cc313</code></a> chore: release 5.7.2</li>
<li><a href="2f8fd41487"><code>2f8fd41</code></a> fix: better handling of whitespace (<a href="https://redirect.github.com/npm/node-semver/issues/585">#585</a>)</li>
<li><a href="deb5ad51bf"><code>deb5ad5</code></a> chore: <code>`@​npmcli/template-oss</code><a` href="https://github.com/4"><code>`@​4</code></a>.16.0</li>`
<li>See full diff in <a href="https://github.com/npm/node-semver/compare/v5.7.1...v5.7.2">compare view</a></li>
</ul>
</details>
<details>
<summary>Maintainer changes</summary>
<p>This version was pushed to npm by <a href="https://www.npmjs.com/~lukekarrys">lukekarrys</a>, a new releaser for semver since your current version.</p>
</details>
<br />

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=semver&package-manager=npm_and_yarn&previous-version=5.7.1&new-version=5.7.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting ``@dependabot` rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- ``@dependabot` rebase` will rebase this PR
- ``@dependabot` recreate` will recreate this PR, overwriting any edits that have been made to it
- ``@dependabot` merge` will merge this PR after your CI passes on it
- ``@dependabot` squash and merge` will squash and merge this PR after your CI passes on it
- ``@dependabot` cancel merge` will cancel a previously requested merge and block automerging
- ``@dependabot` reopen` will reopen this PR if it is closed
- ``@dependabot` close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- ``@dependabot` ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- ``@dependabot` ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- ``@dependabot` ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/rust-lang/rust-analyzer/network/alerts).

</details>
2023-07-12 22:30:09 +00:00
bors
f45fdd9123 Auto merge of #15260 - DropDemBits:structured-snippet-migrate-3, r=lowr
internal: Migrate assists to the structured snippet API, part 3

Continuing from #15231

Migrates the following assists:
- `add_missing_match_arms`
- `fix_visibility`
- `promote_local_to_const`

The `add_missing_match_arms` changes are best reviewed commit-by-commit since they're relatively big changes compared to the rest of the commits.
2023-07-12 22:05:30 +00:00
DropDemBits
614987ae71
Test rendering of snippets
Had a missing ':' between the snippet index and placeholder text
2023-07-12 17:22:02 -04:00
Laurențiu Nicola
a2b159dcc6 Use a permalink to the SIMD line index code, and add a note on the GitHub API 2023-07-12 20:51:20 +03:00
Ryo Yoshida
074488b290
Properly infer types with type casts 2023-07-13 00:14:15 +09:00
ChristianSchott
8f612b5352
Make fields of mir::Terminator public 2023-07-12 09:35:44 +02:00
DropDemBits
a1877df5a5
Passthrough is_snippet for non-structured snippets
Structured snippets precisely track which text edits need to be marked
as snippet text edits, but the cases where structured snippets aren't
used but snippets are still present are for simple single text-edit
changes, so it's perfectly fine to mark all one of them as being a
snippet text edit
2023-07-12 03:14:09 -04:00
DropDemBits
a3a02d01f3
Simplify snippet rendering
Also makes sure that stray placeholders get converted into tabstops
2023-07-12 02:58:32 -04:00
DropDemBits
ae83f32ee9
Remove unnecessary SourceChange trait impls 2023-07-12 02:36:37 -04:00
DropDemBits
97a6fa58cd
internal: Defer rendering of structured snippets
This ensures that any assist using structured snippets won't
accidentally remove bits interpreted as snippet bits.
2023-07-12 01:50:35 -04:00
DropDemBits
89f7bf7411
Add SnippetEdit to be alongside source changes
Rendering of snippet edits is deferred to places using source change
2023-07-12 00:43:41 -04:00
dependabot[bot]
f0e2ad5a95
Bump semver from 5.7.1 to 5.7.2 in /editors/code
Bumps [semver](https://github.com/npm/node-semver) from 5.7.1 to 5.7.2.
- [Release notes](https://github.com/npm/node-semver/releases)
- [Changelog](https://github.com/npm/node-semver/blob/v5.7.2/CHANGELOG.md)
- [Commits](https://github.com/npm/node-semver/compare/v5.7.1...v5.7.2)

---
updated-dependencies:
- dependency-name: semver
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-11 22:02:42 +00:00