Skip to content

Commit

Permalink
feat(gcc): Update Google Closure Compiler options for 20171203 release.
Browse files Browse the repository at this point in the history
BREAKING CHANGE: The gcc error groups are not backwards compatible with older compilers.
This will also introduce new warnings unless `missingOverride` is added to `jscomp_off`
in package gcc options.
  • Loading branch information
Kevin Schmidt committed Dec 19, 2017
1 parent c530ca8 commit 8afc7fd
Showing 1 changed file with 18 additions and 19 deletions.
37 changes: 18 additions & 19 deletions plugins/gcc/options-base.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@
This is from the compiler's help output:
Available Error Groups: accessControls, ambiguousFunctionDecl,
checkEventfulObjectDisposal, checkRegExp, checkTypes, checkVars,
conformanceViolations, const, constantProperty, deprecated,
deprecatedAnnotations, duplicateMessage, es3, es5Strict, externsValidation,
fileoverviewTags, globalThis, internetExplorerChecks, invalidCasts,
misplacedTypeAnnotation, missingGetCssName, missingProperties,
missingProvide, missingRequire, missingReturn, msgDescriptions,
newCheckTypes, nonStandardJsDocs, reportUnknownTypes, suspiciousCode,
strictModuleDepCheck, typeInvalidation, undefinedNames, undefinedVars,
unknownDefines, unusedLocalVariables, unusedPrivateMembers, uselessCode,
useOfGoogBase, underscore, visibility
checkRegExp, checkTypes, checkVars, conformanceViolations, const,
constantProperty, deprecated, deprecatedAnnotations, duplicateMessage, es3,
es5Strict, externsValidation, fileoverviewTags, functionParams, globalThis,
internetExplorerChecks, invalidCasts, misplacedTypeAnnotation,
missingGetCssName, missingOverride, missingPolyfill, missingProperties,
missingProvide, missingRequire, missingReturn, moduleLoad, msgDescriptions,
newCheckTypes, nonStandardJsDocs, missingSourcesWarnings,
reportUnknownTypes, suspiciousCode, strictModuleDepCheck, typeInvalidation,
undefinedNames, undefinedVars, unknownDefines, unusedLocalVariables,
unusedPrivateMembers, uselessCode, useOfGoogBase, underscore, visibility
The docs for jscomp_* state that you can use a wildcard. However, that wildcard
also enables a lot more undocumented items.
Expand Down Expand Up @@ -43,7 +43,6 @@ module.exports = {
jscomp_error: [
'accessControls',
'ambiguousFunctionDecl',
'checkEventfulObjectDisposal',
'checkRegExp',
'checkTypes',
'checkVars',
Expand All @@ -57,30 +56,32 @@ module.exports = {
'es5Strict',
'externsValidation',
'fileoverviewTags',
'functionParams',
'globalThis',
'inferredConstCheck',
'internetExplorerChecks',
'invalidCasts',
'misplacedTypeAnnotation',
'missingGetCssName',
'missingPolyfill',
'missingProperties',
// 'missingProvide',
'missingRequire',
'missingReturn',
'moduleLoad',
'msgDescriptions',
// 'newCheckTypes',
'nonStandardJsDocs',
'missingSourcesWarnings',
// 'reportUnknownTypes',
'suspiciousCode',
'strictModuleDepCheck',
'typeInvalidation',
'undefinedNames',
'undefinedVars',
'unknownDefines',
'unnecessaryCasts',
// 'unusedLocalVariables',
'unusedLocalVariables',
// 'unusedPrivateMembers',
// 'useOfGoogBase',
'useOfGoogBase',
'uselessCode',
'underscore',
'visibility'
Expand All @@ -89,10 +90,8 @@ module.exports = {
// If jscomp_error changes to *, you probably want this one
// 'lintChecks'
'deprecated',
'missingProvide',
'unusedLocalVariables',
'unusedPrivateMembers',
'useOfGoogBase'
'missingOverride',
'unusedPrivateMembers'
],
// TODO: can we get rid of these too?
jscomp_off: [
Expand Down

0 comments on commit 8afc7fd

Please sign in to comment.