MCPcopy Create free account
hub / github.com/LaBatata101/sith-language-server / fmt

Method fmt

crates/sith_python_parser/src/parser/statement.rs:3494–3509  ·  view source on GitHub ↗
(&self, f: &mut std::fmt::Formatter<'_>)

Source from the content-addressed store, hash-verified

3492
3493impl Display for Clause {
3494 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
3495 match self {
3496 Clause::If => write!(f, "`if` statement"),
3497 Clause::Else => write!(f, "`else` clause"),
3498 Clause::ElIf => write!(f, "`elif` clause"),
3499 Clause::For => write!(f, "`for` statement"),
3500 Clause::With => write!(f, "`with` statement"),
3501 Clause::Class => write!(f, "`class` definition"),
3502 Clause::While => write!(f, "`while` statement"),
3503 Clause::FunctionDef => write!(f, "function definition"),
3504 Clause::Case => write!(f, "`case` block"),
3505 Clause::Try => write!(f, "`try` statement"),
3506 Clause::Except => write!(f, "`except` clause"),
3507 Clause::Finally => write!(f, "`finally` clause"),
3508 }
3509 }
3510}
3511
3512/// The classification of the `match` token.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected