Update of /cvsroot/monetdb/sql/src/backends/monet5
In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv5515

Modified Files:
        sql_gencode.mx 
Log Message:
Make the return type for table returning functions more precise


U sql_gencode.mx
Index: sql_gencode.mx
===================================================================
RCS file: /cvsroot/monetdb/sql/src/backends/monet5/sql_gencode.mx,v
retrieving revision 1.278
retrieving revision 1.279
diff -u -d -r1.278 -r1.279
--- sql_gencode.mx      17 Jun 2008 10:34:59 -0000      1.278
+++ sql_gencode.mx      13 Jul 2008 14:20:09 -0000      1.279
@@ -2060,6 +2060,7 @@
                return;
        f->sql++;
        s = scope_sqlparse(m, NULL, f->imp, m_instantiate);
+       assert(s);
        if (s) {
                stmt *opt;
                opt = optimize(m, s);
@@ -2078,7 +2079,10 @@
        varSetProp(curBlk, getArg(curInstr, 0), inlineProp, op_eq, NULL);
 
        if (f->res.type) { 
-               setVarType(curBlk, 0, f->res.type->localtype);
+               if (f->res.type->localtype == TYPE_bat)
+                       setVarType(curBlk, 0, newBatType(TYPE_str, TYPE_bat));
+               else
+                       setVarType(curBlk, 0, f->res.type->localtype);
                setVarUDFtype(curBlk,0);
        } else {
                setVarType(curBlk, 0, TYPE_void);


-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Monetdb-sql-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-sql-checkins

Reply via email to