MCPcopy Index your code
hub / github.com/nodejs/node / checkClassNameCollisionWithObject

Function checkClassNameCollisionWithObject

test/fixtures/snapshot/typescript.js:83906–83911  ·  view source on GitHub ↗

* The name cannot be used as 'Object' of user defined types with special target.

(name)

Source from the content-addressed store, hash-verified

83904 * The name cannot be used as 'Object' of user defined types with special target.
83905 */
83906 function checkClassNameCollisionWithObject(name) {
83907 if (languageVersion >= 1 /* ScriptTarget.ES5 */ && name.escapedText === "Object"
83908 && (moduleKind < ts.ModuleKind.ES2015 || ts.getSourceFileOfNode(name).impliedNodeFormat === ts.ModuleKind.CommonJS)) {
83909 error(name, ts.Diagnostics.Class_name_cannot_be_Object_when_targeting_ES5_with_module_0, ts.ModuleKind[moduleKind]); // https://github.com/Microsoft/TypeScript/issues/17494
83910 }
83911 }
83912 function checkUnmatchedJSDocParameters(node) {
83913 var jsdocParameters = ts.filter(ts.getJSDocTags(node), ts.isJSDocParameterTag);
83914 if (!ts.length(jsdocParameters))

Callers 1

Calls 1

errorFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…