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

Function createDiagnosticForInvalidCustomType

test/fixtures/snapshot/typescript.js:40492–40495  ·  view source on GitHub ↗
(opt, createDiagnostic)

Source from the content-addressed store, hash-verified

40490 }
40491 ts.createCompilerDiagnosticForInvalidCustomType = createCompilerDiagnosticForInvalidCustomType;
40492 function createDiagnosticForInvalidCustomType(opt, createDiagnostic) {
40493 var namesOfType = ts.arrayFrom(opt.type.keys()).map(function (key) { return "'".concat(key, "'"); }).join(", ");
40494 return createDiagnostic(ts.Diagnostics.Argument_for_0_option_must_be_Colon_1, "--".concat(opt.name), namesOfType);
40495 }
40496 /* @internal */
40497 function parseCustomTypeOption(opt, value, errors) {
40498 return convertJsonOptionOfCustomType(opt, ts.trimString(value || ""), errors);

Calls 5

createDiagnosticFunction · 0.85
concatMethod · 0.80
mapMethod · 0.65
keysMethod · 0.65
joinMethod · 0.45

Tested by

no test coverage detected