ruff_linter 0.15.19

This is an internal component crate of Ruff
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use crate::docstrings::google::GOOGLE_SECTIONS;
use crate::docstrings::numpy::NUMPY_SECTIONS;
use crate::docstrings::sections::SectionKind;

#[derive(Copy, Clone, Debug, is_macro::Is)]
pub(crate) enum SectionStyle {
    Numpy,
    Google,
}

impl SectionStyle {
    pub(crate) fn sections(&self) -> &[SectionKind] {
        match self {
            SectionStyle::Numpy => NUMPY_SECTIONS,
            SectionStyle::Google => GOOGLE_SECTIONS,
        }
    }
}