MCPcopy Create free account
hub / github.com/GraphLite-AI/GraphLite / edge_direction

Function edge_direction

graphlite/src/ast/parser.rs:2420–2427  ·  view source on GitHub ↗

Parse edge direction

(tokens: &[Token])

Source from the content-addressed store, hash-verified

2418
2419/// Parse edge direction
2420fn edge_direction(tokens: &[Token]) -> IResult<&[Token], EdgeDirection> {
2421 alt((
2422 value(EdgeDirection::Both, expect_token(Token::ArrowBoth)),
2423 value(EdgeDirection::Outgoing, expect_token(Token::Arrow)),
2424 value(EdgeDirection::Incoming, expect_token(Token::ArrowLeft)),
2425 value(EdgeDirection::Undirected, expect_token(Token::Dash)),
2426 ))(tokens)
2427}
2428
2429/// Parse comparison operator
2430fn comparison_operator(tokens: &[Token]) -> IResult<&[Token], Operator> {

Callers

nothing calls this directly

Calls 1

expect_tokenFunction · 0.85

Tested by

no test coverage detected