Improve display of interpreter implementation names (#3749)

e.g. instead of

```
❯ uv venv --python pypy@3.10
  × No interpreter found for pypy 3.10 in search path
```

we say

```
❯ uv venv --python pypy@3.10
  × No interpreter found for PyPy 3.10 in search path
```
This commit is contained in:
Zanie Blue 2024-05-22 14:22:09 -04:00 committed by GitHub
parent 845d788c91
commit d5ac2f53d3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -46,6 +46,9 @@ impl FromStr for ImplementationName {
impl Display for ImplementationName {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
f.write_str(self.as_str())
match self {
Self::CPython => f.write_str("CPython"),
Self::PyPy => f.write_str("PyPy"),
}
}
}