summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorthep-svn <theppitak@gmail.com>2016-01-20 15:40:33 +0000
committerJihoon Kim <jihoon48.kim@samsung.com>2022-03-10 16:42:52 +0900
commit6e8d522453f4b7a39b2c50ecf5648cbc9c93121b (patch)
tree8966c6877dcdbd57fafb2fb2e4aded5286f3f0fa
parent56b986b5c0fa3c3f2c0bb07139953d27a283ef8c (diff)
downloadlibthai-6e8d522453f4b7a39b2c50ecf5648cbc9c93121b.tar.gz
libthai-6e8d522453f4b7a39b2c50ecf5648cbc9c93121b.tar.bz2
libthai-6e8d522453f4b7a39b2c50ecf5648cbc9c93121b.zip
* include/thai/thctype.h (_th_bitmsk): - Use unsigned int instead of unsigned short for bitmask base, as GCC 6 takes ~0 as -1 for unsigned short, and causes compilation error for scim-thai. Thanks Martin Michlmayr for the report via Debian #811690 http://bugs.debian.org/811690 Change-Id: Id1ad10ac1c73423c6e839f141dab4822248223cd
-rw-r--r--ChangeLog12
-rw-r--r--include/thai/thctype.h2
2 files changed, 13 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 1359b2b..abe6188 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+2016-01-20 Theppitak Karoonboonyanan <theppitak@gmail.com>
+
+ Fix compilation error with GCC 6
+
+ * include/thai/thctype.h (_th_bitmsk):
+ - Use unsigned int instead of unsigned short for bitmask base,
+ as GCC 6 takes ~0 as -1 for unsigned short,
+ and causes compilation error for scim-thai.
+
+ Thanks Martin Michlmayr for the report via Debian #811690
+ http://bugs.debian.org/811690
+
2012-06-12 Theppitak Karoonboonyanan <thep@linux.thai.net>
* configure.in, NEWS:
diff --git a/include/thai/thctype.h b/include/thai/thctype.h
index 2bd6632..df656a2 100644
--- a/include/thai/thctype.h
+++ b/include/thai/thctype.h
@@ -363,7 +363,7 @@ extern int th_iscombchar(thchar_t c);
#include <ctype.h>
#define _th_ISbit(bit) (1 << (bit))
#define _th_bitfld(base, val) ((val) << (base))
-#define _th_bitmsk(base, bits) (~((~(unsigned short)0) << (bits)) << (base))
+#define _th_bitmsk(base, bits) (~((~(unsigned)0) << (bits)) << (base))
enum {
_th_IStis = _th_ISbit(0), /* TIS-620 char */