Changeset: f6aca3fec9f0 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/f6aca3fec9f0
Modified Files:
gdk/gdk_calc.c
monetdb5/modules/atoms/blob.c
sql/server/sql_atom.c
sql/server/sql_atom.h
Branch: Jan2022
Log Message:
More const
diffs (70 lines):
diff --git a/gdk/gdk_calc.c b/gdk/gdk_calc.c
--- a/gdk/gdk_calc.c
+++ b/gdk/gdk_calc.c
@@ -15233,7 +15233,7 @@ BATcalcifthencstelsecst(BAT *b, const Va
*/
#ifdef HAVE_HGE
-static hge scales[39] = {
+static const hge scales[39] = {
(hge) LL_CONSTANT(1),
(hge) LL_CONSTANT(10),
(hge) LL_CONSTANT(100),
@@ -15275,7 +15275,7 @@ static hge scales[39] = {
(hge) LL_CONSTANT(10000000000000000000U) *
LL_CONSTANT(10000000000000000000U)
};
#else
-static lng scales[19] = {
+static const lng scales[19] = {
LL_CONSTANT(1),
LL_CONSTANT(10),
LL_CONSTANT(100),
diff --git a/monetdb5/modules/atoms/blob.c b/monetdb5/modules/atoms/blob.c
--- a/monetdb5/modules/atoms/blob.c
+++ b/monetdb5/modules/atoms/blob.c
@@ -36,7 +36,7 @@
int TYPE_blob;
-static blob nullval = {
+static const blob nullval = {
~(size_t) 0
};
diff --git a/sql/server/sql_atom.c b/sql/server/sql_atom.c
--- a/sql/server/sql_atom.c
+++ b/sql/server/sql_atom.c
@@ -189,7 +189,7 @@ atom_float(sql_allocator *sa, sql_subtyp
}
#ifdef HAVE_HGE
-hge scales[39] = {
+const hge scales[39] = {
(hge) LL_CONSTANT(1),
(hge) LL_CONSTANT(10),
(hge) LL_CONSTANT(100),
@@ -231,7 +231,7 @@ hge scales[39] = {
(hge) LL_CONSTANT(10000000000000000000U) *
LL_CONSTANT(10000000000000000000U)
};
#else
-lng scales[19] = {
+const lng scales[19] = {
LL_CONSTANT(1),
LL_CONSTANT(10),
LL_CONSTANT(100),
diff --git a/sql/server/sql_atom.h b/sql/server/sql_atom.h
--- a/sql/server/sql_atom.h
+++ b/sql/server/sql_atom.h
@@ -61,10 +61,10 @@ extern int atom_is_zero(atom *a);
#ifdef HAVE_HGE
#define MAX_SCALE 39
-extern hge scales[MAX_SCALE];
+extern const hge scales[MAX_SCALE];
#else
#define MAX_SCALE 19
-extern lng scales[MAX_SCALE];
+extern const lng scales[MAX_SCALE];
#endif
extern atom *atom_zero_value(sql_allocator *sa, sql_subtype* tpe);
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list