Title: TypeError: Cannot read property 'type' of undefined at getJSDocTypeForVariableLikeDeclarationFromJSDocComment · Issue #7002 · microsoft/TypeScript · GitHub
Open Graph Title: TypeError: Cannot read property 'type' of undefined at getJSDocTypeForVariableLikeDeclarationFromJSDocComment · Issue #7002 · microsoft/TypeScript
X Title: TypeError: Cannot read property 'type' of undefined at getJSDocTypeForVariableLikeDeclarationFromJSDocComment · Issue #7002 · microsoft/TypeScript
Description: With the current master, the compiler crashes when the @type JSDoc annotation of a variable is malformed, e.g. in the following (shortened) example from lodash: /** * Checks if `value` is classified as an `Array` object. * * @type Functi...
Open Graph Description: With the current master, the compiler crashes when the @type JSDoc annotation of a variable is malformed, e.g. in the following (shortened) example from lodash: /** * Checks if `value` is classifie...
X Description: With the current master, the compiler crashes when the @type JSDoc annotation of a variable is malformed, e.g. in the following (shortened) example from lodash: /** * Checks if `value` is classifie...
Opengraph URL: https://github.com/microsoft/TypeScript/issues/7002
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"TypeError: Cannot read property 'type' of undefined at getJSDocTypeForVariableLikeDeclarationFromJSDocComment","articleBody":"With the current master, the compiler crashes when the `@type` JSDoc annotation of a variable is malformed, e.g. in the following (shortened) example from [lodash](https://github.com/lodash/lodash/blob/4.3.0/lodash.js#L9452):\n\n``` javascript\n/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @type Function\n */\nvar isArray = Array.isArray;\n```\n\nThis is in the statement `return annotation.typeExpression.type;`;\n\nThis compiles fine if `Function` above is replaced with `{Function}`.\n\nIt seems this is similar to #6709 and `annotation.typeExpression` needs checking too.\n\nI could submit a PR, but I understand from CONTRIBUTING.md that the issue needs approval first?\n","author":{"url":"https://github.com/magnushiie","@type":"Person","name":"magnushiie"},"datePublished":"2016-02-10T15:53:45Z","url":"https://github.com/microsoft/TypeScript/issues/7002"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:47af3411-914d-bb53-87cb-78e075aac3fe |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D4A0:38E318:98B136:C07C05:6B01268B |
| html-safe-nonce | 1d271ee3a70a029773d8d4f1d76731093a81468e81b1ec8d294b2e1ff9f89043 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJENEEwOjM4RTMxODo5OEIxMzY6QzA3QzA1OjZCMDEyNjhCIiwidmlzaXRvcl9pZCI6IjUyNjE4NjExMjAxMzM2Mzc3NzIiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 7e8c6a477a255aa73eebf7893b58a46e5300a209c94b180309611c78ef154431 |
| hovercard-subject-tag | issue:132738243 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/microsoft/TypeScript/7002/issue_layout |
| twitter:image | https://opengraph.githubassets.com/5c00fa61e16da684c859da8973ada8d4ece5b681d3dca4878e33e83a9943c0d0/microsoft/TypeScript/issues/7002 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/5c00fa61e16da684c859da8973ada8d4ece5b681d3dca4878e33e83a9943c0d0/microsoft/TypeScript/issues/7002 |
| og:image:alt | With the current master, the compiler crashes when the @type JSDoc annotation of a variable is malformed, e.g. in the following (shortened) example from lodash: /** * Checks if `value` is classifie... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | magnushiie |
| hostname | github.com |
| expected-hostname | github.com |
| None | cc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c |
| turbo-cache-control | no-preview |
| go-import | github.com/microsoft/TypeScript git https://github.com/microsoft/TypeScript.git |
| octolytics-dimension-user_id | 6154722 |
| octolytics-dimension-user_login | microsoft |
| octolytics-dimension-repository_id | 20929025 |
| octolytics-dimension-repository_nwo | microsoft/TypeScript |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 20929025 |
| octolytics-dimension-repository_network_root_nwo | microsoft/TypeScript |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 8c77c9e8439031ad54c75a250694842892f693e1 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width