[mono-vb] Poor state of mb-parser.jay

K SatyaSudha ksathyasudha@novell.com
Tue, 22 Mar 2005 20:14:58 -0700


This is a MIME message. If you are reading this text, you may want to 
consider changing to a mail reader or gateway that understands how to 
properly handle MIME multipart messages.

--=__Part97B49822.1__=
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

Hey Rafael,

Thanks for pointing this out. This has been fixed now. 

Thanks,
Sudha.

>>> Rafael Teixeira <monoman@gmail.com> 03/21/05 11:19 PM >>>
Sathya,

It seems the rules added to support the LIKE operator in your latest
commit are giving recursive problems, as jay tell us:

make[1]: Entering directory `/home/rafael/source/cli/mcs/mbas'
../jay/jay -ctv <../jay/skeleton.cs mb-parser.jay >mb-parser.cs
../jay/jay: 358 shift/reduce conflicts, 154 reduce/reduce conflicts.

reduce/reduce conflicts normally make lots of false errors appear
while parsing, but it doesn't show up in my limited testing
(Test/misc).

I hope you can shortly bring those numbers down.

Sorry if I can't jump in to help just now. 

My advice is to look carefully at the y.output file to see what is
happenning. Probably your new rules are colliding with the way the
other rules deal with the end-of-statement part.

Fun,

-- 
Rafael "Monoman" Teixeira
---------------------------------------
I'm trying to become a "Rosh Gadol" before my own eyes. 
See http://www.joelonsoftware.com/items/2004/12/06.html for
enlightment.
It hurts!
_______________________________________________
Mono-vb mailing list
Mono-vb@lists.ximian.com 
http://lists.ximian.com/mailman/listinfo/mono-vb
--=__Part97B49822.1__=
Content-Type: message/rfc822

Return-path: <mono-patches-admin@ximian.com>
Received: from OLYMPUS.novell.com [130.57.1.24]
	by lucius.provo.novell.com; Tue, 22 Mar 2005 03:18:43 -0700
Received: from lists.ximian.com (unverified [130.57.169.17]) by OLYMPUS.novell.com
 (Vircom SMTPRS 4.0.346.0) with ESMTP id <C0029607018@OLYMPUS.novell.com>;
 Tue, 22 Mar 2005 03:20:37 -0700
Received: from headcheese.ximian.com (localhost [127.0.0.1])
	by lists.ximian.com (Postfix) with ESMTP
	id CD36F12415B; Tue, 22 Mar 2005 05:18:41 -0500 (EST)
Received: by lists.ximian.com (Postfix, from userid 38)
	id 1891A124A26; Tue, 22 Mar 2005 05:16:38 -0500 (EST)
Received: from mono-cvs.ximian.com (mono-cvs.ximian.com [130.57.169.27])
	by lists.ximian.com (Postfix) with ESMTP id 061DB1240D5
	for <mono-patches@lists.ximian.com>; Tue, 22 Mar 2005 05:16:26 -0500 (EST)
Received: by mono-cvs.ximian.com (Postfix, from userid 1282)
	id 6833794765; Tue, 22 Mar 2005 04:51:00 -0500 (EST)
To: mono-patches@lists.ximian.com
From: "Sudha <ksathyasudha@novell.com>" <sudha@mono-cvs.ximian.com>
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Message-Id: <20050322095100.6833794765@mono-cvs.ximian.com>
X-Spam-Status: No, hits=0.7 required=5.0
	tests=PATCH_UNIFIED_DIFF,RCVD_IN_ORBS,RCVD_IN_OSIRUSOFT_COM
	version=2.53
X-Spam-Level: 
X-Spam-Checker-Version: SpamAssassin 2.53 (1.174.2.15-2003-03-30-exp)
Subject: [Mono-patches] r42073 - trunk/mcs/mbas
Sender: mono-patches-admin@ximian.com
Errors-To: mono-patches-admin@ximian.com
X-BeenThere: mono-patches@ximian.com
X-Mailman-Version: 2.0.13
Precedence: bulk
List-Help: <mailto:mono-patches-request@ximian.com?subject=help>
List-Post: <mailto:mono-patches@ximian.com>
List-Subscribe: <http://lists.ximian.com/mailman/listinfo/mono-patches>,
	<mailto:mono-patches-request@ximian.com?subject=subscribe>
List-Id: Patches to the Mono project are posted on this mailing list. <mono-patches.ximian.com>
List-Unsubscribe: <http://lists.ximian.com/mailman/listinfo/mono-patches>,
	<mailto:mono-patches-request@ximian.com?subject=unsubscribe>
List-Archive: <http://lists.ximian.com/archives/public/mono-patches/>
Date: Tue, 22 Mar 2005 04:51:00 -0500 (EST)

Author: sudha
Date: 2005-03-22 04:51:00 -0500 (Tue, 22 Mar 2005)
New Revision: 42073

Modified:
   trunk/mcs/mbas/ChangeLog
   trunk/mcs/mbas/mb-parser.jay
Log:
Patch for reducing conflicts in grammar - by Sudharsan V


Modified: trunk/mcs/mbas/ChangeLog
===================================================================
--- trunk/mcs/mbas/ChangeLog	2005-03-22 09:45:46 UTC (rev 42072)
+++ trunk/mcs/mbas/ChangeLog	2005-03-22 09:51:00 UTC (rev 42073)
@@ -1,3 +1,8 @@
+2005-03-22 Satya Sudha K <ksathyasudha@novell.com>
+	   Sudharsan V <vsudharsan@novell.com>
+	* mb-parser.jay : 
+			Removed some conflicts in the grammar
+
 2005-03-21 Manjula GHM <mmanjula@novell.com>
 	* statement.cs: Implementation of 'End' Statement which terminates execution immediately
 

Modified: trunk/mcs/mbas/mb-parser.jay
===================================================================
--- trunk/mcs/mbas/mb-parser.jay	2005-03-22 09:45:46 UTC (rev 42072)
+++ trunk/mcs/mbas/mb-parser.jay	2005-03-22 09:51:00 UTC (rev 42073)
@@ -866,20 +866,20 @@
 	: /* empty */	{ $$ = Parameters.EmptyReadOnlyParameters; }
 	| OPEN_PARENS CLOSE_PARENS	{ $$ = Parameters.EmptyReadOnlyParameters; }
 	| OPEN_PARENS _mark_ opt_formal_parameter_list CLOSE_PARENS	{ $$ = $3; }
-	| OPEN_PARENS _mark_
+	| OPEN_PARENS _mark_ error
 	  {
 		Report.Error(30203,(Location)$2, "Identifier Expected"); 
 		$$ = Parameters.EmptyReadOnlyParameters;
    	  }
-	| OPEN_PARENS _mark_ opt_formal_parameter_list 
+	| OPEN_PARENS _mark_ opt_formal_parameter_list error
 	  {
 		Report.Error(30198,(Location)$2, "'(' is not having a matching ')'"); 
 		$$ = $3;
 	  }
-	| _mark_ opt_formal_parameter_list CLOSE_PARENS 
+	| error _mark_ opt_formal_parameter_list CLOSE_PARENS 
 	  {
-		Report.Error(30205,(Location)$1, "')' is not having a matching '('"); 
-		$$ = $2;
+		Report.Error(30205,(Location)$2, "')' is not having a matching '('"); 
+		$$ = $3;
 	  }
 	;
 
@@ -3357,12 +3357,12 @@
         {
 		 $$ = new DictionaryEntry ($4, $1); 
 	}
-	| _mark_ AS type
+	| error _mark_ AS type
 	{
-		Report.Error(30203, (Location)$1, "Identifier Expected");
+		Report.Error(30203, (Location)$2, "Identifier Expected");
 		$$ = null;
 	}
-	| identifier AS _mark_   
+	| identifier AS _mark_ error  
 	{
 		Report.Error(30182, (Location)$3, "Type Expected");
 		$$ = null;
@@ -4414,9 +4414,8 @@
 	//| element_access
 	| new_expression
 	| cast_expression
-	| /*empty*/ _mark_ 
-					     { Report.Error(30201,(Location)$1,"Expression expected"); $$ = (Expression)null;}
-                             
+	| error _mark_ 
+	     { Report.Error(30201,(Location)$2,"Expression expected"); $$ = (Expression)null;}
 	;
 
 literal
@@ -4768,10 +4767,10 @@
 
 relational_expression
 	: shift_expression
-	| relational_expression _mark_ LIKE shift_expression
+	| relational_expression LIKE _mark_ shift_expression
 	  {
 		$$ = new Binary (Binary.Operator.Like,
-			         (Expression) $1, (Expression) $4, (Location)$2);
+			         (Expression) $1, (Expression) $4, (Location)$3);
 	  }
 	| relational_expression ASSIGN _mark_ shift_expression
 	  {
@@ -5156,8 +5155,6 @@
 	  {$$ = 1;}
 	| LOOP
 	  {$$ = 2;}
-	| /* empty */ 
-	  {$$ = 0;} 
 	;
 
 opt_block_types

_______________________________________________
Mono-patches maillist  -  Mono-patches@ximian.com
http://lists.ximian.com/mailman/listinfo/mono-patches

--=__Part97B49822.1__=--