Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a dedicated token indexer for continuations and comments #1886

Merged
merged 3 commits into from
Jan 15, 2023

Conversation

charliermarsh
Copy link
Member

The primary motivation is that we can now robustly detect \ continuations due to the addition of Tok::NonLogicalNewline. This PR generalizes the approach we took to comments (track all lines that contain any comments), and applies it to continuations too.

@charliermarsh charliermarsh merged commit 3791ca7 into main Jan 15, 2023
@charliermarsh charliermarsh deleted the charlie/indexer branch January 15, 2023 06:57
renovate bot added a commit to ixm-one/pytest-cmake-presets that referenced this pull request Jan 16, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [ruff](https://togithub.com/charliermarsh/ruff) | `^0.0.222` ->
`^0.0.223` |
[![age](https://badges.renovateapi.com/packages/pypi/ruff/0.0.223/age-slim)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://badges.renovateapi.com/packages/pypi/ruff/0.0.223/adoption-slim)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://badges.renovateapi.com/packages/pypi/ruff/0.0.223/compatibility-slim/0.0.222)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://badges.renovateapi.com/packages/pypi/ruff/0.0.223/confidence-slim/0.0.222)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>charliermarsh/ruff</summary>

###
[`v0.0.223`](https://togithub.com/charliermarsh/ruff/releases/tag/v0.0.223)

[Compare
Source](https://togithub.com/charliermarsh/ruff/compare/v0.0.222...v0.0.223)

#### What's Changed

- Turn define_rule_mapping! into a procedural macro by
[@&#8203;not-my-profile](https://togithub.com/not-my-profile) in
[astral-sh/ruff#1885
- Convert confusable violations to named fields by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[astral-sh/ruff#1887
- Add a dedicated token indexer for continuations and comments by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[astral-sh/ruff#1886
- Remove some Clippy allows by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[astral-sh/ruff#1888
- Update add plugin/rule scripts by
[@&#8203;messense](https://togithub.com/messense) in
[astral-sh/ruff#1889
- Improve magic value message wording by
[@&#8203;TomFryers](https://togithub.com/TomFryers) in
[astral-sh/ruff#1892
- Use more precise error ranges for RET505~508 by
[@&#8203;harupy](https://togithub.com/harupy) in
[astral-sh/ruff#1895
- Implement flake8-commas by
[@&#8203;bluetech](https://togithub.com/bluetech) in
[astral-sh/ruff#1872
- refactor: Split CliSettings from Settings by
[@&#8203;not-my-profile](https://togithub.com/not-my-profile) in
[astral-sh/ruff#1891
- Skip noqa checker if no diagnostics are found by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[astral-sh/ruff#1898
- Don't require docstrings for setters and deleters by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[astral-sh/ruff#1899
- Buffer diagnostic writes to `stdout` by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[astral-sh/ruff#1900
- Lock `stdout` once when printing diagnostics by
[@&#8203;messense](https://togithub.com/messense) in
[astral-sh/ruff#1901
- Avoid triggering SIM117 for async with statements by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[astral-sh/ruff#1903

#### New Contributors

- [@&#8203;TomFryers](https://togithub.com/TomFryers) made their first
contribution in
[astral-sh/ruff#1892

**Full Changelog**:
astral-sh/ruff@v0.0.222...v0.0.223

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR is behind base branch, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://app.renovatebot.com/dashboard#github/ixm-one/pytest-cmake-presets).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNC4xMDIuNyIsInVwZGF0ZWRJblZlciI6IjM0LjEwMi43In0=-->

Signed-off-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant