You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pig.apache.org by th...@apache.org on 2011/08/22 20:40:39 UTC

svn commit: r1160368 - in /pig/trunk: ./ ivy/ src/org/apache/pig/parser/

Author: thejas
Date: Mon Aug 22 18:40:39 2011
New Revision: 1160368

URL: http://svn.apache.org/viewvc?rev=1160368&view=rev
Log:
PIG-2055: inconsistent behavior in parser generated during build (thejas)

Modified:
    pig/trunk/CHANGES.txt
    pig/trunk/build.xml
    pig/trunk/ivy.xml
    pig/trunk/ivy/libraries.properties
    pig/trunk/ivy/pig.pom
    pig/trunk/src/org/apache/pig/parser/AstValidator.g
    pig/trunk/src/org/apache/pig/parser/LogicalPlanBuilder.java
    pig/trunk/src/org/apache/pig/parser/LogicalPlanGenerator.g
    pig/trunk/src/org/apache/pig/parser/PigRecognitionException.java

Modified: pig/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/pig/trunk/CHANGES.txt?rev=1160368&r1=1160367&r2=1160368&view=diff
==============================================================================
--- pig/trunk/CHANGES.txt (original)
+++ pig/trunk/CHANGES.txt Mon Aug 22 18:40:39 2011
@@ -111,6 +111,8 @@ PIG-2011: Speed up TestTypedMap.java (dv
 
 BUG FIXES
 
+PIG-2055: inconsistent behavior in parser generated during build (thejas)
+
 PIG-2185: NullPointerException while Accessing Empty Bag in FOREACH { FILTER } (daijy)
 
 PIG-2227: Wrong jars copied into lib directory in e2e tests when invoked from top level (gates)

Modified: pig/trunk/build.xml
URL: http://svn.apache.org/viewvc/pig/trunk/build.xml?rev=1160368&r1=1160367&r2=1160368&view=diff
==============================================================================
--- pig/trunk/build.xml (original)
+++ pig/trunk/build.xml Mon Aug 22 18:40:39 2011
@@ -564,7 +564,7 @@
             <zipfileset src="${ivy.lib.dir}/hadoop-core-${hadoop-core.version}.jar" />
             <zipfileset src="${lib.dir}/${automaton.jarfile}" />
             <zipfileset src="${ivy.lib.dir}/antlr-runtime-${antlr.version}.jar" />
-            <zipfileset src="${ivy.lib.dir}/stringtemplate-${antlr.version}.jar" />
+            <zipfileset src="${ivy.lib.dir}/ST4-${stringtemplate.version}.jar" />
             <zipfileset src="${ivy.lib.dir}/junit-${junit.version}.jar" />
             <zipfileset src="${ivy.lib.dir}/jsch-${jsch.version}.jar" />
             <zipfileset src="${ivy.lib.dir}/jline-${jline.version}.jar" />
@@ -649,7 +649,7 @@
             </manifest>
             <zipfileset src="${lib.dir}/${automaton.jarfile}" />
             <zipfileset src="${ivy.lib.dir}/antlr-runtime-${antlr.version}.jar" />
-            <zipfileset src="${ivy.lib.dir}/stringtemplate-${antlr.version}.jar" />
+            <zipfileset src="${ivy.lib.dir}/ST4-${stringtemplate.version}.jar" />
             <zipfileset src="${ivy.lib.dir}/junit-${junit.version}.jar" />
             <zipfileset src="${ivy.lib.dir}/jsch-${jsch.version}.jar" />
             <zipfileset src="${ivy.lib.dir}/jline-${jline.version}.jar" />

Modified: pig/trunk/ivy.xml
URL: http://svn.apache.org/viewvc/pig/trunk/ivy.xml?rev=1160368&r1=1160367&r2=1160368&view=diff
==============================================================================
--- pig/trunk/ivy.xml (original)
+++ pig/trunk/ivy.xml Mon Aug 22 18:40:39 2011
@@ -98,6 +98,7 @@
     <dependency org="rhino" name="js" rev="${rhino.version}" conf="compile->master"/>
   	<dependency org="org.antlr" name="antlr" rev="${antlr.version}" conf="compile->master"/>
   	<dependency org="org.antlr" name="antlr-runtime" rev="${antlr.version}" conf="compile->default"/>
+	<dependency org="org.antlr" name="ST4" rev="${stringtemplate.version}" conf="compile->default"/>
     <dependency org="org.apache.zookeeper" name="zookeeper" rev="${zookeeper.version}" conf="compile->master"/>
     <dependency org="org.jboss.netty" name="netty" rev="3.2.2.Final" conf="compile->master"/>
 

Modified: pig/trunk/ivy/libraries.properties
URL: http://svn.apache.org/viewvc/pig/trunk/ivy/libraries.properties?rev=1160368&r1=1160367&r2=1160368&view=diff
==============================================================================
--- pig/trunk/ivy/libraries.properties (original)
+++ pig/trunk/ivy/libraries.properties Mon Aug 22 18:40:39 2011
@@ -15,7 +15,6 @@
 
 #These are the versions of our dependencies (in alphabetical order)
 apacheant.version=1.7.1
-antlr.version=2.7.6
 pig.version=0.9.0
 
 avro.version=1.5.1
@@ -43,7 +42,8 @@ json-simple.version=1.1
 junit.version=4.5
 jython.version=2.5.0
 rhino.version=1.7R2
-antlr.version=3.2
+antlr.version=3.4
+stringtemplate.version=4.0.4
 log4j.version=1.2.14
 netty.version=3.2.2
 rats-lib.version=0.5.1

Modified: pig/trunk/ivy/pig.pom
URL: http://svn.apache.org/viewvc/pig/trunk/ivy/pig.pom?rev=1160368&r1=1160367&r2=1160368&view=diff
==============================================================================
--- pig/trunk/ivy/pig.pom (original)
+++ pig/trunk/ivy/pig.pom Mon Aug 22 18:40:39 2011
@@ -121,12 +121,12 @@
     <dependency>
       <groupId>org.antlr</groupId>
       <artifactId>antlr-runtime</artifactId>
-      <version>3.2</version>
+      <version>3.4</version>
     </dependency>
     <dependency>
       <groupId>org.antlr</groupId>
-      <artifactId>stringtemplate</artifactId>
-      <version>3.2</version>
+      <artifactId>ST4</artifactId>
+      <version>4.0.4</version>
     </dependency>
    <dependency>
       <groupId>org.apache.hadoop</groupId>

Modified: pig/trunk/src/org/apache/pig/parser/AstValidator.g
URL: http://svn.apache.org/viewvc/pig/trunk/src/org/apache/pig/parser/AstValidator.g?rev=1160368&r1=1160367&r2=1160368&view=diff
==============================================================================
--- pig/trunk/src/org/apache/pig/parser/AstValidator.g (original)
+++ pig/trunk/src/org/apache/pig/parser/AstValidator.g Mon Aug 22 18:40:39 2011
@@ -186,11 +186,11 @@ filename : QUOTEDSTRING
 as_clause: ^( AS field_def_list )
 ;
 
-field_def[Set<String> fieldNames] throws Exception
+field_def[Set<String> fieldNames] throws DuplicatedSchemaAliasException
  : ^( FIELD_DEF IDENTIFIER { validateSchemaAliasName( fieldNames, $IDENTIFIER, $IDENTIFIER.text ); } type? )
 ;
 
-field_def_list
+field_def_list throws DuplicatedSchemaAliasException
 scope{
     Set<String> fieldNames;
 }

Modified: pig/trunk/src/org/apache/pig/parser/LogicalPlanBuilder.java
URL: http://svn.apache.org/viewvc/pig/trunk/src/org/apache/pig/parser/LogicalPlanBuilder.java?rev=1160368&r1=1160367&r2=1160368&view=diff
==============================================================================
--- pig/trunk/src/org/apache/pig/parser/LogicalPlanBuilder.java (original)
+++ pig/trunk/src/org/apache/pig/parser/LogicalPlanBuilder.java Mon Aug 22 18:40:39 2011
@@ -48,7 +48,6 @@ import org.apache.pig.impl.io.FileSpec;
 import org.apache.pig.impl.logicalLayer.FrontendException;
 import org.apache.pig.impl.plan.NodeIdGenerator;
 import org.apache.pig.impl.plan.OperatorKey;
-import org.apache.pig.impl.plan.PlanValidationException;
 import org.apache.pig.impl.streaming.StreamingCommand;
 import org.apache.pig.impl.streaming.StreamingCommand.Handle;
 import org.apache.pig.impl.streaming.StreamingCommand.HandleSpec;
@@ -870,7 +869,7 @@ public class LogicalPlanBuilder {
      * @param endExpr the last expression to be projected, null 
      *        if everything to the end is to be projected
      * @return project expression
-     * @throws PlanValidationException 
+     * @throws ParserValidationException 
      */
     LogicalExpression buildRangeProjectExpr(SourceLocation loc, LogicalExpressionPlan plan, LogicalRelationalOperator relOp,
             int input, LogicalExpression startExpr, LogicalExpression endExpr)

Modified: pig/trunk/src/org/apache/pig/parser/LogicalPlanGenerator.g
URL: http://svn.apache.org/viewvc/pig/trunk/src/org/apache/pig/parser/LogicalPlanGenerator.g?rev=1160368&r1=1160367&r2=1160368&view=diff
==============================================================================
--- pig/trunk/src/org/apache/pig/parser/LogicalPlanGenerator.g (original)
+++ pig/trunk/src/org/apache/pig/parser/LogicalPlanGenerator.g Mon Aug 22 18:40:39 2011
@@ -47,6 +47,7 @@ import org.apache.pig.impl.logicalLayer.
 import org.apache.pig.impl.streaming.StreamingCommand;
 import org.apache.pig.impl.streaming.StreamingCommand.HandleSpec;
 import org.apache.pig.impl.util.MultiMap;
+import org.apache.pig.impl.plan.PlanValidationException;
 import org.apache.pig.newplan.Operator;
 import org.apache.pig.newplan.logical.expression.AddExpression;
 import org.apache.pig.newplan.logical.expression.AndExpression;
@@ -1373,7 +1374,7 @@ scope GScope;
    }
 ;
 
-split_otherwise throws PlanValidationException, PlanGenerationFailureException
+split_otherwise throws PlanGenerationFailureException
 scope GScope;
 @init {
     $GScope::currentOp = builder.createSplitOutputOp();

Modified: pig/trunk/src/org/apache/pig/parser/PigRecognitionException.java
URL: http://svn.apache.org/viewvc/pig/trunk/src/org/apache/pig/parser/PigRecognitionException.java?rev=1160368&r1=1160367&r2=1160368&view=diff
==============================================================================
--- pig/trunk/src/org/apache/pig/parser/PigRecognitionException.java (original)
+++ pig/trunk/src/org/apache/pig/parser/PigRecognitionException.java Mon Aug 22 18:40:39 2011
@@ -34,7 +34,7 @@ public abstract class PigRecognitionExce
     private SourceLocation location;
     
     public PigRecognitionException(IntStream input, SourceLocation loc) {
-        super( input );
+        super( );
         this.line = loc.line();
         this.charPositionInLine = loc.offset();
         this.location = loc;