MCPcopy Index your code
hub / github.com/Linen-dev/linen.dev / explicit

Function explicit

packages/ast/parse/combinators.js:11–19  ·  view source on GitHub ↗
(matcher)

Source from the content-addressed store, hash-verified

9};
10
11const explicit = (matcher) => (text, position) => {
12 const previous = text[position - 1];
13
14 if (previous && !previous.match(/[\s.,([{!?\-=]/)) {
15 return null;
16 }
17
18 return matcher(text, position);
19};
20
21const topline = (matcher) => (text, position) => {
22 if (position > 0 && text.charAt(position - 1) !== '\n') {

Callers 3

index.jsFile · 0.85
index.jsFile · 0.85
index.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected