MCPcopy Create free account
hub / github.com/csskit/csskit / peek

Method peek

crates/css_ast/src/units/custom.rs:17–23  ·  view source on GitHub ↗
(p: &Parser<'a, I>, c: Cursor)

Source from the content-addressed store, hash-verified

15
16 #[inline(always)]
17 fn peek<I>(p: &Parser<'a, I>, c: Cursor) -> bool
18 where
19 I: Iterator<Item = Cursor> + Clone,
20 {
21 <T![Dimension]>::peek(p, c)
22 && p.to_source_cursor(c).source()[c.token().numeric_len() as usize..].starts_with("--")
23 }
24}
25
26impl<'a> Parse<'a> for CustomDimension {

Callers

nothing calls this directly

Calls 4

numeric_lenMethod · 0.80
sourceMethod · 0.45
to_source_cursorMethod · 0.45
tokenMethod · 0.45

Tested by

no test coverage detected