def get

bolt@1.27.0.0 · src/lsp/docs.bend:43

import bolt@1.27.0.0/src/lsp/docs.bend as Docs
import Base
import bolt@1.27.0.0/src/lazy/lazy.bend as Lazy

43# the text of an open document, when it is open
44def get(docs: List<&2, Doc>, +uri: String) -> Maybe<&2, String>:
45  match docs:
46    case Nil{}:
47      None{}
48    case Con{Doc{u, t, e, m}, r}:
49      Lazy.stop(Maybe<&2, String>, String.eq(u, uri), Some{t}, _u => get(r, uri))

Uses (6)

Used by (3)