Function
isPatternInstanceIn
(node: BaseNode, value: RegExp)
Source from the content-addressed store, hash-verified
| 1157 | } |
| 1158 | |
| 1159 | const isPatternInstanceIn = (node: BaseNode, value: RegExp): boolean => { |
| 1160 | for (const id in node.byId) { |
| 1161 | const reference = node.byId[id] |
| 1162 | if ( |
| 1163 | reference.is("pattern") && |
| 1164 | (reference.instance === value || reference.tested === value) |
| 1165 | ) |
| 1166 | return true |
| 1167 | } |
| 1168 | return false |
| 1169 | } |
| 1170 | |
| 1171 | // a cycle's members are ordered by content |
| 1172 | const nameComponent = ( |
Tested by
no test coverage detected