def key.of
import bolt@1.27.0.0/src/lsp/checker/names.bend as Namesimport Base
25# the key of a name that opens with `head.`: through the import aliased head
26# when there is one, else the name as written
27def key.of(alias: Maybe<&2, String>, +name: String, +rest: String) -> String:
28 match alias:
29 case None{}:
30 name
31 case Some{path}:
32 ns(path) ++ "." ++ rest