summaryrefslogtreecommitdiff
path: root/contrib/pg_trgm/trgm.h
diff options
context:
space:
mode:
authorPeter Eisentraut2011-09-11 18:54:32 +0000
committerPeter Eisentraut2011-09-11 18:54:32 +0000
commit1b81c2fe6ee2b26d37610c3d381a87fa17af0a7c (patch)
tree09075f19d47fd81df20beb96e27e0f21ad2a0729 /contrib/pg_trgm/trgm.h
parent02bca4f35164dd1873eab9b8e6167e42a79157c4 (diff)
Remove many -Wcast-qual warnings
This addresses only those cases that are easy to fix by adding or moving a const qualifier or removing an unnecessary cast. There are many more complicated cases remaining.
Diffstat (limited to 'contrib/pg_trgm/trgm.h')
-rw-r--r--contrib/pg_trgm/trgm.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/pg_trgm/trgm.h b/contrib/pg_trgm/trgm.h
index 61de5d89d16..067f29d4daf 100644
--- a/contrib/pg_trgm/trgm.h
+++ b/contrib/pg_trgm/trgm.h
@@ -33,7 +33,7 @@
typedef char trgm[3];
#define CMPCHAR(a,b) ( ((a)==(b)) ? 0 : ( ((a)<(b)) ? -1 : 1 ) )
-#define CMPPCHAR(a,b,i) CMPCHAR( *(((char*)(a))+i), *(((char*)(b))+i) )
+#define CMPPCHAR(a,b,i) CMPCHAR( *(((const char*)(a))+i), *(((const char*)(b))+i) )
#define CMPTRGM(a,b) ( CMPPCHAR(a,b,0) ? CMPPCHAR(a,b,0) : ( CMPPCHAR(a,b,1) ? CMPPCHAR(a,b,1) : CMPPCHAR(a,b,2) ) )
#define CPTRGM(a,b) do { \