(seed: string)
| 259 | } |
| 260 | |
| 261 | function freshIdentifier(seed: string): string { |
| 262 | const sanitized = sanitizeJavaScriptIdentifier(seed) |
| 263 | let candidate = sanitized |
| 264 | let suffix = 0 |
| 265 | while (uniqueIdentifiers.has(candidate)) candidate = `${sanitized}${++suffix}` |
| 266 | uniqueIdentifiers.add(candidate) |
| 267 | return candidate |
| 268 | } |
| 269 | |
| 270 | function addImport(importDeclaration: string): void { |
| 271 | if (!artifacts.some((artifact) => artifact._tag === "Import" && artifact.importDeclaration === importDeclaration)) { |
no test coverage detected