()
| 38304 | return false; |
| 38305 | } |
| 38306 | function parseJSDocEntityName() { |
| 38307 | var entity = parseJSDocIdentifierName(); |
| 38308 | if (parseOptional(22 /* SyntaxKind.OpenBracketToken */)) { |
| 38309 | parseExpected(23 /* SyntaxKind.CloseBracketToken */); |
| 38310 | // Note that y[] is accepted as an entity name, but the postfix brackets are not saved for checking. |
| 38311 | // Technically usejsdoc.org requires them for specifying a property of a type equivalent to Array<{ x: ...}> |
| 38312 | // but it's not worth it to enforce that restriction. |
| 38313 | } |
| 38314 | while (parseOptional(24 /* SyntaxKind.DotToken */)) { |
| 38315 | var name = parseJSDocIdentifierName(); |
| 38316 | if (parseOptional(22 /* SyntaxKind.OpenBracketToken */)) { |
| 38317 | parseExpected(23 /* SyntaxKind.CloseBracketToken */); |
| 38318 | } |
| 38319 | entity = createQualifiedName(entity, name); |
| 38320 | } |
| 38321 | return entity; |
| 38322 | } |
| 38323 | function parseJSDocIdentifierName(message) { |
| 38324 | if (!ts.tokenIsIdentifierOrKeyword(token())) { |
| 38325 | return createMissingNode(79 /* SyntaxKind.Identifier */, /*reportAtCurrentPosition*/ !message, message || ts.Diagnostics.Identifier_expected); |
no test coverage detected