summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@gmx.de>2013-10-17 12:02:45 +0200
committercinap_lenrek <cinap_lenrek@gmx.de>2013-10-17 12:02:45 +0200
commita5e964190697f7367e92628620baaee370c32f88 (patch)
treef0fc96abf5b9052a503d7bfe6af9025941dc8feb
parente30f50283c60e21763aa28def66deab70ae12187 (diff)
downloadplan9front-a5e964190697f7367e92628620baaee370c32f88.tar.xz
change Rune from ushort to uint for to 21 bit runes (thanks mischief!)
big big change. requires rebuilding 8c first and then rebuild everything.
-rw-r--r--386/include/u.h4
-rw-r--r--68000/include/u.h2
-rw-r--r--68020/include/u.h2
-rw-r--r--alpha/include/u.h4
-rw-r--r--amd64/include/u.h4
-rw-r--r--arm/include/u.h2
-rw-r--r--mips/include/u.h2
-rw-r--r--power/include/u.h4
-rw-r--r--power64/include/u.h2
-rw-r--r--sparc/include/u.h2
-rw-r--r--sparc64/include/u.h2
-rw-r--r--sys/include/ape/limits.h2
-rw-r--r--sys/include/ape/u.h4
-rw-r--r--sys/include/ape/utf.h6
-rw-r--r--sys/include/libc.h6
15 files changed, 24 insertions, 24 deletions
diff --git a/386/include/u.h b/386/include/u.h
index e324c8ad3..ebccf02e8 100644
--- a/386/include/u.h
+++ b/386/include/u.h
@@ -3,12 +3,12 @@ typedef unsigned short ushort;
typedef unsigned char uchar;
typedef unsigned long ulong;
typedef unsigned int uint;
-typedef signed char schar;
+typedef signed char schar;
typedef long long vlong;
typedef unsigned long long uvlong;
typedef unsigned long uintptr;
typedef unsigned long usize;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef long jmp_buf[2];
#define JMPBUFSP 0
diff --git a/68000/include/u.h b/68000/include/u.h
index 50b91a02c..445edbfb4 100644
--- a/68000/include/u.h
+++ b/68000/include/u.h
@@ -8,7 +8,7 @@ typedef long long vlong;
typedef unsigned long long uvlong;
typedef unsigned long uintptr;
typedef unsigned long usize;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef long jmp_buf[2];
#define JMPBUFSP 0
diff --git a/68020/include/u.h b/68020/include/u.h
index 7ff92a408..d4942b8fb 100644
--- a/68020/include/u.h
+++ b/68020/include/u.h
@@ -8,7 +8,7 @@ typedef long long vlong;
typedef unsigned long long uvlong;
typedef unsigned long uintptr;
typedef unsigned long usize;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef long jmp_buf[2];
#define JMPBUFSP 0
diff --git a/alpha/include/u.h b/alpha/include/u.h
index f6614449e..92fea5c7c 100644
--- a/alpha/include/u.h
+++ b/alpha/include/u.h
@@ -3,12 +3,12 @@ typedef unsigned short ushort;
typedef unsigned char uchar;
typedef unsigned long ulong;
typedef unsigned int uint;
-typedef signed char schar;
+typedef signed char schar;
typedef long long vlong;
typedef unsigned long long uvlong;
typedef unsigned long uintptr;
typedef unsigned long usize;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef long jmp_buf[2];
#define JMPBUFSP 0
diff --git a/amd64/include/u.h b/amd64/include/u.h
index 8dce5066f..742de1035 100644
--- a/amd64/include/u.h
+++ b/amd64/include/u.h
@@ -3,12 +3,12 @@ typedef unsigned short ushort;
typedef unsigned char uchar;
typedef unsigned long ulong;
typedef unsigned int uint;
-typedef signed char schar;
+typedef signed char schar;
typedef long long vlong;
typedef unsigned long long uvlong;
typedef unsigned long long uintptr;
typedef unsigned long usize;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef uintptr jmp_buf[2];
#define JMPBUFSP 0
diff --git a/arm/include/u.h b/arm/include/u.h
index db55db33d..916b8cc6f 100644
--- a/arm/include/u.h
+++ b/arm/include/u.h
@@ -9,7 +9,7 @@ typedef long long vlong;
typedef unsigned long long uvlong;
typedef unsigned long uintptr;
typedef unsigned long usize;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef long jmp_buf[2];
#define JMPBUFSP 0
diff --git a/mips/include/u.h b/mips/include/u.h
index 08f7832b7..c30ebd882 100644
--- a/mips/include/u.h
+++ b/mips/include/u.h
@@ -8,7 +8,7 @@ typedef long long vlong;
typedef unsigned long long uvlong;
typedef unsigned long uintptr;
typedef unsigned long usize;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef long jmp_buf[2];
#define JMPBUFSP 0
diff --git a/power/include/u.h b/power/include/u.h
index f84422ccf..27a88d274 100644
--- a/power/include/u.h
+++ b/power/include/u.h
@@ -3,12 +3,12 @@ typedef unsigned short ushort;
typedef unsigned char uchar;
typedef unsigned long ulong;
typedef unsigned int uint;
-typedef signed char schar;
+typedef signed char schar;
typedef long long vlong;
typedef unsigned long long uvlong;
typedef unsigned long uintptr;
typedef unsigned long usize;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef long jmp_buf[2];
#define JMPBUFSP 0
diff --git a/power64/include/u.h b/power64/include/u.h
index d9dbf50be..7f4c22c96 100644
--- a/power64/include/u.h
+++ b/power64/include/u.h
@@ -8,7 +8,7 @@ typedef long long vlong;
typedef unsigned long long uvlong;
typedef unsigned long long uintptr;
typedef unsigned long usize;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef uintptr jmp_buf[2];
#define JMPBUFSP 0
diff --git a/sparc/include/u.h b/sparc/include/u.h
index cc2cb1f97..fe9fbff2d 100644
--- a/sparc/include/u.h
+++ b/sparc/include/u.h
@@ -8,7 +8,7 @@ typedef long long vlong;
typedef unsigned long long uvlong;
typedef unsigned long uintptr;
typedef unsigned long usize;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef long jmp_buf[2];
#define JMPBUFSP 0
diff --git a/sparc64/include/u.h b/sparc64/include/u.h
index cc2cb1f97..fe9fbff2d 100644
--- a/sparc64/include/u.h
+++ b/sparc64/include/u.h
@@ -8,7 +8,7 @@ typedef long long vlong;
typedef unsigned long long uvlong;
typedef unsigned long uintptr;
typedef unsigned long usize;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef long jmp_buf[2];
#define JMPBUFSP 0
diff --git a/sys/include/ape/limits.h b/sys/include/ape/limits.h
index 0837bbe1d..8986b7bf4 100644
--- a/sys/include/ape/limits.h
+++ b/sys/include/ape/limits.h
@@ -3,7 +3,7 @@
/* 8 bit chars (signed), 16 bit shorts, 32 bit ints/longs */
#define CHAR_BIT 8
-#define MB_LEN_MAX 3
+#define MB_LEN_MAX 4
#define UCHAR_MAX 0xff
#define USHRT_MAX 0xffff
diff --git a/sys/include/ape/u.h b/sys/include/ape/u.h
index 87af9d1cd..4ce766194 100644
--- a/sys/include/ape/u.h
+++ b/sys/include/ape/u.h
@@ -9,10 +9,10 @@ typedef unsigned short ushort;
typedef unsigned char uchar;
typedef unsigned long ulong;
typedef unsigned int uint;
-typedef signed char schar;
+typedef signed char schar;
typedef long long vlong;
typedef unsigned long long uvlong;
-typedef ushort Rune;
+typedef uint Rune;
typedef union FPdbleword FPdbleword;
typedef char* p9va_list;
diff --git a/sys/include/ape/utf.h b/sys/include/ape/utf.h
index bba977100..c78b94fee 100644
--- a/sys/include/ape/utf.h
+++ b/sys/include/ape/utf.h
@@ -7,15 +7,15 @@
extern "C" {
#endif
-typedef unsigned short Rune; /* 16 bits */
+typedef unsigned int Rune; /* 32 bits */
enum
{
- UTFmax = 3, /* maximum bytes per rune */
+ UTFmax = 4, /* maximum bytes per rune */
Runesync = 0x80, /* cannot represent part of a UTF sequence (<) */
Runeself = 0x80, /* rune and UTF sequences are the same (<) */
Runeerror = 0xFFFD, /* decoding error in UTF */
- Runemax = 0xFFFF, /* 16 bit rune */
+ Runemax = 0x10FFFF, /* 21 bit rune */
};
/*
diff --git a/sys/include/libc.h b/sys/include/libc.h
index a92e5680d..1300d46d5 100644
--- a/sys/include/libc.h
+++ b/sys/include/libc.h
@@ -41,12 +41,12 @@ extern int tokenize(char*, char**, int);
enum
{
- UTFmax = 3, /* maximum bytes per rune */
+ UTFmax = 4, /* maximum bytes per rune */
Runesync = 0x80, /* cannot represent part of a UTF sequence (<) */
Runeself = 0x80, /* rune and UTF sequences are the same (<) */
Runeerror = 0xFFFD, /* decoding error in UTF */
- Runemax = 0xFFFF, /* 16 bit rune */
- Runemask = 0xFFFF, /* bits used by runes (see grep) */
+ Runemax = 0x10FFFF, /* 21 bit rune */
+ Runemask = 0x1FFFFF, /* bits used by runes (see grep) */
};
/*