Update of /cvsroot/monetdb/pathfinder/compiler/algebra
In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv13278/algebra

Modified Files:
      Tag: XQuery_0-24
        logical.c 
Log Message:
-- Corrected type bit inference in the type assertion operator
   (fixes bug #1981783).


U logical.c
Index: logical.c
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/compiler/algebra/logical.c,v
retrieving revision 1.98.2.2
retrieving revision 1.98.2.3
diff -u -d -r1.98.2.2 -r1.98.2.3
--- logical.c   28 May 2008 11:37:20 -0000      1.98.2.2
+++ logical.c   2 Jun 2008 15:19:48 -0000       1.98.2.3
@@ -2368,11 +2368,18 @@
         {
             if (pos)
                 assert_ty = n->schema.items[i].type & ty;
-            else
+            else {
                 /* the restricted type assert_ty is the original
                    type without type ty */
                 assert_ty = n->schema.items[i].type -
                             (n->schema.items[i].type & ty);
+                /* make sure that all node type bits are retained */
+                if (assert_ty & aat_nkind)
+                    assert_ty = assert_ty | aat_pre | aat_frag;
+                /* make sure that all attr type bits are retained */
+                if (assert_ty & aat_attr)
+                    assert_ty = assert_ty | aat_pre | aat_frag;
+            }
             break;
         }
 


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Monetdb-pf-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-pf-checkins

Reply via email to