Update of /cvsroot/monetdb/pathfinder/compiler/core
In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv2478/core

Modified Files:
      Tag: XQuery_0-16
        fs.brg 
Log Message:
Until now, document managenment functions could not be called from
user-defined functions (`docmgmt' is not a subtype of `item*').

Similar in spririt to the `declare updating function' syntax in the
W3C Update Facility, we now have the syntax extension

  declare document management function foo(...)
  {
    ...
  };

That sets the return type `docmgmt*' for the respective function.

(I have the magic ability to foresee Peter's reactions on lengthy
syntax such as `declare document management function'.  Based on my
predictive abilities, I also included the short-hand `declare
docmgmt function' for Peter's convenience. ;-))


Index: fs.brg
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/compiler/core/fs.brg,v
retrieving revision 1.52.2.1
retrieving revision 1.52.2.2
diff -u -d -r1.52.2.1 -r1.52.2.2
--- fs.brg      9 Feb 2007 15:21:38 -0000       1.52.2.1
+++ fs.brg      14 Feb 2007 10:27:11 -0000      1.52.2.2
@@ -209,6 +209,7 @@
 %term    recursion      = 126
 %term    seed           = 127
 %term    xrpc           = 128
+%term    docmgmt_ty     = 129
 
 %%
 
@@ -621,6 +622,9 @@
 /* Pathfinder extension: XRPC */
 XRPCCall:               xrpc (Expr, FunctionCall)                   = 235 (10);
 
+/* Pathfinder extension: statement type for document management functions */
+SequenceType:           seq_ty (docmgmt_ty (nil))                   = 236 (10);
+
 %%
 
 /*
@@ -4017,6 +4021,14 @@
                          xrpc (var (v3), C(R(p))));
         } break;
 
+        /* SequenceType:           seq_ty (docmgmt_ty (nil)) */
+        case 236:
+            /*
+             * statement type for document managemtn user-defined functions.
+             */
+            C(p) = seqtype (PFty_star (PFty_docmgmt ()));
+            break;
+
         default:
             PFoops_loc (OOPS_FATAL, p->loc, "untranslated expression");
             break;


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Monetdb-pf-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-pf-checkins

Reply via email to