def refine_name

bolt@1.27.0.0 · src/syntax/lex.bend:258

import bolt@1.27.0.0/src/syntax/lex.bend as Lex
import Base

258# a whole name's kind
259def refine_name(+tt: String) -> TokKind:
260  Bool.pick(TokKind, is_keyword(tt), TKey{},
261    Bool.pick(TokKind, String.contains(tt, "."), TDotted{},
262      Bool.pick(TokKind, String.eq(tt, "_"), TWild{},
263        Bool.pick(TokKind, upper_first(String.to_list(tt)), TUpper{}, TName{}))))

Uses (8)

Used by (1)