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

Function shallow

packages/ast/parse/combinators.js:42–53  ·  view source on GitHub ↗
(type)

Source from the content-addressed store, hash-verified

40};
41
42const shallow = (type) => (match, _, position) => {
43 const [result, content] = match;
44
45 return [
46 {
47 type,
48 value: content,
49 source: result,
50 },
51 position + result.length,
52 ];
53};
54
55const root = (input, children) => ({
56 type: 'root',

Callers 2

index.jsFile · 0.85
index.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected