Revision: 5801 Author: b...@google.com Date: Mon Jul 27 06:28:36 2009 Log: Reapplying r5789 to remove warnings from JsParser.
http://code.google.com/p/google-web-toolkit/source/detail?r=5801 Modified: /trunk/dev/core/src/com/google/gwt/dev/js/JsParser.java ======================================= --- /trunk/dev/core/src/com/google/gwt/dev/js/JsParser.java Fri Jul 24 17:50:15 2009 +++ /trunk/dev/core/src/com/google/gwt/dev/js/JsParser.java Mon Jul 27 06:28:36 2009 @@ -346,6 +346,8 @@ */ private JsNameRef mapAsPropertyNameRef(Node nameRefNode) throws JsParserException { + // Javac 1.6.0_01 doesn't like the cast below if this is parameterized + @SuppressWarnings("unchecked") JsNode unknown = map(nameRefNode); // This is weird, but for "a.b", the rhino AST calls "b" a string literal. // However, since we know it's for a PROPGET, we can unstringliteralize it. @@ -563,6 +565,8 @@ } private JsExpression mapExpression(Node exprNode) throws JsParserException { + // Javac 1.6.0_01 doesn't like the cast below if this is parameterized + @SuppressWarnings("unchecked") JsNode unknown = map(exprNode); if (unknown instanceof JsExpression) { return (JsExpression) unknown; @@ -623,7 +627,8 @@ JsFor toFor = new JsFor(makeSourceInfo(forNode)); // The first item is either an expression or a JsVars. - // + // Javac 1.6.0_01 doesn't like the cast below if this is parameterized + @SuppressWarnings("unchecked") JsNode initThingy = map(fromInit); if (initThingy != null) { if (initThingy instanceof JsVars) { @@ -839,6 +844,8 @@ private JsExpression mapOptionalExpression(Node exprNode) throws JsParserException { + // Javac 1.6.0_01 doesn't like the cast below if this is parameterized + @SuppressWarnings("unchecked") JsNode unknown = map(exprNode); if (unknown != null) { if (unknown instanceof JsExpression) { @@ -984,6 +991,8 @@ } private JsStatement mapStatement(Node nodeStmt) throws JsParserException { + // Javac 1.6.0_01 doesn't like the cast below if this is parameterized + @SuppressWarnings("unchecked") JsNode unknown = map(nodeStmt); if (unknown != null) { if (unknown instanceof JsStatement) { --~--~---------~--~----~------------~-------~--~----~ http://groups.google.com/group/Google-Web-Toolkit-Contributors -~----------~----~----~----~------~----~------~--~---