INNER CODE UNIT · Rust

cmp

apache/datafusion-sqlparser-rs · src/ast/mod.rs:313

    fn cmp(&self, other: &Self) -> Ordering {
        let Ident {
            value,
            quote_style,
            // exhaustiveness check; we ignore spans in ordering
            span: _,
        } = self;

        let Ident {
            value: other_value,
            quote_style: other_quote_style,
            // exhaustiveness check; we ignore spans in ordering
            span: _,
        } = other;

        // First compare by value, then by quote_style
        value
            .cmp(other_value)

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…