2021-12-20 10:45:52 -06:00
|
|
|
const PARSED = [
|
|
|
|
{
|
2023-06-09 09:49:38 -05:00
|
|
|
query: 'fn:foo',
|
2021-12-20 10:45:52 -06:00
|
|
|
elems: [{
|
|
|
|
name: "foo",
|
|
|
|
fullPath: ["foo"],
|
|
|
|
pathWithoutLast: [],
|
|
|
|
pathLast: "foo",
|
|
|
|
generics: [],
|
2023-02-28 19:17:59 -06:00
|
|
|
typeFilter: 5,
|
2021-12-20 10:45:52 -06:00
|
|
|
}],
|
|
|
|
foundElems: 1,
|
|
|
|
original: "fn:foo",
|
|
|
|
returned: [],
|
2022-01-03 09:43:30 -06:00
|
|
|
userQuery: "fn:foo",
|
2021-12-20 10:45:52 -06:00
|
|
|
error: null,
|
|
|
|
},
|
|
|
|
{
|
2023-06-09 09:49:38 -05:00
|
|
|
query: 'enum : foo',
|
2021-12-20 10:45:52 -06:00
|
|
|
elems: [{
|
|
|
|
name: "foo",
|
|
|
|
fullPath: ["foo"],
|
|
|
|
pathWithoutLast: [],
|
|
|
|
pathLast: "foo",
|
|
|
|
generics: [],
|
2023-02-28 19:17:59 -06:00
|
|
|
typeFilter: 4,
|
2021-12-20 10:45:52 -06:00
|
|
|
}],
|
|
|
|
foundElems: 1,
|
|
|
|
original: "enum : foo",
|
|
|
|
returned: [],
|
2022-01-03 09:43:30 -06:00
|
|
|
userQuery: "enum : foo",
|
2021-12-20 10:45:52 -06:00
|
|
|
error: null,
|
|
|
|
},
|
|
|
|
{
|
2023-06-09 09:49:38 -05:00
|
|
|
query: 'macro<f>:foo',
|
2022-01-09 08:12:46 -06:00
|
|
|
elems: [],
|
|
|
|
foundElems: 0,
|
2021-12-20 10:45:52 -06:00
|
|
|
original: "macro<f>:foo",
|
|
|
|
returned: [],
|
2022-01-03 09:43:30 -06:00
|
|
|
userQuery: "macro<f>:foo",
|
2023-06-12 09:05:00 -05:00
|
|
|
error: "Unexpected `<` in type filter (before `:`)",
|
2021-12-20 10:45:52 -06:00
|
|
|
},
|
2023-02-16 16:32:38 -06:00
|
|
|
{
|
2023-06-09 09:49:38 -05:00
|
|
|
query: 'macro!',
|
2023-02-16 16:32:38 -06:00
|
|
|
elems: [{
|
|
|
|
name: "macro",
|
|
|
|
fullPath: ["macro"],
|
|
|
|
pathWithoutLast: [],
|
|
|
|
pathLast: "macro",
|
|
|
|
generics: [],
|
2023-02-28 19:17:59 -06:00
|
|
|
typeFilter: 14,
|
2023-02-16 16:32:38 -06:00
|
|
|
}],
|
|
|
|
foundElems: 1,
|
|
|
|
original: "macro!",
|
|
|
|
returned: [],
|
|
|
|
userQuery: "macro!",
|
|
|
|
error: null,
|
|
|
|
},
|
|
|
|
{
|
2023-06-09 09:49:38 -05:00
|
|
|
query: 'macro:mac!',
|
2023-02-16 16:32:38 -06:00
|
|
|
elems: [{
|
|
|
|
name: "mac",
|
|
|
|
fullPath: ["mac"],
|
|
|
|
pathWithoutLast: [],
|
|
|
|
pathLast: "mac",
|
|
|
|
generics: [],
|
2023-02-28 19:17:59 -06:00
|
|
|
typeFilter: 14,
|
2023-02-16 16:32:38 -06:00
|
|
|
}],
|
|
|
|
foundElems: 1,
|
|
|
|
original: "macro:mac!",
|
|
|
|
returned: [],
|
|
|
|
userQuery: "macro:mac!",
|
|
|
|
error: null,
|
|
|
|
},
|
|
|
|
{
|
2023-06-09 09:49:38 -05:00
|
|
|
query: 'a::mac!',
|
2023-02-16 16:32:38 -06:00
|
|
|
elems: [{
|
|
|
|
name: "a::mac",
|
|
|
|
fullPath: ["a", "mac"],
|
|
|
|
pathWithoutLast: ["a"],
|
|
|
|
pathLast: "mac",
|
|
|
|
generics: [],
|
2023-02-28 19:17:59 -06:00
|
|
|
typeFilter: 14,
|
2023-02-16 16:32:38 -06:00
|
|
|
}],
|
|
|
|
foundElems: 1,
|
|
|
|
original: "a::mac!",
|
|
|
|
returned: [],
|
|
|
|
userQuery: "a::mac!",
|
|
|
|
error: null,
|
|
|
|
},
|
2023-02-28 19:17:59 -06:00
|
|
|
{
|
2023-06-09 09:49:38 -05:00
|
|
|
query: '-> fn:foo',
|
2023-02-28 19:17:59 -06:00
|
|
|
elems: [],
|
|
|
|
foundElems: 1,
|
|
|
|
original: "-> fn:foo",
|
|
|
|
returned: [{
|
|
|
|
name: "foo",
|
|
|
|
fullPath: ["foo"],
|
|
|
|
pathWithoutLast: [],
|
|
|
|
pathLast: "foo",
|
|
|
|
generics: [],
|
|
|
|
typeFilter: 5,
|
|
|
|
}],
|
|
|
|
userQuery: "-> fn:foo",
|
|
|
|
error: null,
|
|
|
|
},
|
|
|
|
{
|
2023-06-09 09:49:38 -05:00
|
|
|
query: '-> fn:foo<fn:bar>',
|
2023-02-28 19:17:59 -06:00
|
|
|
elems: [],
|
|
|
|
foundElems: 1,
|
|
|
|
original: "-> fn:foo<fn:bar>",
|
|
|
|
returned: [{
|
|
|
|
name: "foo",
|
|
|
|
fullPath: ["foo"],
|
|
|
|
pathWithoutLast: [],
|
|
|
|
pathLast: "foo",
|
|
|
|
generics: [
|
|
|
|
{
|
|
|
|
name: "bar",
|
|
|
|
fullPath: ["bar"],
|
|
|
|
pathWithoutLast: [],
|
|
|
|
pathLast: "bar",
|
|
|
|
generics: [],
|
|
|
|
typeFilter: 5,
|
|
|
|
}
|
|
|
|
],
|
|
|
|
typeFilter: 5,
|
|
|
|
}],
|
|
|
|
userQuery: "-> fn:foo<fn:bar>",
|
|
|
|
error: null,
|
|
|
|
},
|
|
|
|
{
|
2023-06-09 09:49:38 -05:00
|
|
|
query: '-> fn:foo<fn:bar, enum : baz::fuzz>',
|
2023-02-28 19:17:59 -06:00
|
|
|
elems: [],
|
|
|
|
foundElems: 1,
|
|
|
|
original: "-> fn:foo<fn:bar, enum : baz::fuzz>",
|
|
|
|
returned: [{
|
|
|
|
name: "foo",
|
|
|
|
fullPath: ["foo"],
|
|
|
|
pathWithoutLast: [],
|
|
|
|
pathLast: "foo",
|
|
|
|
generics: [
|
|
|
|
{
|
|
|
|
name: "bar",
|
|
|
|
fullPath: ["bar"],
|
|
|
|
pathWithoutLast: [],
|
|
|
|
pathLast: "bar",
|
|
|
|
generics: [],
|
|
|
|
typeFilter: 5,
|
|
|
|
},
|
|
|
|
{
|
|
|
|
name: "baz::fuzz",
|
|
|
|
fullPath: ["baz", "fuzz"],
|
|
|
|
pathWithoutLast: ["baz"],
|
|
|
|
pathLast: "fuzz",
|
|
|
|
generics: [],
|
|
|
|
typeFilter: 4,
|
|
|
|
},
|
|
|
|
],
|
|
|
|
typeFilter: 5,
|
|
|
|
}],
|
|
|
|
userQuery: "-> fn:foo<fn:bar, enum : baz::fuzz>",
|
|
|
|
error: null,
|
|
|
|
},
|
2021-12-20 10:45:52 -06:00
|
|
|
];
|