flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aha...@apache.org
Subject [2/9] git commit: [flex-falcon] [refs/heads/develop] - suppress warnings when we don't emit a goog.requires for types only mentioned in JSDoc
Date Mon, 11 Jan 2016 18:04:45 GMT
suppress warnings when we don't emit a goog.requires for types only mentioned in JSDoc


Project: http://git-wip-us.apache.org/repos/asf/flex-falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-falcon/commit/a61d9064
Tree: http://git-wip-us.apache.org/repos/asf/flex-falcon/tree/a61d9064
Diff: http://git-wip-us.apache.org/repos/asf/flex-falcon/diff/a61d9064

Branch: refs/heads/develop
Commit: a61d9064561ad6299bc3a189b0180e1c545496fa
Parents: 15b170f
Author: Alex Harui <aharui@apache.org>
Authored: Thu Jan 7 15:52:32 2016 -0800
Committer: Alex Harui <aharui@apache.org>
Committed: Thu Jan 7 15:52:32 2016 -0800

----------------------------------------------------------------------
 .../google/javascript/jscomp/FlexJSDiagnosticGroups.java    | 9 +++++++++
 .../flex/compiler/utils/JSClosureCompilerWrapper.java       | 1 +
 2 files changed, 10 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/a61d9064/compiler.jx/src/com/google/javascript/jscomp/FlexJSDiagnosticGroups.java
----------------------------------------------------------------------
diff --git a/compiler.jx/src/com/google/javascript/jscomp/FlexJSDiagnosticGroups.java b/compiler.jx/src/com/google/javascript/jscomp/FlexJSDiagnosticGroups.java
index e28cfe7..5b77b44 100644
--- a/compiler.jx/src/com/google/javascript/jscomp/FlexJSDiagnosticGroups.java
+++ b/compiler.jx/src/com/google/javascript/jscomp/FlexJSDiagnosticGroups.java
@@ -46,4 +46,13 @@ public class FlexJSDiagnosticGroups {
 		DiagnosticGroups.registerGroup("flexjsReferenceBeforeDeclare",
                 VariableReferenceCheck.UNDECLARED_REFERENCE);
     */
+	
+	/**
+	 * Flex code won't always generate a goog.requires for types only used
+	 * in JSDoc annotations, but the compiler complains.
+	 */
+	public static final DiagnosticGroup FLEXJS_UNKNOWN_JSDOC_TYPE_NAME =
+		DiagnosticGroups.registerGroup("flexjsUnknownJSDocTypeName",
+                RhinoErrorReporter.TYPE_PARSE_ERROR);
+
 }

http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/a61d9064/compiler.jx/src/org/apache/flex/compiler/utils/JSClosureCompilerWrapper.java
----------------------------------------------------------------------
diff --git a/compiler.jx/src/org/apache/flex/compiler/utils/JSClosureCompilerWrapper.java
b/compiler.jx/src/org/apache/flex/compiler/utils/JSClosureCompilerWrapper.java
index a9aa8bd..05e0328 100644
--- a/compiler.jx/src/org/apache/flex/compiler/utils/JSClosureCompilerWrapper.java
+++ b/compiler.jx/src/org/apache/flex/compiler/utils/JSClosureCompilerWrapper.java
@@ -277,6 +277,7 @@ public class JSClosureCompilerWrapper
             // still want warnings for others in the group.
             options_.setWarningLevel(FlexJSDiagnosticGroups.FLEXJS_NOT_A_CONSTRUCTOR, CheckLevel.OFF);
             options_.setWarningLevel(FlexJSDiagnosticGroups.FLEXJS_SUPER_CALL_TO_DIFFERENT_NAME,
CheckLevel.OFF);
+            options_.setWarningLevel(FlexJSDiagnosticGroups.FLEXJS_UNKNOWN_JSDOC_TYPE_NAME,
CheckLevel.OFF);
 //            options_.setWarningLevel(FlexJSDiagnosticGroups.FLEXJS_REFERENCE_BEFORE_DECLARE,
CheckLevel.OFF);
         }
         


Mime
View raw message