Skip to content

Conversation

@joe-p
Copy link
Contributor

@joe-p joe-p commented Nov 9, 2025

"msg" adds noise to expect and crossbeam's Sender. "op" adds noise to map_err. There's probably more instance of each, but I noticed these all in one snippet:

CleanShot 2025-11-09 at 18 19 52

"msg" adds noise to `expect` and crossbeam's `Sender`. "op" adds noise
to `map_err`
@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Nov 9, 2025
@joe-p joe-p changed the title feat: hide "msg" and "op" parameter names Add "msg" and "op" to hidden inlay parameter names Nov 9, 2025
@ChayimFriedman2
Copy link
Contributor

I'm not enthusiast to add new names to the exclusion. op is pretty generic, and also used in the standard library, so I guess it is fine. However msg could provide extra information plus it's not used in std, as such I'd prefer not to add it.

@joe-p
Copy link
Contributor Author

joe-p commented Nov 10, 2025

However msg could provide extra information plus it's not used in std, as such I'd prefer not to add it.

msg is used by core::result::Result::expect. Since these are only hidden for unary functions I personally think msg is along the same lines as value in terms of significance.

That being said, if the consensus is to just have op I can make that change, but wanted to make the case for msg

@ChayimFriedman2
Copy link
Contributor

Makes sense.

Thanks!

@ChayimFriedman2 ChayimFriedman2 added this pull request to the merge queue Nov 10, 2025
Merged via the queue into rust-lang:master with commit 260f94c Nov 10, 2025
15 checks passed
@rustbot rustbot removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Nov 10, 2025
@lnicola lnicola changed the title Add "msg" and "op" to hidden inlay parameter names minor: Add "msg" and "op" to hidden inlay parameter names Nov 10, 2025
lnicola pushed a commit to lnicola/rust-analyzer that referenced this pull request Nov 11, 2025
Add "msg" and "op" to hidden inlay parameter names
lnicola pushed a commit to lnicola/rust-analyzer that referenced this pull request Nov 11, 2025
Add "msg" and "op" to hidden inlay parameter names
lnicola pushed a commit to lnicola/rust-analyzer that referenced this pull request Nov 15, 2025
Add "msg" and "op" to hidden inlay parameter names
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants