(ref: UnresolvedRef, context: ResolutionContext)
| 162 | * most likely built with one that has it. |
| 163 | */ |
| 164 | export function matchPascalSystemCall(ref: UnresolvedRef, context: ResolutionContext): ResolvedRef | null { |
| 165 | const decl = declarationInScope(ref.referenceName.toLowerCase(), classOfCall(ref, context), ref, context); |
| 166 | if (!decl) return null; |
| 167 | if (DATA_KINDS.has(decl.node.kind) && !isProceduralData(decl.node, context)) return null; |
| 168 | if (!decl.node.qualifiedName.includes('::') && declaredUnderCondition(decl.node, context)) return null; |
| 169 | context.rememberNode?.(decl.node); |
| 170 | return { original: ref, targetNodeId: decl.node.id, confidence: decl.confidence, resolvedBy: decl.resolvedBy }; |
| 171 | } |
| 172 | |
| 173 | /** |
| 174 | * What a Pascal call another strategy resolved stands for, when it landed on |
no test coverage detected