def hover.local

bolt@1.27.0.0 · src/lsp/proto.bend:161

import bolt@1.27.0.0/src/lsp/proto.bend as Proto
import Base
import emerging-ezjson@1.2.0.0/main.bend as Ezjson
import emerging-ezjson@1.2.0.0/src/value.bend as J
import bolt@1.27.0.0/src/syntax/bind.bend as Bind

161# a binder of the document: the text that bound it, and what it is. The
162# server knows binding sites, not types: only a declaration carries one
163def hover.local(bb: Bind.Bind) -> J.Json:
164  Bind.Bind{name, line, col, +kind, note} = bb
165  Ezjson.obj([("contents", Ezjson.obj([("kind", J.JStr{"markdown"}), ("value", J.JStr{"```bend\n" ++ note ++ "\n```\n\n" ++
166    kind_name(kind) ++ where_bound(kind, line)})]))])

Uses (8)

Used by (1)