Commit ddd6a30
authored
[ty] Do not suggest argument completion when at value of keyword argument (#24669)
In the following situation:
```python
def foo(y_true,y_pred): ...
y_true = 1
y_pred = 2
foo(y_true=y<CURSOR>)
```
the completion suggestions began with `y_true=` and `y_pred=`. But it is
never the right thing to suggest an argument completion (i.e.
`something=`) when the cursor is at the _value_ of a keyword argument.
So this PR introduces an early exit to the logic for deciding to suggest
arguments.1 parent 9282e61 commit ddd6a30
1 file changed
Lines changed: 29 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1411 | 1411 | | |
1412 | 1412 | | |
1413 | 1413 | | |
| 1414 | + | |
| 1415 | + | |
| 1416 | + | |
| 1417 | + | |
| 1418 | + | |
| 1419 | + | |
| 1420 | + | |
1414 | 1421 | | |
1415 | 1422 | | |
1416 | 1423 | | |
| |||
8733 | 8740 | | |
8734 | 8741 | | |
8735 | 8742 | | |
| 8743 | + | |
| 8744 | + | |
| 8745 | + | |
| 8746 | + | |
| 8747 | + | |
| 8748 | + | |
| 8749 | + | |
| 8750 | + | |
| 8751 | + | |
| 8752 | + | |
| 8753 | + | |
| 8754 | + | |
| 8755 | + | |
| 8756 | + | |
| 8757 | + | |
| 8758 | + | |
| 8759 | + | |
| 8760 | + | |
| 8761 | + | |
| 8762 | + | |
| 8763 | + | |
| 8764 | + | |
8736 | 8765 | | |
8737 | 8766 | | |
8738 | 8767 | | |
| |||
0 commit comments