From fae7a129eb91e66d7a32bbfddfec1d0c24ce66dc Mon Sep 17 00:00:00 2001 From: Daniel Rosenwasser Date: Thu, 10 Sep 2015 13:50:12 -0700 Subject: [PATCH] Assert condition to track root cause of issue. --- src/compiler/commandLineParser.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/compiler/commandLineParser.ts b/src/compiler/commandLineParser.ts index c56a18b3ab2..c9df1747999 100644 --- a/src/compiler/commandLineParser.ts +++ b/src/compiler/commandLineParser.ts @@ -326,9 +326,12 @@ namespace ts { if (hasProperty(map, key)) { options[opt.name] = map[key]; } - else { + else if (opt.error) { errors.push(createCompilerDiagnostic(opt.error)); } + else { + Debug.fail(`Command line option for '${opt.name}' doesn't account for invalid options.`); + } } } else {