Enable --document-private-items for ruff_python_formatter (#21903)

This commit is contained in:
Brent Westbrook
2025-12-11 08:23:10 -05:00
committed by GitHub
parent 27912d46b1
commit c51727708a
18 changed files with 70 additions and 53 deletions

View File

@@ -783,7 +783,7 @@ enum CodeExampleKind<'src> {
///
/// Documentation describing doctests and how they're recognized can be
/// found as part of the Python standard library:
/// https://docs.python.org/3/library/doctest.html.
/// <https://docs.python.org/3/library/doctest.html>.
///
/// (You'll likely need to read the [regex matching] used internally by the
/// doctest module to determine more precisely how it works.)

View File

@@ -38,8 +38,9 @@ impl<'a, 'src> StringNormalizer<'a, 'src> {
/// it can't because the string contains the preferred quotes OR
/// it leads to more escaping.
///
/// Note: If you add more cases here where we return `QuoteStyle::Preserve`,
/// make sure to also add them to [`FormatImplicitConcatenatedStringFlat::new`].
/// Note: If you add more cases here where we return `QuoteStyle::Preserve`, make sure to also
/// add them to
/// [`FormatImplicitConcatenatedStringFlat::new`](crate::string::implicit::FormatImplicitConcatenatedStringFlat::new).
pub(super) fn preferred_quote_style(&self, string: StringLikePart) -> QuoteStyle {
let preferred_quote_style = self
.preferred_quote_style