Server.pub.lint: def of bolt@1.27.0.0 Import: import bolt@1.27.0.0/src/lsp/server.bend as Server Lines 232-247 of bolt@1.27.0.0/src/lsp/server.bend: https://jend.leeeet.dev/read.txt?path=bolt@1.27.0.0/src/lsp/server.bend&start_line=232&end_line=247 import Base import bolt@1.27.0.0/src/rules.bend as Lint import bolt@1.27.0.0/src/finding.bend as Finding import bolt@1.27.0.0/src/config.bend as Config import bolt@1.27.0.0/src/lint/plan.bend as Plan import bolt@1.27.0.0/src/role.bend as Role import bolt@1.27.0.0/src/src.bend as Src import bolt@1.27.0.0/src/noqa.bend as Noqa import bolt@1.27.0.0/src/syntax/lex.bend as Lex # the linter's findings on the text the editor shows, each rule told the # file's role among the marks, at the levels the nearest bolt.bend read gives # them, less what the text's noqa comments # silence, then the `noqa` rule's, which judges no project rule's code (the # editor runs none); none for a bolt.bend, which is bolt's configuration, # not source def pub.lint( +path: String, +text: String, rs: List<&2, Maybe<&2, String>>, ms: List<&2, Role.Mark> ) -> List<&2, Finding.Graded>: +cfg = Config.nearest(rs) Bool.pick(List<&2, Finding.Graded>, Plan.is_config(path), [], Plan.after([Noqa.file(path, Lex.tokens(text))], False{}, Lint.graded(cfg, Lint.on.role(Role.of(ms, path), Src.of(path, text))), fs => Lint.graded(cfg, fs))) Uses (16): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.pick https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Maybe https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/config.bend&name=nearest https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/finding.bend&name=Graded https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/lint/plan.bend&name=after https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/lint/plan.bend&name=is_config https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/noqa.bend&name=file https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/role.bend&name=Mark https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/role.bend&name=of https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/rules.bend&name=graded https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/rules.bend&name=on.role https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/src.bend&name=of https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/syntax/lex.bend&name=tokens