Remove redundant #![allow()] from main_native by andersk · Pull Request #1703 · astral-sh/ruff (original) (raw)

@andersk

main_native.rs is a module of main.rs, so the #![allow()]s in the latter apply to the former automatically.

Signed-off-by: Anders Kaseorg andersk@mit.edu

bruxisma referenced this pull request in ixm-one/pytest-cmake-presets

Jan 7, 2023

@renovate

suleymanozkeskin added a commit to suleymanozkeskin/ruff-ty-typeis-fix that referenced this pull request

Dec 1, 2025

@suleymanozkeskin

Fixes astral-sh#1703

Fixes incomplete type narrowing when using TypeIs with generic union types like: Result[T, E] = Ok[T] | Err[E].

Previously, type parameter E was materialized to 'object' before specialization could substitute it with concrete types like Exception, causing narrowing to produce Err[Unknown] instead of Err[Exception].

Changes:

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters

[ Show hidden characters]({{ revealButtonHref }})