about summary refs log tree commit diff
path: root/compiler/rustc_llvm/llvm-wrapper
diff options
context:
space:
mode:
authorIvar Scholten <ivar.scholten@protonmail.com>2024-08-31 00:56:16 +0200
committerIvar Scholten <ivar.scholten@protonmail.com>2024-09-02 02:00:19 +0200
commit92b8b5676682fe8cc50b4145a6bd25075454d283 (patch)
treed697632b7061c8e9e3afd9e79e8341f247a94d23 /compiler/rustc_llvm/llvm-wrapper
parentc7f4874be017a7766fa7bccb5d421e4312ef3a82 (diff)
downloadrust-92b8b5676682fe8cc50b4145a6bd25075454d283.tar.gz
rust-92b8b5676682fe8cc50b4145a6bd25075454d283.zip
fix: use Result type aliases in "Wrap return type in Result" assist
This commit makes the "Wrap return type in Result" assist prefer type aliases of standard library
type when the are in scope, use at least one generic parameter, and have the name "Result".

The last restriction was made in an attempt to avoid false assumptions about which type the
user is referring to, but that might be overly strict. We could also do something like this, in
order of priority:

* Use the alias named "Result".
* Use any alias if only a single one is in scope, otherwise:
* Use the standard library type.

This is easy to add if others feel differently that is appropriate, just let me know.
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper')
0 files changed, 0 insertions, 0 deletions