TYP: Fix typehints for ExtensionDtype
This is a fix for type hints of `ExtensionDtype`. `register_extension_dtype` was confusing pyright autocomplete. It was fixed by parameterizing its return value on its input value.

Example:

```python
import pandas as pd

pd.CategoricalDtype(categories=['a', 'b'])
```

Before this change:
```console
$ pyright --version
pyright 1.1.133
$ pyright --lib pd.py
No configuration file found.
No pyproject.toml file found.
stubPath /home/omer/src/ext/typings is not a valid directory.
Assuming Python platform Linux
Searching for source files
Found 1 source file
/home/omer/src/ext/pd.py
  /home/omer/src/ext/pd.py:3:1 - error: Expected no arguments to "ExtensionDtype" constructor (reportGeneralTypeIssues)
1 error, 0 warnings, 0 infos
Completed in 0.72sec
```

After:
```console
$ pyright --lib ../pd.py
No configuration file found.
pyproject.toml file found at /home/omer/src/ext/pandas.
Loading pyproject.toml file at /home/omer/src/ext/pandas/pyproject.toml
Pyproject file "/home/omer/src/ext/pandas/pyproject.toml" is missing "[tool.pyright] section.
stubPath /home/omer/src/ext/pandas/typings is not a valid directory.
Assuming Python platform Linux
Searching for source files
Found 1 source file
0 errors, 0 warnings, 0 infos
Completed in 0.777sec
```