(source: string)
| 3209 | } |
| 3210 | |
| 3211 | function skipLeadingIgnoredTrivia(source: string): number { |
| 3212 | let index = source.charCodeAt(0) === 0xfeff ? 1 : 0 |
| 3213 | while (index < source.length) { |
| 3214 | while (index < source.length && /\s/.test(source[index])) index++ |
| 3215 | if (!source.startsWith("//", index)) return index |
| 3216 | const lineEnd = source.indexOf("\n", index) |
| 3217 | const end = lineEnd === -1 ? source.length : lineEnd + 1 |
| 3218 | if (!isSkippableDirectiveComment(source.slice(index, end))) return index |
| 3219 | index = end |
| 3220 | } |
| 3221 | return index |
| 3222 | } |
| 3223 | |
| 3224 | function sourceFileTopLevelJSDoc(sourceFile: ts.SourceFile): ParsedModuleJSDoc | undefined { |
| 3225 | const source = sourceFile.text |
no test coverage detected