[syntax-errors]: multiple-starred-expressions (F622) (#20243)

<!--
Thank you for contributing to Ruff/ty! To help us out with reviewing,
please consider the following:

- Does this pull request include a summary of the change? (See below.)
- Does this pull request include a descriptive title? (Please prefix
with `[ty]` for ty pull
  requests.)
- Does this pull request include references to any relevant issues?
-->

## Summary

This PR implements
https://docs.astral.sh/ruff/rules/multiple-starred-expressions/ as a
semantic syntax error

## Test Plan

 I have added inline tests as directed in #17412

---------

Signed-off-by: 11happy <soni5happy@gmail.com>
Co-authored-by: Brent Westbrook <36778786+ntBre@users.noreply.github.com>
This commit is contained in:
Bhuminjay Soni 2025-09-25 01:02:55 +05:30 committed by GitHub
parent 73b4b1ed17
commit e6073d0cca
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 783 additions and 20 deletions

View file

@ -0,0 +1,5 @@
(*a, *b) = (1, 2)
[*a, *b] = (1, 2)
(*a, *b, c) = (1, 2, 3)
[*a, *b, c] = (1, 2, 3)
(*a, *b, (*c, *d)) = (1, 2)

View file

@ -0,0 +1,2 @@
(*a, b) = (1, 2)
(*_, normed), *_ = [(1,), 2]