Changeset: 2b5348f9236b for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/2b5348f9236b
Modified Files:
monetdb5/modules/atoms/batxml.c
monetdb5/modules/atoms/inet-46.c
monetdb5/modules/atoms/inet.c
monetdb5/modules/atoms/str.c
monetdb5/modules/atoms/streams.c
monetdb5/modules/atoms/url.c
monetdb5/modules/atoms/uuid.c
monetdb5/modules/atoms/xml.c
monetdb5/modules/kernel/aggr.c
monetdb5/modules/kernel/alarm.c
monetdb5/modules/kernel/algebra.c
monetdb5/modules/kernel/bat5.c
monetdb5/modules/kernel/batmmath.c
monetdb5/modules/kernel/batstr.c
monetdb5/modules/kernel/group.c
monetdb5/modules/kernel/microbenchmark.c
monetdb5/modules/kernel/mmath.c
monetdb5/modules/mal/batExtensions.c
monetdb5/modules/mal/batMask.c
monetdb5/modules/mal/bbp.c
monetdb5/modules/mal/calc.c
monetdb5/modules/mal/clients.c
monetdb5/modules/mal/groupby.c
monetdb5/modules/mal/inspect.c
monetdb5/modules/mal/iterator.c
monetdb5/modules/mal/language.c
monetdb5/modules/mal/mal_io.c
monetdb5/modules/mal/mal_mapi.c
monetdb5/modules/mal/manifold.c
monetdb5/modules/mal/manual.c
monetdb5/modules/mal/mat.c
monetdb5/modules/mal/mdb.c
monetdb5/modules/mal/mkey.c
monetdb5/modules/mal/orderidx.c
monetdb5/modules/mal/pcre.c
monetdb5/modules/mal/profiler.c
monetdb5/modules/mal/projectionpath.c
monetdb5/modules/mal/querylog.c
monetdb5/modules/mal/remote.c
monetdb5/modules/mal/sample.c
monetdb5/modules/mal/sysmon.c
monetdb5/modules/mal/tracer.c
monetdb5/modules/mal/txtsim.c
Branch: Dec2025
Log Message:
mel initialization arrays should be static.
diffs (truncated from 533 to 300 lines):
diff --git a/monetdb5/modules/atoms/batxml.c b/monetdb5/modules/atoms/batxml.c
--- a/monetdb5/modules/atoms/batxml.c
+++ b/monetdb5/modules/atoms/batxml.c
@@ -1763,7 +1763,7 @@ AGGRsubxml(Client ctx, bat *retval, cons
#endif /* HAVE_LIBXML */
#include "mel.h"
-mel_func batxml_init_funcs[] = {
+static mel_func batxml_init_funcs[] = {
command("batxml", "xml", BATXMLstr2xml, false, "Cast the string to an xml
compliant string.", args(1,2, batarg("",xml),batarg("src",str))),
command("batxml", "str", BATXMLxml2str, false, "Cast the xml to a string.",
args(1,2, batarg("",str),batarg("src",xml))),
command("batxml", "document", BATXMLdocument, false, "Parse the string as an
XML document.", args(1,2, batarg("",xml),batarg("src",str))),
diff --git a/monetdb5/modules/atoms/inet-46.c b/monetdb5/modules/atoms/inet-46.c
--- a/monetdb5/modules/atoms/inet-46.c
+++ b/monetdb5/modules/atoms/inet-46.c
@@ -1197,7 +1197,7 @@ INETinet6containssymmetricinet6_bulk(Cli
}
#include "mel.h"
-mel_func inet46_init_funcs[] = {
+static mel_func inet46_init_funcs[] = {
command("calc", "inet4", INETinet42inet4, false, "", args(1,2,
arg("",inet4),arg("u",inet4))),
command("calc", "inet4", INETstr2inet4, false, "Coerce a string to an inet4,
validating its format", args(1,2, arg("",inet4),arg("s",str))),
command("batcalc", "inet4", INETinet42inet4_bulk, false, "", args(1,3,
batarg("",inet4),batarg("u",inet4),batarg("c",oid))),
diff --git a/monetdb5/modules/atoms/inet.c b/monetdb5/modules/atoms/inet.c
--- a/monetdb5/modules/atoms/inet.c
+++ b/monetdb5/modules/atoms/inet.c
@@ -826,10 +826,10 @@ INETnull(void)
}
#include "mel.h"
-mel_atom inet_init_atoms[] = {
+static mel_atom inet_init_atoms[] = {
{ .name="inet", .basetype="lng", .size=sizeof(inet), .null=INETnull,
.cmp=INETcompare, .equal=INETequal, .fromstr=INETfromString,
.tostr=INETtoString, }, { .cmp=NULL }
};
-mel_func inet_init_funcs[] = {
+static mel_func inet_init_funcs[] = {
command("inet", "new", INETnew, false, "Create an inet from a string
literal", args(1,2, arg("",inet),arg("s",str))),
command("inet", "isnil", INET_isnil, false, "Nil test for inet value",
args(1,2, arg("",bit),arg("v",inet))),
command("inet", "=", INET_comp_EQ, false, "Equality of two inets", args(1,3,
arg("",bit),arg("v",inet),arg("w",inet))),
diff --git a/monetdb5/modules/atoms/str.c b/monetdb5/modules/atoms/str.c
--- a/monetdb5/modules/atoms/str.c
+++ b/monetdb5/modules/atoms/str.c
@@ -2849,7 +2849,7 @@ STRcontainsjoin(Client ctx, MalBlkPtr mb
}
#include "mel.h"
-mel_func str_init_funcs[] = {
+static mel_func str_init_funcs[] = {
command("str", "str", STRtostr, false, "Noop routine.", args(1,2,
arg("",str),arg("s",str))),
command("str", "string", STRTail, false, "Return the tail
s[offset..n]\nof a string s[0..n].", args(1,3,
arg("",str),arg("s",str),arg("offset",int))),
command("str", "string3", STRSubString, false, "Return substring
s[offset..offset+count] of a string s[0..n]", args(1,4,
arg("",str),arg("s",str),arg("offset",int),arg("count",int))),
diff --git a/monetdb5/modules/atoms/streams.c b/monetdb5/modules/atoms/streams.c
--- a/monetdb5/modules/atoms/streams.c
+++ b/monetdb5/modules/atoms/streams.c
@@ -239,11 +239,11 @@ bstream_read_wrapwrap(Client ctx, int *r
}
#include "mel.h"
-mel_atom streams_init_atoms[] = {
+static mel_atom streams_init_atoms[] = {
{ .name="streams", .basetype="ptr", },
{ .name="bstream", .basetype="ptr", }, { .cmp=NULL }
};
-mel_func streams_init_funcs[] = {
+static mel_func streams_init_funcs[] = {
command("streams", "openReadBytes", mnstr_open_rstreamwrap, true, "open a
file stream for reading", args(1,2, arg("",streams),arg("filename",str))),
command("streams", "openWriteBytes", mnstr_open_wstreamwrap, true, "open a
file stream for writing", args(1,2, arg("",streams),arg("filename",str))),
command("streams", "openRead", mnstr_open_rastreamwrap, true, "open ascii
file stream for reading", args(1,2, arg("",streams),arg("filename",str))),
diff --git a/monetdb5/modules/atoms/url.c b/monetdb5/modules/atoms/url.c
--- a/monetdb5/modules/atoms/url.c
+++ b/monetdb5/modules/atoms/url.c
@@ -1033,10 +1033,10 @@ BATextractURLHost(Client ctx, bat *res,
#include "mel.h"
-mel_atom url_init_atoms[] = {
+static mel_atom url_init_atoms[] = {
{ .name="url", .basetype="str", .fromstr=URLfromString, .tostr=URLtoString,
}, { .cmp=NULL }
};
-mel_func url_init_funcs[] = {
+static mel_func url_init_funcs[] = {
command("url", "url", URLnew, false, "Create an URL from a string literal",
args(1,2, arg("",url),arg("s",str))),
command("url", "url", URLnoop, false, "Create an URL from a string literal",
args(1,2, arg("",url),arg("s",url))),
command("calc", "url", URLnew, false, "Create an URL from a string literal",
args(1,2, arg("",url),arg("s",str))),
diff --git a/monetdb5/modules/atoms/uuid.c b/monetdb5/modules/atoms/uuid.c
--- a/monetdb5/modules/atoms/uuid.c
+++ b/monetdb5/modules/atoms/uuid.c
@@ -492,7 +492,7 @@ UUIDuuid2str_bulk(Client ctx, bat *res,
}
#include "mel.h"
-mel_func uuid_init_funcs[] = {
+static mel_func uuid_init_funcs[] = {
command("uuid", "new", UUIDgenerateUuid, true, "Generate a new uuid",
args(1,1, arg("",uuid))),
command("uuid", "new", UUIDgenerateUuidInt, false, "Generate a new uuid
(dummy version for side effect free multiplex loop)", args(1,2,
arg("",uuid),arg("d",int))),
pattern("batuuid", "new", UUIDgenerateUuidInt_bulk, false, "Generate a new
uuid (dummy version for side effect free multiplex loop)", args(1,2,
batarg("",uuid),batarg("d",int))),
diff --git a/monetdb5/modules/atoms/xml.c b/monetdb5/modules/atoms/xml.c
--- a/monetdb5/modules/atoms/xml.c
+++ b/monetdb5/modules/atoms/xml.c
@@ -912,10 +912,10 @@ XMLepilogue(Client ctx, void *ret)
#endif /* HAVE_LIBXML */
#include "mel.h"
-mel_atom xml_init_atoms[] = {
+static mel_atom xml_init_atoms[] = {
{ .name="xml", .basetype="str", .fromstr=XMLfromString, .tostr=XMLtoString,
}, { .cmp=NULL }
};
-mel_func xml_init_funcs[] = {
+static mel_func xml_init_funcs[] = {
command("xml", "xml", XMLstr2xml, false, "Cast the string to an xml compliant
string", args(1,2, arg("",xml),arg("src",str))),
command("xml", "str", XMLxml2str, false, "Cast the string to an xml compliant
string", args(1,2, arg("",str),arg("src",xml))),
command("xml", "text", XMLxmltext, false, "Extract text from an xml atom",
args(1,2, arg("",str),arg("src",xml))),
diff --git a/monetdb5/modules/kernel/aggr.c b/monetdb5/modules/kernel/aggr.c
--- a/monetdb5/modules/kernel/aggr.c
+++ b/monetdb5/modules/kernel/aggr.c
@@ -1543,7 +1543,7 @@ AGGRsubcorrcand(Client ctx, bat *retval,
}
#include "mel.h"
-mel_func aggr_init_funcs[] = {
+static mel_func aggr_init_funcs[] = {
command("aggr", "sum", AGGRsum3_dbl, false, "Grouped tail sum on bte",
args(1,4, batarg("",dbl),batarg("b",bte),batarg("g",oid),batargany("e",1))),
command("aggr", "sum", AGGRsum3_bte, false, "Grouped tail sum on bte",
args(1,4, batarg("",bte),batarg("b",bte),batarg("g",oid),batargany("e",1))),
command("aggr", "subsum", AGGRsubsum_bte, false, "Grouped sum aggregate",
args(1,5,
batarg("",bte),batarg("b",bte),batarg("g",oid),batargany("e",1),arg("skip_nils",bit))),
diff --git a/monetdb5/modules/kernel/alarm.c b/monetdb5/modules/kernel/alarm.c
--- a/monetdb5/modules/kernel/alarm.c
+++ b/monetdb5/modules/kernel/alarm.c
@@ -114,7 +114,7 @@ ALARMtime(Client ctx, int *res)
}
#include "mel.h"
-mel_func alarm_init_funcs[] = {
+static mel_func alarm_init_funcs[] = {
pattern("alarm", "sleep", ALARMsleep, true, "Sleep a few milliseconds",
args(1,2, arg("",void),argany("msecs",1))),
pattern("alarm", "sleep", ALARMsleep, true, "Sleep a few milliseconds and
return the slept value", args(1,2, argany("",1),argany("msecs",1))),
command("alarm", "usec", ALARMusec, true, "Return time since Jan 1, 1970 in
microseconds.", args(1,1, arg("",lng))),
diff --git a/monetdb5/modules/kernel/algebra.c
b/monetdb5/modules/kernel/algebra.c
--- a/monetdb5/modules/kernel/algebra.c
+++ b/monetdb5/modules/kernel/algebra.c
@@ -1896,7 +1896,7 @@ ALGcorr(Client ctx, dbl *res, const bat
}
#include "mel.h"
-mel_func algebra_init_funcs[] = {
+static mel_func algebra_init_funcs[] = {
command("algebra", "groupby", ALGgroupby, false, "Produces a new BAT with
groups identified by the head column. The result contains tail times the head
value, ie the tail contains the result group sizes.", args(1,3,
batarg("",oid),batarg("gids",oid),batarg("cnts",lng))),
command("algebra", "find", ALGfind, false, "Returns the index position of a
value. If no such BUN exists return OID-nil.", args(1,3,
arg("",oid),batargany("b",1),argany("t",1))),
command("algebra", "fetch", ALGfetchoid, false, "Returns the value of the BUN
at x-th position with 0 <= x < b.count", args(1,3,
argany("",1),batargany("b",1),arg("x",oid))),
diff --git a/monetdb5/modules/kernel/bat5.c b/monetdb5/modules/kernel/bat5.c
--- a/monetdb5/modules/kernel/bat5.c
+++ b/monetdb5/modules/kernel/bat5.c
@@ -1074,7 +1074,7 @@ BKCdiffcand(Client ctx, bat *ret, const
}
#include "mel.h"
-mel_func bat5_init_funcs[] = {
+static mel_func bat5_init_funcs[] = {
command("bat", "mirror", BKCmirror, false, "Returns the head-mirror image of
a BAT (two head columns).", args(1,2, batarg("",oid),batargany("b",1))),
command("bat", "delete", BKCdelete, false, "Delete BUN indicated by head
value, exchanging with last BUN", args(1,3,
batargany("",1),batargany("b",1),arg("h",oid))),
command("bat", "delete", BKCdelete_multi, false, "Delete multiple BUN,
shifting BUNs up", args(1,3, batargany("",1),batargany("b",1),batarg("d",oid))),
diff --git a/monetdb5/modules/kernel/batmmath.c
b/monetdb5/modules/kernel/batmmath.c
--- a/monetdb5/modules/kernel/batmmath.c
+++ b/monetdb5/modules/kernel/batmmath.c
@@ -451,7 +451,7 @@ scienceBinaryImpl(pow)
scienceBinaryImpl(logbs)
#include "mel.h"
-mel_func batmmath_init_funcs[] = {
+static mel_func batmmath_init_funcs[] = {
pattern("batmmath", "asin", CMDscience_bat_asin, false, "", args(1,2,
batarg("",dbl),batarg("x",dbl))),
pattern("batmmath", "asin", CMDscience_bat_asin, false, "", args(1,3,
batarg("",dbl),batarg("x",dbl),batarg("s",oid))),
pattern("batmmath", "asin", CMDscience_bat_asin, false, "", args(1,2,
batarg("",flt),batarg("x",flt))),
diff --git a/monetdb5/modules/kernel/batstr.c b/monetdb5/modules/kernel/batstr.c
--- a/monetdb5/modules/kernel/batstr.c
+++ b/monetdb5/modules/kernel/batstr.c
@@ -5857,7 +5857,7 @@ BATSTRasciify(Client cntxt, MalBlkPtr mb
}
#include "mel.h"
-mel_func batstr_init_funcs[] = {
+static mel_func batstr_init_funcs[] = {
pattern("batstr", "length", STRbatLength, false, "Return the length of
a string.", args(1,2, batarg("",int),batarg("s",str))),
pattern("batstr", "length", STRbatLength, false, "Return the length of
a string.", args(1,3, batarg("",int),batarg("s",str),batarg("s",oid))),
pattern("batstr", "nbytes", STRbatBytes, false, "Return the string
length in bytes.", args(1,2, batarg("",int),batarg("s",str))),
diff --git a/monetdb5/modules/kernel/group.c b/monetdb5/modules/kernel/group.c
--- a/monetdb5/modules/kernel/group.c
+++ b/monetdb5/modules/kernel/group.c
@@ -174,7 +174,7 @@ GRPsubgroup21(Client ctx, bat *ngid, con
}
#include "mel.h"
-mel_func group_init_funcs[] = {
+static mel_func group_init_funcs[] = {
command("group", "group", GRPgroup1, false, "", args(3,4,
batarg("groups",oid),batarg("extents",oid),batarg("histo",lng),batargany("b",1))),
command("group", "group", GRPgroup2, false, "", args(3,5,
batarg("groups",oid),batarg("extents",oid),batarg("histo",lng),batargany("b",1),batarg("s",oid))),
command("group", "group", GRPgroup3, false, "", args(2,3,
batarg("groups",oid),batarg("extents",oid),batargany("b",1))),
diff --git a/monetdb5/modules/kernel/microbenchmark.c
b/monetdb5/modules/kernel/microbenchmark.c
--- a/monetdb5/modules/kernel/microbenchmark.c
+++ b/monetdb5/modules/kernel/microbenchmark.c
@@ -416,7 +416,7 @@ MBMskewed(Client ctx, bat *ret, const oi
}
#include "mel.h"
-mel_func microbenchmark_init_funcs[] = {
+static mel_func microbenchmark_init_funcs[] = {
command("microbenchmark", "random", MBMrandom, false, "Create a BAT with
random integer distribution; domain == nil:int ? [0:RAND_MAX] : [0,domain)",
args(1,4, batarg("",int),arg("base",oid),arg("size",lng),arg("domain",int))),
command("microbenchmark", "random", MBMrandom_seed, false, "Create a BAT with
random integer distribution,\nusing given seed (seed == nil:int -> no seed
used);\ndomain == nil:int ? [0:RAND_MAX] : [0,domain)", args(1,5,
batarg("",int),arg("base",oid),arg("size",lng),arg("domain",int),arg("seed",int))),
command("microbenchmark", "uniform", MBMuniform, false, "Create a BAT with
uniform integer distribution", args(1,4,
batarg("",int),arg("base",oid),arg("size",lng),arg("domain",int))),
diff --git a/monetdb5/modules/kernel/mmath.c b/monetdb5/modules/kernel/mmath.c
--- a/monetdb5/modules/kernel/mmath.c
+++ b/monetdb5/modules/kernel/mmath.c
@@ -333,7 +333,7 @@ MATHpi(Client ctx, dbl *pi)
}
#include "mel.h"
-mel_func mmath_init_funcs[] = {
+static mel_func mmath_init_funcs[] = {
command("mmath", "acos", MATHunary_ACOSflt, false, "", args(1,2,
arg("",flt),arg("x",flt))),
command("mmath", "acos", MATHunary_ACOSdbl, false, "The acos(x) function
calculates the arc cosine of x, that is the \nvalue whose cosine is x. The
value is returned in radians and is \nmathematically defined to be between 0
and PI (inclusive).", args(1,2, arg("",dbl),arg("x",dbl))),
command("mmath", "asin", MATHunary_ASINflt, false, "", args(1,2,
arg("",flt),arg("x",flt))),
diff --git a/monetdb5/modules/mal/batExtensions.c
b/monetdb5/modules/mal/batExtensions.c
--- a/monetdb5/modules/mal/batExtensions.c
+++ b/monetdb5/modules/mal/batExtensions.c
@@ -280,7 +280,7 @@ CMDBATvacuum(Client ctx, bat *r, const b
}
#include "mel.h"
-mel_func batExtensions_init_funcs[] = {
+static mel_func batExtensions_init_funcs[] = {
pattern("bat", "new", CMDBATnew, false, "", args(1,2,
batargany("",1),argany("tt",1))),
pattern("bat", "new", CMDBATnew, false, "", args(1,3,
batargany("",1),argany("tt",1),arg("size",int))),
pattern("bat", "new", CMDBATnew, false, "", args(1,4,
batargany("",1),argany("tt",1),arg("size",lng),arg("persist",bit))),
diff --git a/monetdb5/modules/mal/batMask.c b/monetdb5/modules/mal/batMask.c
--- a/monetdb5/modules/mal/batMask.c
+++ b/monetdb5/modules/mal/batMask.c
@@ -128,7 +128,7 @@ MSKumask(Client cntxt, MalBlkPtr mb, Mal
#include "mel.h"
-mel_func batMask_init_funcs[] = {
+static mel_func batMask_init_funcs[] = {
pattern("mask", "mask", MSKmask, false, "", args(1,2, batarg("r", msk),
batarg("b",oid))),
pattern("mask", "umask", MSKumask, false, "", args(1,2, batarg("r", oid),
batarg("b",msk))),
{ .imp=NULL }
diff --git a/monetdb5/modules/mal/bbp.c b/monetdb5/modules/mal/bbp.c
--- a/monetdb5/modules/mal/bbp.c
+++ b/monetdb5/modules/mal/bbp.c
@@ -549,7 +549,7 @@ CMDsetName(Client ctx, str *rname, const
}
#include "mel.h"
-mel_func bbp_init_funcs[] = {
+static mel_func bbp_init_funcs[] = {
pattern("bbp", "bind", CMDbbpbind, false, "Locate the BAT using its logical
name", args(1,2, batargany("",1),arg("name",str))),
command("bbp", "getIndex", CMDbbpgetIndex, false, "Retrieve the index in the
BBP", args(1,2, arg("",int),batargany("b",1))),
command("bbp", "getNames", CMDbbpNames, false, "Map BAT into its bbp name",
args(1,1, batarg("",str))),
diff --git a/monetdb5/modules/mal/calc.c b/monetdb5/modules/mal/calc.c
--- a/monetdb5/modules/mal/calc.c
+++ b/monetdb5/modules/mal/calc.c
@@ -896,7 +896,7 @@ CMDBATavg3comb(Client cntxt, MalBlkPtr m
}
#include "mel.h"
-mel_func calc_init_funcs[] = {
+static mel_func calc_init_funcs[] = {
#ifdef HAVE_HGE
pattern("calc", "iszero", CMDvarISZERO, false, "Unary check for zero of V",
args(1,2, arg("",bit),arg("v",hge))),
pattern("calc", "not", CMDvarNOT, false, "Unary bitwise not of V", args(1,2,
arg("",hge),arg("v",hge))),
diff --git a/monetdb5/modules/mal/clients.c b/monetdb5/modules/mal/clients.c
--- a/monetdb5/modules/mal/clients.c
+++ b/monetdb5/modules/mal/clients.c
@@ -796,7 +796,7 @@ CLTsetClientInfo(Client ctx, MalBlkPtr m
}
#include "mel.h"
-mel_func clients_init_funcs[] = {
+static mel_func clients_init_funcs[] = {
pattern("clients", "setListing", CLTsetListing, true, "Turn on/off echo of
MAL instructions:\n1 - echo input,\n2 - show mal instruction,\n4 - show details
of type resolutoin, \n8 - show binding information.", args(1,2,
arg("",int),arg("flag",int))),
pattern("clients", "getId", CLTgetClientId, false, "Return a number that
uniquely represents the current client.", args(1,1, arg("",int))),
pattern("clients", "getInfo", CLTInfo, false, "Pseudo bat with client
attributes.", args(2,2, batarg("",str),batarg("",str))),
diff --git a/monetdb5/modules/mal/groupby.c b/monetdb5/modules/mal/groupby.c
--- a/monetdb5/modules/mal/groupby.c
+++ b/monetdb5/modules/mal/groupby.c
@@ -219,7 +219,7 @@ GROUPmulticolumngroup(Client cntxt, MalB
}
#include "mel.h"
-mel_func groupby_init_funcs[] = {
+static mel_func groupby_init_funcs[] = {
pattern("group", "multicolumn", GROUPmulticolumngroup, false, "Derivation of
a group index over multiple columns.", args(3,4,
batarg("ref",oid),batarg("grp",oid),batargany("hist",0),batvarargany("b",0))),
{ .imp=NULL }
};
diff --git a/monetdb5/modules/mal/inspect.c b/monetdb5/modules/mal/inspect.c
--- a/monetdb5/modules/mal/inspect.c
+++ b/monetdb5/modules/mal/inspect.c
@@ -669,7 +669,7 @@ INSPECTtypeName(Client cntxt, MalBlkPtr
}
#include "mel.h"
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]