Import Tcl 8.6.11
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
# UnicodeData file from:
|
||||
# ftp://ftp.unicode.org/Public/UNIDATA/UnicodeData.txt
|
||||
#
|
||||
# Copyright (c) 1998-1999 by Scriptics Corporation.
|
||||
# Copyright (c) 1998-1999 Scriptics Corporation.
|
||||
# All rights reserved.
|
||||
|
||||
|
||||
@@ -68,7 +68,7 @@ proc uni::getGroup {value} {
|
||||
variable groups
|
||||
|
||||
set gIndex [lsearch -exact $groups $value]
|
||||
if {$gIndex == -1} {
|
||||
if {$gIndex < 0} {
|
||||
set gIndex [llength $groups]
|
||||
lappend groups $value
|
||||
}
|
||||
@@ -81,7 +81,7 @@ proc uni::addPage {info} {
|
||||
variable shift
|
||||
|
||||
set pIndex [lsearch -exact $pages $info]
|
||||
if {$pIndex == -1} {
|
||||
if {$pIndex < 0} {
|
||||
set pIndex [llength $pages]
|
||||
lappend pages $info
|
||||
}
|
||||
@@ -114,8 +114,8 @@ proc uni::buildTables {data} {
|
||||
set items [split $line \;]
|
||||
|
||||
scan [lindex $items 0] %x index
|
||||
if {$index > 0x2ffff} then {
|
||||
# Ignore non-BMP characters, as long as Tcl doesn't support them
|
||||
if {$index > 0x3FFFF} then {
|
||||
# Ignore characters > plane 3
|
||||
continue
|
||||
}
|
||||
set index [format %d $index]
|
||||
@@ -185,7 +185,7 @@ proc uni::main {} {
|
||||
* automatically generated by the tools/uniParse.tcl script. Do not
|
||||
* modify this file by hand.
|
||||
*
|
||||
* Copyright (c) 1998 by Scriptics Corporation.
|
||||
* Copyright (c) 1998 Scriptics Corporation.
|
||||
* All rights reserved.
|
||||
*/
|
||||
|
||||
@@ -343,9 +343,9 @@ static const int groups\[\] = {"
|
||||
puts -nonewline $f "};
|
||||
|
||||
#if TCL_UTF_MAX > 3 || TCL_MAJOR_VERSION > 8 || TCL_MINOR_VERSION > 6
|
||||
# define UNICODE_OUT_OF_RANGE(ch) (((ch) & 0x1fffff) >= [format 0x%x $next])
|
||||
# define UNICODE_OUT_OF_RANGE(ch) (((ch) & 0x1FFFFF) >= [format 0x%X $next])
|
||||
#else
|
||||
# define UNICODE_OUT_OF_RANGE(ch) (((ch) & 0x1f0000) != 0)
|
||||
# define UNICODE_OUT_OF_RANGE(ch) (((ch) & 0x1F0000) != 0)
|
||||
#endif
|
||||
|
||||
/*
|
||||
@@ -392,8 +392,8 @@ enum {
|
||||
* to do sign extension on right shifts.
|
||||
*/
|
||||
|
||||
#define GetCaseType(info) (((info) & 0xe0) >> 5)
|
||||
#define GetCategory(ch) (GetUniCharInfo(ch) & 0x1f)
|
||||
#define GetCaseType(info) (((info) & 0xE0) >> 5)
|
||||
#define GetCategory(ch) (GetUniCharInfo(ch) & 0x1F)
|
||||
#define GetDelta(info) ((info) >> 8)
|
||||
|
||||
/*
|
||||
@@ -402,9 +402,9 @@ enum {
|
||||
*/
|
||||
|
||||
#if TCL_UTF_MAX > 3 || TCL_MAJOR_VERSION > 8 || TCL_MINOR_VERSION > 6
|
||||
# define GetUniCharInfo(ch) (groups\[groupMap\[pageMap\[((ch) & 0x1fffff) >> OFFSET_BITS\] | ((ch) & ((1 << OFFSET_BITS)-1))\]\])
|
||||
# define GetUniCharInfo(ch) (groups\[groupMap\[pageMap\[((ch) & 0x1FFFFF) >> OFFSET_BITS\] | ((ch) & ((1 << OFFSET_BITS)-1))\]\])
|
||||
#else
|
||||
# define GetUniCharInfo(ch) (groups\[groupMap\[pageMap\[((ch) & 0xffff) >> OFFSET_BITS\] | ((ch) & ((1 << OFFSET_BITS)-1))\]\])
|
||||
# define GetUniCharInfo(ch) (groups\[groupMap\[pageMap\[((ch) & 0xFFFF) >> OFFSET_BITS\] | ((ch) & ((1 << OFFSET_BITS)-1))\]\])
|
||||
#endif
|
||||
"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user