summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.fossil-settings/ignore-glob4
-rw-r--r--.travis.yml152
-rw-r--r--doc/Tcl.n8
-rw-r--r--doc/ToUpper.36
-rw-r--r--doc/Utf.39
-rw-r--r--doc/array.n2
-rw-r--r--doc/cookiejar.n2
-rw-r--r--doc/define.n2
-rw-r--r--doc/expr.n3
-rw-r--r--doc/info.n384
-rw-r--r--doc/mathop.n9
-rw-r--r--doc/timerate.n129
-rw-r--r--doc/zipfs.n5
-rw-r--r--generic/regc_locale.c329
-rw-r--r--generic/regcomp.c19
-rw-r--r--generic/regexec.c8
-rw-r--r--generic/tcl.decls2
-rw-r--r--generic/tclAlloc.c6
-rw-r--r--generic/tclBasic.c34
-rw-r--r--generic/tclBinary.c88
-rw-r--r--generic/tclCkalloc.c8
-rw-r--r--generic/tclClock.c11
-rw-r--r--generic/tclCmdAH.c6
-rw-r--r--generic/tclCmdMZ.c444
-rw-r--r--generic/tclCompCmdsGR.c2
-rw-r--r--generic/tclCompCmdsSZ.c2
-rw-r--r--generic/tclCompExpr.c6
-rw-r--r--generic/tclCompile.c14
-rw-r--r--generic/tclDecls.h7
-rw-r--r--generic/tclDictObj.c2
-rw-r--r--generic/tclDisassemble.c8
-rw-r--r--generic/tclEncoding.c85
-rw-r--r--generic/tclEnsemble.c4
-rw-r--r--generic/tclEnv.c25
-rw-r--r--generic/tclExecute.c58
-rw-r--r--generic/tclFileName.c10
-rw-r--r--generic/tclHash.c4
-rw-r--r--generic/tclIO.c22
-rw-r--r--generic/tclIOCmd.c2
-rw-r--r--generic/tclIORChan.c6
-rw-r--r--generic/tclIORTrans.c10
-rw-r--r--generic/tclIOUtil.c2
-rw-r--r--generic/tclIndexObj.c8
-rw-r--r--generic/tclInt.h51
-rw-r--r--generic/tclInterp.c12
-rw-r--r--generic/tclLink.c2
-rw-r--r--generic/tclListObj.c6
-rw-r--r--generic/tclLiteral.c6
-rw-r--r--generic/tclLoad.c2
-rw-r--r--generic/tclMain.c17
-rw-r--r--generic/tclNamesp.c4
-rw-r--r--generic/tclOOCall.c2
-rw-r--r--generic/tclObj.c109
-rw-r--r--generic/tclParse.c12
-rw-r--r--generic/tclPathObj.c26
-rw-r--r--generic/tclPipe.c2
-rw-r--r--generic/tclPkg.c46
-rw-r--r--generic/tclProc.c2
-rw-r--r--generic/tclProcess.c4
-rw-r--r--generic/tclRegexp.c2
-rw-r--r--generic/tclResult.c2
-rw-r--r--generic/tclScan.c10
-rw-r--r--generic/tclStrToD.c160
-rw-r--r--generic/tclStringObj.c30
-rw-r--r--generic/tclStubInit.c115
-rw-r--r--generic/tclTest.c29
-rw-r--r--generic/tclTestObj.c32
-rw-r--r--generic/tclTestProcBodyObj.c47
-rw-r--r--generic/tclThread.c4
-rw-r--r--generic/tclTimer.c2
-rw-r--r--generic/tclTomMath.decls25
-rw-r--r--generic/tclTomMath.h45
-rw-r--r--generic/tclTomMathDecls.h76
-rw-r--r--generic/tclTomMathInterface.c38
-rw-r--r--generic/tclTrace.c6
-rw-r--r--generic/tclUniData.c1644
-rw-r--r--generic/tclUtf.c423
-rw-r--r--generic/tclUtil.c32
-rw-r--r--generic/tclVar.c2
-rw-r--r--generic/tclZipfs.c24
-rw-r--r--generic/tclZlib.c6
-rw-r--r--library/init.tcl36
-rw-r--r--library/tzdata/America/Metlakatla3
-rw-r--r--library/tzdata/Asia/Gaza52
-rw-r--r--library/tzdata/Asia/Hebron52
-rw-r--r--library/tzdata/Asia/Jerusalem4
-rw-r--r--library/tzdata/Etc/UCT6
-rw-r--r--library/tzdata/UCT6
-rw-r--r--libtommath/bn_mp_clear.c2
-rw-r--r--libtommath/bn_mp_fwrite.c8
-rw-r--r--libtommath/bn_mp_get_bit.c12
-rw-r--r--libtommath/bn_mp_get_double.c6
-rw-r--r--libtommath/bn_mp_get_int.c19
-rw-r--r--libtommath/bn_mp_get_long.c10
-rw-r--r--libtommath/bn_mp_get_long_long.c8
-rw-r--r--libtommath/bn_mp_grow.c4
-rw-r--r--libtommath/bn_mp_init.c2
-rw-r--r--libtommath/bn_mp_init_size.c2
-rw-r--r--libtommath/bn_mp_is_square.c5
-rw-r--r--libtommath/bn_mp_prime_random_ex.c10
-rw-r--r--libtommath/bn_mp_read_radix.c4
-rw-r--r--libtommath/bn_mp_set_double.c4
-rw-r--r--libtommath/bn_mp_shrink.c4
-rw-r--r--libtommath/tommath.h29
-rw-r--r--libtommath/tommath_private.h76
-rw-r--r--macosx/Tcl.xcode/project.pbxproj4
-rw-r--r--macosx/Tcl.xcodeproj/project.pbxproj4
-rw-r--r--macosx/tclMacOSXFCmd.c14
-rw-r--r--tests-perf/clock.perf.tcl411
-rw-r--r--tests-perf/test-performance.tcl144
-rw-r--r--tests-perf/timer-event.perf.tcl182
-rw-r--r--tests/cmdMZ.test84
-rw-r--r--tests/encoding.test7
-rw-r--r--tests/expr.test42
-rw-r--r--tests/obj.test28
-rw-r--r--tests/proc.test3
-rw-r--r--tests/socket.test10
-rw-r--r--tests/utf.test22
-rw-r--r--tests/util.test1244
-rw-r--r--tools/tcltk-man2html-utils.tcl1
-rwxr-xr-xtools/tcltk-man2html.tcl51
-rw-r--r--tools/uniParse.tcl8
-rw-r--r--unix/Makefile.in20
-rw-r--r--unix/tclUnixChan.c30
-rw-r--r--unix/tclUnixFCmd.c20
-rw-r--r--unix/tclUnixFile.c2
-rw-r--r--unix/tclUnixSock.c2
-rw-r--r--unix/tclUnixTime.c71
-rw-r--r--win/Makefile.in2
-rw-r--r--win/makefile.vc10
-rw-r--r--win/nmakehlp.c2
-rw-r--r--win/rules.vc54
-rw-r--r--win/tclWin32Dll.c120
-rw-r--r--win/tclWinChan.c6
-rw-r--r--win/tclWinConsole.c6
-rw-r--r--win/tclWinFCmd.c109
-rw-r--r--win/tclWinFile.c164
-rw-r--r--win/tclWinInit.c21
-rw-r--r--win/tclWinInt.h4
-rw-r--r--win/tclWinPipe.c51
-rw-r--r--win/tclWinPort.h9
-rw-r--r--win/tclWinSerial.c16
-rw-r--r--win/tclWinSock.c4
-rw-r--r--win/tclWinTime.c426
144 files changed, 5323 insertions, 3453 deletions
diff --git a/.fossil-settings/ignore-glob b/.fossil-settings/ignore-glob
index 08e405d..cd6e689 100644
--- a/.fossil-settings/ignore-glob
+++ b/.fossil-settings/ignore-glob
@@ -19,14 +19,18 @@
*/tcltest*
*/versions.vc
*/version.vc
+*/libtcl.vfs
+*/libtcl_*.zip
html
libtommath/bn.ilg
libtommath/bn.ind
libtommath/pretty.build
libtommath/tommath.src
+libtommath/*.log
libtommath/*.pdf
libtommath/*.pl
libtommath/*.sh
+libtommath/doc/*
libtommath/tombc/*
libtommath/pre_gen/*
libtommath/pics/*
diff --git a/.travis.yml b/.travis.yml
index e186e26..3770e07 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -4,29 +4,29 @@ language: c
matrix:
include:
- os: linux
- dist: trusty
+ dist: xenial
compiler: clang
env:
- BUILD_DIR=unix
- os: linux
- dist: trusty
+ dist: xenial
compiler: clang
env:
- CFGOPT=--disable-shared
- BUILD_DIR=unix
- os: linux
- dist: trusty
+ dist: xenial
compiler: gcc
env:
- BUILD_DIR=unix
- os: linux
- dist: trusty
+ dist: xenial
compiler: gcc
env:
- CFGOPT=--disable-shared
- BUILD_DIR=unix
- os: linux
- dist: trusty
+ dist: xenial
compiler: gcc-4.9
addons:
apt:
@@ -37,7 +37,7 @@ matrix:
env:
- BUILD_DIR=unix
- os: linux
- dist: trusty
+ dist: xenial
compiler: gcc-5
addons:
apt:
@@ -48,7 +48,7 @@ matrix:
env:
- BUILD_DIR=unix
- os: linux
- dist: trusty
+ dist: xenial
compiler: gcc-6
addons:
apt:
@@ -59,7 +59,7 @@ matrix:
env:
- BUILD_DIR=unix
- os: linux
- dist: trusty
+ dist: xenial
compiler: gcc-7
addons:
apt:
@@ -69,6 +69,42 @@ matrix:
- g++-7
env:
- BUILD_DIR=unix
+ - os: linux
+ dist: xenial
+ compiler: gcc-7
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-7
+ env:
+ - BUILD_DIR=unix
+ - CFGOPT=CFLAGS=-DTCL_UTF_MAX=6
+ - os: linux
+ dist: xenial
+ compiler: gcc-7
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-7
+ env:
+ - BUILD_DIR=unix
+ - CFGOPT=CFLAGS=-DTCL_UTF_MAX=3
+ - os: linux
+ dist: xenial
+ compiler: gcc-7
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-7
+ env:
+ - BUILD_DIR=unix
+ - CFGOPT=CFLAGS=-DTCL_NO_DEPRECATED=1
- os: osx
osx_image: xcode8
env:
@@ -84,7 +120,7 @@ matrix:
- BUILD_DIR=macosx
- NO_DIRECT_CONFIGURE=1
- os: osx
- osx_image: xcode10
+ osx_image: xcode10.2
env:
- BUILD_DIR=macosx
- NO_DIRECT_CONFIGURE=1
@@ -95,7 +131,7 @@ matrix:
### ... so proxy with a Mingw cross-compile
# Test with mingw-w64 (32 bit)
- os: linux
- dist: trusty
+ dist: xenial
compiler: i686-w64-mingw32-gcc
addons:
apt:
@@ -110,9 +146,57 @@ matrix:
- BUILD_DIR=win
- CFGOPT=--host=i686-w64-mingw32
- NO_DIRECT_TEST=1
+ - os: linux
+ dist: xenial
+ compiler: i686-w64-mingw32-gcc
+ addons:
+ apt:
+ packages:
+ - gcc-mingw-w64-base
+ - binutils-mingw-w64-i686
+ - gcc-mingw-w64-i686
+ - gcc-mingw-w64
+ - gcc-multilib
+ - wine
+ env:
+ - BUILD_DIR=win
+ - CFGOPT="--host=i686-w64-mingw32 CFLAGS=-DTCL_UTF_MAX=6"
+ - NO_DIRECT_TEST=1
+ - os: linux
+ dist: xenial
+ compiler: i686-w64-mingw32-gcc
+ addons:
+ apt:
+ packages:
+ - gcc-mingw-w64-base
+ - binutils-mingw-w64-i686
+ - gcc-mingw-w64-i686
+ - gcc-mingw-w64
+ - gcc-multilib
+ - wine
+ env:
+ - BUILD_DIR=win
+ - CFGOPT="--host=i686-w64-mingw32 CFLAGS=-DTCL_UTF_MAX=3"
+ - NO_DIRECT_TEST=1
+ - os: linux
+ dist: xenial
+ compiler: i686-w64-mingw32-gcc
+ addons:
+ apt:
+ packages:
+ - gcc-mingw-w64-base
+ - binutils-mingw-w64-i686
+ - gcc-mingw-w64-i686
+ - gcc-mingw-w64
+ - gcc-multilib
+ - wine
+ env:
+ - BUILD_DIR=win
+ - CFGOPT="--host=i686-w64-mingw32 CFLAGS=-DTCL_NO_DEPRECATED=1"
+ - NO_DIRECT_TEST=1
# Test with mingw-w64 (64 bit)
- os: linux
- dist: trusty
+ dist: xenial
compiler: x86_64-w64-mingw32-gcc
addons:
apt:
@@ -126,7 +210,51 @@ matrix:
- BUILD_DIR=win
- CFGOPT="--host=x86_64-w64-mingw32 --enable-64bit"
- NO_DIRECT_TEST=1
-
+ - os: linux
+ dist: xenial
+ compiler: x86_64-w64-mingw32-gcc
+ addons:
+ apt:
+ packages:
+ - gcc-mingw-w64-base
+ - binutils-mingw-w64-x86-64
+ - gcc-mingw-w64-x86-64
+ - gcc-mingw-w64
+ - wine
+ env:
+ - BUILD_DIR=win
+ - CFGOPT="--host=x86_64-w64-mingw32 --enable-64bit CFLAGS=-DTCL_UTF_MAX=6"
+ - NO_DIRECT_TEST=1
+ - os: linux
+ dist: xenial
+ compiler: x86_64-w64-mingw32-gcc
+ addons:
+ apt:
+ packages:
+ - gcc-mingw-w64-base
+ - binutils-mingw-w64-x86-64
+ - gcc-mingw-w64-x86-64
+ - gcc-mingw-w64
+ - wine
+ env:
+ - BUILD_DIR=win
+ - CFGOPT="--host=x86_64-w64-mingw32 --enable-64bit CFLAGS=-DTCL_UTF_MAX=3"
+ - NO_DIRECT_TEST=1
+ - os: linux
+ dist: xenial
+ compiler: x86_64-w64-mingw32-gcc
+ addons:
+ apt:
+ packages:
+ - gcc-mingw-w64-base
+ - binutils-mingw-w64-x86-64
+ - gcc-mingw-w64-x86-64
+ - gcc-mingw-w64
+ - wine
+ env:
+ - BUILD_DIR=win
+ - CFGOPT="--host=x86_64-w64-mingw32 --enable-64bit CFLAGS=-DTCL_NO_DEPRECATED=1"
+ - NO_DIRECT_TEST=1
before_install:
- export ERROR_ON_FAILURES=1
- cd ${BUILD_DIR}
diff --git a/doc/Tcl.n b/doc/Tcl.n
index fc3b477..0eb51b9 100644
--- a/doc/Tcl.n
+++ b/doc/Tcl.n
@@ -28,10 +28,10 @@ First, the Tcl interpreter breaks the command into \fIwords\fR
and performs substitutions as described below.
These substitutions are performed in the same way for all
commands.
-Secondly, the first word is used to locate a command procedure to
-carry out the command, then all of the words of the command are
-passed to the command procedure.
-The command procedure is free to interpret each of its words
+Secondly, the first word is used to locate a routine to
+carry out the command, and the remaining words of the command are
+passed to that routine.
+The routine is free to interpret each of its words
in any way it likes, such as an integer, variable name, list,
or Tcl script.
Different commands interpret their words differently.
diff --git a/doc/ToUpper.3 b/doc/ToUpper.3
index 1c7a0c2..fd9ddfb 100644
--- a/doc/ToUpper.3
+++ b/doc/ToUpper.3
@@ -78,11 +78,5 @@ turns each character in the string into its lower-case equivalent.
turns the first character in the string into its title-case equivalent
and all following characters into their lower-case equivalents.
-.SH BUGS
-.PP
-At this time, the case conversions are only defined for the ISO8859-1
-characters. Unicode characters above 0x00ff are not modified by these
-routines.
-
.SH KEYWORDS
utf, unicode, toupper, tolower, totitle, case
diff --git a/doc/Utf.3 b/doc/Utf.3
index 922fd81..111aae6 100644
--- a/doc/Utf.3
+++ b/doc/Utf.3
@@ -132,10 +132,11 @@ represent one Unicode character in the UTF-8 representation.
.PP
\fBTcl_UniCharToUtf\fR stores the character \fIch\fR as a UTF-8 string
in starting at \fIbuf\fR. The return value is the number of bytes stored
-in \fIbuf\fR. If ch is an upper surrogate (range U+D800 - U+DBFF), then
-the return value will be 0 and nothing will be stored. If you still
-want to produce UTF-8 output for it (even though knowing it's an illegal
-code-point on its own), just call \fBTcl_UniCharToUtf\fR again using ch = -1.
+in \fIbuf\fR. If ch is a high surrogate (range U+D800 - U+DBFF), then
+the return value will be 1 and a single byte in the range 0xF0 - 0xF4
+will be stored. If you still want to produce UTF-8 output for it (even
+though knowing it's an illegal code-point on its own), just call
+\fBTcl_UniCharToUtf\fR again specifying ch = -1.
.PP
\fBTcl_UtfToUniChar\fR reads one UTF-8 character starting at \fIsrc\fR
and stores it as a Tcl_UniChar in \fI*chPtr\fR. The return value is the
diff --git a/doc/array.n b/doc/array.n
index bbfcd9f..268597d 100644
--- a/doc/array.n
+++ b/doc/array.n
@@ -40,7 +40,7 @@ has been completed.
.VS TIP508
Manages the default value of the array. Arrays initially have no default
value, but this command allows you to set one; the default value will be
-returned when reading from an element of the array \farrayName\fR if the read
+returned when reading from an element of the array \fIarrayName\fR if the read
would otherwise result in an error. Note that this may cause the \fBappend\fR,
\fBdict\fR, \fBincr\fR and \fBlappend\fR commands to change their behavior in
relation to non-existing array elements.
diff --git a/doc/cookiejar.n b/doc/cookiejar.n
index ac71759..0d8b81a 100644
--- a/doc/cookiejar.n
+++ b/doc/cookiejar.n
@@ -96,7 +96,7 @@ the database.
.RE
.PP
Cookie jar instances may be made with any of the standard TclOO instance
-creation methods (\fBcreate\fR or \fRnew\fR).
+creation methods (\fBcreate\fR or \fBnew\fR).
.TP
\fB::http::cookiejar new\fR ?\fIfilename\fR?
.
diff --git a/doc/define.n b/doc/define.n
index a84028b..a2b0813 100644
--- a/doc/define.n
+++ b/doc/define.n
@@ -52,7 +52,7 @@ the \fBmethod\fR definition, below.
.RS
.PP
Class methods can be called on either the class itself or on the instances of
-that class. When they are called, the current object (see the \fBself\R and
+that class. When they are called, the current object (see the \fBsel\fR and
\fBmy\fR commands) is the class on which they are called or the class of the
instance on which they are called, depending on whether they are called on the
class or an instance of the class, respectively. If called on a subclass or
diff --git a/doc/expr.n b/doc/expr.n
index d33623c..0210348 100644
--- a/doc/expr.n
+++ b/doc/expr.n
@@ -126,7 +126,8 @@ applied to integers.
.TP 20
\fB**\fR
.
-Exponentiation. Valid for numeric operands.
+Exponentiation. Valid for numeric operands. The maximum exponent value
+that Tcl can handle if the first number is an integer > 1 is 268435455.
.TP 20
\fB*\0\0/\0\0%\fR
.
diff --git a/doc/info.n b/doc/info.n
index cf5a438..dc21ac1 100644
--- a/doc/info.n
+++ b/doc/info.n
@@ -13,129 +13,102 @@
.BS
'\" Note: do not modify the .SH NAME line immediately below!
.SH NAME
-info \- Return information about the state of the Tcl interpreter
+info \- Information about the state of the Tcl interpreter
.SH SYNOPSIS
\fBinfo \fIoption \fR?\fIarg arg ...\fR?
.BE
.SH DESCRIPTION
.PP
-This command provides information about various internals of the Tcl
-interpreter.
-The legal \fIoption\fRs (which may be abbreviated) are:
+Available commands:
.TP
\fBinfo args \fIprocname\fR
.
-Returns a list containing the names of the arguments to procedure
-\fIprocname\fR, in order. \fIProcname\fR must be the name of a
-Tcl command procedure.
+Returns the names of the parameters to the procedure named \fIprocname\fR.
.TP
\fBinfo body \fIprocname\fR
.
-Returns the body of procedure \fIprocname\fR. \fIProcname\fR must be
-the name of a Tcl command procedure.
+Returns the body of the procedure named \fIprocname\fR.
.TP
\fBinfo class\fI subcommand class\fR ?\fIarg ...\fR
.
-Returns information about the class, \fIclass\fR. The \fIsubcommand\fRs are
-described in \fBCLASS INTROSPECTION\fR below.
+Returns information about the class named \fIclass\fR.
+See \fBCLASS INTROSPECTION\fR below.
.TP
\fBinfo cmdcount\fR
.
-Returns a count of the total number of commands that have been invoked
-in this interpreter.
+Returns the total number of commands evaluated in this interpreter.
.TP
\fBinfo cmdtype \fIcommandName\fR
.VS TIP426
-Returns a description of the kind of command named by \fIcommandName\fR. The
-supported types are:
+Returns a the type of the command named \fIcommandName\fR.
+Built-in types are:
.RS
.IP \fBalias\fR
-Indicates that \fIcommandName\fR was created by \fBinterp alias\fR. Note that
-safe interpreters can only see a subset of aliases (specifically those between
-two commands within themselves).
+\fIcommandName\fR was created by \fBinterp alias\fR.
+In a safe interpreter an alias is only visible if both the alias and the
+target are visible.
.IP \fBcoroutine\fR
-Indicates that \fIcommandName\fR was created by \fBcoroutine\fR.
+\fIcommandName\fR was created by \fBcoroutine\fR.
.IP \fBensemble\fR
-Indicates that \fIcommandName\fR was created by \fBnamespace ensemble\fR.
+\fIcommandName\fR was created by \fBnamespace ensemble\fR.
.IP \fBimport\fR
-Indicates that \fIcommandName\fR was created by \fBnamespace import\fR.
+\fIcommandName\fR was created by \fBnamespace import\fR.
.IP \fBnative\fR
-Indicates that \fIcommandName\fR was created by the \fBTcl_CreateObjProc\fR
+\fIcommandName\fR was created by the \fBTcl_CreateObjProc\fR
interface directly without further registration of the type of command.
.IP \fBobject\fR
-Indicates that \fIcommandName\fR is the public command that represents an
+\fIcommandName\fR is the public command that represents an
instance of \fBoo::object\fR or one of its subclasses.
.IP \fBprivateObject\fR
-Indicates that \fIcommandName\fR is the private command (\fBmy\fR by default)
+\fIcommandName\fR is the private command, \fBmy\fR by default,
that represents an instance of \fBoo::object\fR or one of its subclasses.
.IP \fBproc\fR
-Indicates that \fIcommandName\fR was created by \fBproc\fR.
+\fIcommandName\fR was created by \fBproc\fR.
.IP \fBslave\fR
-Indicates that \fIcommandName\fR was created by \fBinterp create\fR.
+\fIcommandName\fR was created by \fBinterp create\fR.
.IP \fBzlibStream\fR
-Indicates that \fIcommandName\fR was created by \fBzlib stream\fR.
+\fIcommandName\fR was created by \fBzlib stream\fR.
.PP
-There may be other registered types as well; this is a set that is extensible
-at the implementation level with \fBTcl_RegisterCommandTypeName\fR.
+Other types may be also registered as well. See \fBTcl_RegisterCommandTypeName\fR.
.RE
.VE TIP426
.TP
\fBinfo commands \fR?\fIpattern\fR?
.
-If \fIpattern\fR is not specified,
-returns a list of names of all the Tcl commands visible
-(i.e. executable without using a qualified name) to the current namespace,
-including both the built-in commands written in C and
-the command procedures defined using the \fBproc\fR command.
-If \fIpattern\fR is specified,
-only those names matching \fIpattern\fR are returned.
-Matching is determined using the same rules as for \fBstring match\fR.
-\fIpattern\fR can be a qualified name like \fBFoo::print*\fR.
-That is, it may specify a particular namespace
-using a sequence of namespace names separated by double colons (\fB::\fR),
-and may have pattern matching special characters
-at the end to specify a set of commands in that namespace.
-If \fIpattern\fR is a qualified name,
-the resulting list of command names has each one qualified with the name
-of the specified namespace, and only the commands defined in the named
-namespace are returned.
-.\" Technically, most of this hasn't changed; that's mostly just the
-.\" way it always worked. Hardly anyone knew that though.
+Returns the names of all commands visible in the current namespace. If
+\fIpattern\fR is given, returns only those names that match according to
+\fBstring match\fR. Only the last component of \fIpattern\fR is a pattern.
+Other components identify a namespace. See \fBNAMESPACE RESOLUTION\fR in the
+\fBnamespace\fR(n) documentation.
.TP
\fBinfo complete \fIcommand\fR
.
-Returns 1 if \fIcommand\fR is a complete Tcl command in the sense of
-having no unclosed quotes, braces, brackets or array element names.
-If the command does not appear to be complete then 0 is returned.
-This command is typically used in line-oriented input environments
-to allow users to type in commands that span multiple lines; if the
-command is not complete, the script can delay evaluating it until additional
-lines have been typed to complete the command.
+Returns 1 if \fIcommand\fR is a complete command, and \fB0\fR otherwise.
+Typically used in line-oriented input environments
+to allow users to type in commands that span multiple lines.
.TP
\fBinfo coroutine\fR
.
-Returns the name of the currently executing \fBcoroutine\fR, or the empty
-string if either no coroutine is currently executing, or the current coroutine
-has been deleted (but has not yet returned or yielded since deletion).
+Returns the name of the current \fBcoroutine\fR, or the empty
+string if there is no current coroutine or the current coroutine
+has been deleted.
.TP
-\fBinfo default \fIprocname arg varname\fR
+\fBinfo default \fIprocname parameter varname\fR
.
-\fIProcname\fR must be the name of a Tcl command procedure and \fIarg\fR
-must be the name of an argument to that procedure. If \fIarg\fR
-does not have a default value then the command returns \fB0\fR.
-Otherwise it returns \fB1\fR and places the default value of \fIarg\fR
-into variable \fIvarname\fR.
+If the parameter \fIparameter\fR for the procedure named \fIprocname\fR has a
+default value, stores that value in \fIvarname\fR and returns \fB1\fR.
+Otherwise, returns \fB0\fR.
.TP
\fBinfo errorstack \fR?\fIinterp\fR?
.
-Returns, in a form that is programmatically easy to parse, the function names
-and arguments at each level from the call stack of the last error in the given
-\fIinterp\fR, or in the current one if not specified.
+Returns a description of the active command at each level for the
+last error in the current interpreter, or in the interpreter named
+\fIinterp\fR if given.
.RS
.PP
-This form is an even-sized list alternating tokens and parameters. Tokens are
+The description is a dictionary of tokens and parameters. Tokens are
currently either \fBCALL\fR, \fBUP\fR, or \fBINNER\fR, but other values may be
-introduced in the future. \fBCALL\fR indicates a procedure call, and its
+introduced in the future. \fBCALL\fR indicates a command call, and its
parameter is the corresponding \fBinfo level\fR \fB0\fR. \fBUP\fR indicates a
shift in variable frames generated by \fBuplevel\fR or similar, and applies to
the previous \fBCALL\fR item. Its parameter is the level offset. \fBINNER\fR
@@ -143,126 +116,103 @@ identifies the
.QW "inner context" ,
which is the innermost atomic command or bytecode instruction that raised the
error, along with its arguments when available. While \fBCALL\fR and \fBUP\fR
-allow to follow complex call paths, \fBINNER\fR homes in on the offending
-operation in the innermost procedure call, even going to sub-expression
+provide a trail of the call path, \fBINNER\fR provides details of the offending
+operation in the innermost procedure call, even to sub-expression
granularity.
.PP
This information is also present in the \fB\-errorstack\fR entry of the
options dictionary returned by 3-argument \fBcatch\fR; \fBinfo errorstack\fR
is a convenient way of retrieving it for uncaught errors at top-level in an
-interactive \fBtclsh\fR.
+interactive \fBinterpreter\fR.
.RE
.TP
\fBinfo exists \fIvarName\fR
.
-Returns \fB1\fR if the variable named \fIvarName\fR exists in the
-current context (either as a global or local variable) and has been
-defined by being given a value, returns \fB0\fR otherwise.
+Returns \fB1\fR if a variable named \fIvarName\fR is visible and has been
+defined, and \fB0\fR otherwise.
.TP
-\fBinfo frame\fR ?\fInumber\fR?
+\fBinfo frame\fR ?\fIdepth\fR?
.
-This command provides access to all frames on the stack, even those
-hidden from \fBinfo level\fR. If \fInumber\fR is not specified, this
-command returns a number giving the frame level of the command. This
-is 1 if the command is invoked at top-level. If \fInumber\fR is
-specified, then the result is a dictionary containing the location
-information for the command at the \fInumber\fRed level on the stack.
+Returns the depth of the call to \fBinfo frame\fR itself. Otherwise, returns a
+dictionary describing the active command at the \fIdepth\fR, which counts all
+commands visible to \fBinfo level\fR, plus commands that don't create a new
+level, such as \fBeval\fR, \fBsource\fR, or \fIuplevel\fR. The frame depth is
+always greater than the current level.
.RS
.PP
-If \fInumber\fR is positive (> 0) then it selects a particular stack
-level (1 refers to the outer-most active command, 2 to the command it
-called, and so on, up to the current frame level which refers to
-\fBinfo frame\fR itself); otherwise it gives a level relative to the
-current command (0 refers to the current command, i.e., \fBinfo
-frame\fR itself, -1 to its caller, and so on).
+If \fIdepth\fR is greater than \fB0\fR it is the frame at that depth. Otherwise
+it is the number of frames up from the current frame.
.PP
-This is similar to how \fBinfo level\fR works, except that this
-subcommand reports all frames, like \fBsource\fRd scripts,
-\fBeval\fRs, \fBuplevel\fRs, etc.
-.PP
-Note that for nested commands, like
+As with \fBinfo level\fR and error traces, for nested commands like
.QW "foo [bar [x]]" ,
only
.QW x
-will be seen by an \fBinfo frame\fR invoked within
+is seen by \fBinfo frame\fR invoked within
.QW x .
-This is the same as for \fBinfo level\fR and error stack traces.
.PP
-The result dictionary may contain the keys listed below, with the
-specified meanings for their values:
+The dictionary may contain the following keys:
.TP
\fBtype\fR
.
-This entry is always present and describes the nature of the location
-for the command. The recognized values are \fBsource\fR, \fBproc\fR,
+Always present. Possible values are \fBsource\fR, \fBproc\fR,
\fBeval\fR, and \fBprecompiled\fR.
.RS
.TP
\fBsource\fR\0\0\0\0\0\0\0\0
.
-means that the command is found in a script loaded by the \fBsource\fR
+A script loaded via the \fBsource\fR
command.
.TP
\fBproc\fR\0\0\0\0\0\0\0\0
.
-means that the command is found in dynamically created procedure body.
+The body of a procedure that could not be traced back to a
+line in a particular script.
.TP
\fBeval\fR\0\0\0\0\0\0\0\0
.
-means that the command is executed by \fBeval\fR or \fBuplevel\fR.
+The body of a script provided to \fBeval\fR or \fBuplevel\fR.
.TP
\fBprecompiled\fR\0\0\0\0\0\0\0\0
.
-means that the command is found in a pre-compiled script (loadable by
-the package \fBtbcload\fR), and no further information will be
-available.
+A pre-compiled script (loadable by the package
+\fBtbcload\fR), and no further information is available.
.RE
.TP
\fBline\fR
.
-This entry provides the number of the line the command is at inside of
-the script it is a part of. This information is not present for type
-\fBprecompiled\fR. For type \fBsource\fR this information is counted
-relative to the beginning of the file, whereas for the last two types
-the line is counted relative to the start of the script.
+The line number of of the command inside its script. Not available for
+\fBprecompiled\fR commands. When the type is \fBsource\fR, the line number is
+relative to the beginning of the file, whereas for the last two types it is
+relative to the start of the script.
.TP
\fBfile\fR
.
-This entry is present only for type \fBsource\fR. It provides the
-normalized path of the file the command is in.
+For type \fBsource\fR, provides the normalized path of the file that contains
+the command.
.TP
\fBcmd\fR
.
-This entry provides the string representation of the command. This is
-usually the unsubstituted form, however for commands which are a
-canonically-constructed list (e.g., as produced by the \fBlist\fR command)
-executed by \fBeval\fR it is the substituted form as they have no other
-string representation. Care is taken that the canonicality property of
-the latter is not spoiled.
+The command before substitutions were performed.
.TP
\fBproc\fR
.
-This entry is present only if the command is found in the body of a
-regular Tcl procedure. It then provides the name of that procedure.
+For type \fBprod\fR, the name of the procedure containing the command.
.TP
\fBlambda\fR
.
-This entry is present only if the command is found in the body of an
-anonymous Tcl procedure, i.e. a lambda. It then provides the entire
-definition of the lambda in question.
+For a command in a script evaluated as the body of an unnamed routine via the
+\fBapply\fR command, the definition of that routine.
.TP
\fBlevel\fR
.
-This entry is present only if the queried frame has a corresponding
-frame returned by \fBinfo level\fR. It provides the index of this
-frame, relative to the current level (0 and negative numbers).
+For a frame that corresponds to a level, (to be determined).
.PP
-A thing of note is that for procedures statically defined in files the
-locations of commands in their bodies will be reported with type
-\fBsource\fR and absolute line numbers, and not as type
-\fBproc\fR. The same is true for procedures nested in statically
-defined procedures, and literal eval scripts in files or statically
-defined procedures.
+When a command can be traced to its literal definition in some script, e.g.
+procedures nested in statically defined procedures, and literal eval scripts in
+files or statically defined procedures, its type is \fBsource\fR and its
+location is the absolute line number in the script. Otherwise, its type is
+\fBproc\fR and its location is its line number within the body of the
+procedure.
.PP
In contrast, procedure definitions and \fBeval\fR within a dynamically
\fBeval\fRuated environment count line numbers relative to the start of
@@ -270,7 +220,7 @@ their script, even if they would be able to count relative to the
start of the outer dynamic script. That type of number usually makes
more sense.
.PP
-A different way of describing this behaviour is that file based
+A different way of describing this behaviour is that file-based
locations are tracked as deeply as possible, and where this is not
possible the lines are counted based on the smallest possible
\fBeval\fR or procedure body, as that scope is usually easier to find
@@ -284,152 +234,112 @@ counted relative to the start of each word (smallest scope)
.TP
\fBinfo functions \fR?\fIpattern\fR?
.
-If \fIpattern\fR is not specified, returns a list of all the math
+If \fIpattern\fR is not given, returns a list of all the math
functions currently defined.
-If \fIpattern\fR is specified, only those functions whose name matches
-\fIpattern\fR are returned. Matching is determined using the same
-rules as for \fBstring match\fR.
+If \fIpattern\fR is given, returns only those names that match
+\fIpattern\fR according to \fBstring match\fR.
.TP
\fBinfo globals \fR?\fIpattern\fR?
.
-If \fIpattern\fR is not specified, returns a list of all the names
+If \fIpattern\fR is not given, returns a list of all the names
of currently-defined global variables.
Global variables are variables in the global namespace.
-If \fIpattern\fR is specified, only those names matching \fIpattern\fR
+If \fIpattern\fR is given, only those names matching \fIpattern\fR
are returned. Matching is determined using the same rules as for
\fBstring match\fR.
.TP
\fBinfo hostname\fR
.
-Returns the name of the computer on which this invocation is being
-executed.
-Note that this name is not guaranteed to be the fully qualified domain
-name of the host. Where machines have several different names (as is
+Returns the name of the current host.
+
+This name is not guaranteed to be the fully-qualified domain
+name of the host. Where machines have several different names, as is
common on systems with both TCP/IP (DNS) and NetBIOS-based networking
-installed,) it is the name that is suitable for TCP/IP networking that
+installed, it is the name that is suitable for TCP/IP networking that
is returned.
.TP
-\fBinfo level\fR ?\fInumber\fR?
+\fBinfo level\fR ?\fIlevel\fR?
.
-If \fInumber\fR is not specified, this command returns a number
-giving the stack level of the invoking procedure, or 0 if the
-command is invoked at top-level. If \fInumber\fR is specified,
-then the result is a list consisting of the name and arguments for the
-procedure call at level \fInumber\fR on the stack. If \fInumber\fR
-is positive then it selects a particular stack level (1 refers
-to the top-most active procedure, 2 to the procedure it called, and
-so on); otherwise it gives a level relative to the current level
-(0 refers to the current procedure, -1 to its caller, and so on).
-See the \fBuplevel\fR command for more information on what stack
-levels mean.
+If \fInumber\fR is not given, the level this routine was called from.
+Otherwise returns the complete command active at the given level. If
+\fInumber\fR is greater than \fB0\fR, it is the desired level. Otherwise, it
+is \fInumber\fR levels up from the current level. A complete command is the
+words in the command, with all subsitutions performed, meaning that it is a
+list. See \fBuplevel\fR for more information on levels.
.TP
\fBinfo library\fR
.
-Returns the name of the library directory in which standard Tcl
-scripts are stored.
-This is actually the value of the \fBtcl_library\fR
-variable and may be changed by setting \fBtcl_library\fR.
+Returns the value of \fBtcl_library\fR, which is the name of the library
+directory in which the scripts distributed with Tcl scripts are stored.
.TP
\fBinfo loaded \fR?\fIinterp\fR? ?\fIpackage\fR?
.
-Returns the filename loaded as part of \fIpackage\fR. If \fIpackage\fR
-is not specified, returns a list describing all of the packages
-that have been loaded into \fIinterp\fR with the \fBload\fR command.
-Each list element is a sub-list with two elements consisting of the
-name of the file from which the package was loaded and the name of
-the package.
-For statically-loaded packages the file name will be an empty string.
-If \fIinterp\fR is omitted then information is returned for all packages
-loaded in any interpreter in the process.
-To get a list of just the packages in the current interpreter, specify
-an empty string for the \fIinterp\fR argument.
+Returns the name of each file loaded in \fIinterp\fR va \fBload\fR as part of
+\fIpackage\fR . If \fIpackage\fR is not given, returns a list where each item
+is the name of the loaded file and the name of the package for which the file
+was loaded. For a statically-loaded package the name of the file is the empty
+string. For \fInterp\fR, the empty string is the current interpreter.
.TP
\fBinfo locals \fR?\fIpattern\fR?
.
-If \fIpattern\fR is not specified, returns a list of all the names
-of currently-defined local variables, including arguments to the
-current procedure, if any.
-Variables defined with the \fBglobal\fR, \fBupvar\fR and
-\fBvariable\fR commands will not be returned.
-If \fIpattern\fR is specified, only those names matching \fIpattern\fR
-are returned. Matching is determined using the same rules as for
-\fBstring match\fR.
+If \fIpattern\fR is given, returns the name of each local variable matching
+\fIpattern\fR according to \fBstring match\fR. Otherwise, returns the name of
+each local variable. A variables defined with the \fBglobal\fR, \fBupvar\fR or
+\fBvariable\fR is not local.
+
.TP
\fBinfo nameofexecutable\fR
.
-Returns the full path name of the binary file from which the application
-was invoked. If Tcl was unable to identify the file, then an empty
-string is returned.
+Returns the absolute pathname of the program for the current interpreter. If
+such a file can not be identified an empty string is returned.
.TP
\fBinfo object\fI subcommand object\fR ?\fIarg ...\fR
.
-Returns information about the object, \fIobject\fR. The \fIsubcommand\fRs are
-described in \fBOBJECT INTROSPECTION\fR below.
+Returns information about the object named \fIobject\fR. \fIsubcommand\fR is
+described \fBOBJECT INTROSPECTION\fR below.
.TP
\fBinfo patchlevel\fR
.
-Returns the value of the global variable \fBtcl_patchLevel\fR, which holds
-the exact version of the Tcl library by default.
+Returns the value of the global variable \fBtcl_patchLevel\fR, in which the
+exact version of the Tcl library initially stored.
.TP
\fBinfo procs \fR?\fIpattern\fR?
.
-If \fIpattern\fR is not specified, returns a list of all the
-names of Tcl command procedures in the current namespace.
-If \fIpattern\fR is specified,
-only those procedure names in the current namespace
-matching \fIpattern\fR are returned.
-Matching is determined using the same rules as for
-\fBstring match\fR.
-If \fIpattern\fR contains any namespace separators, they are used to
-select a namespace relative to the current namespace (or relative to
-the global namespace if \fIpattern\fR starts with \fB::\fR) to match
-within; the matching pattern is taken to be the part after the last
-namespace separator.
+Returns the names of all visible procedures. If \fIpattern\fR is given, returns
+only those names that match according to \fBstring match\fR. Only the final
+component in \fIpattern\fR is actually considered a pattern. Any qualifying
+components simply select a namespace. See \fBNAMESPACE RESOLUTION\fR in the
+\fBnamespace\fR(n) documentation.
.TP
\fBinfo script\fR ?\fIfilename\fR?
.
-If a Tcl script file is currently being evaluated (i.e. there is a
-call to \fBTcl_EvalFile\fR active or there is an active invocation
-of the \fBsource\fR command), then this command returns the name
-of the innermost file being processed. If \fIfilename\fR is specified,
-then the return value of this command will be modified for the
-duration of the active invocation to return that name. This is
-useful in virtual file system applications.
-Otherwise the command returns an empty string.
+Returns the pathname of the innermost script currently being evaluated, or the
+empty string if no pathname can be determined. If \fIfilename\fR is given,
+sets the return value of any future calls to \fBinfo script\fR for the duration
+of the innermost active script. This is useful in virtual file system
+applications.
.TP
\fBinfo sharedlibextension\fR
.
-Returns the extension used on this platform for the names of files
-containing shared libraries (for example, \fB.so\fR under Solaris).
-If shared libraries are not supported on this platform then an empty
-string is returned.
+Returns the extension used on this platform for names of shared libraries, e.g.
+\fB.so\fR under Solaris. Returns the empty string if shared libraries are not
+supported on this platform.
.TP
\fBinfo tclversion\fR
.
-Returns the value of the global variable \fBtcl_version\fR, which holds the
-major and minor version of the Tcl library by default.
+Returns the value of the global variable \fBtcl_version\fR, in which the
+major and minor version of the Tcl library are stored.
.TP
\fBinfo vars\fR ?\fIpattern\fR?
.
-If \fIpattern\fR is not specified,
-returns a list of all the names of currently-visible variables.
-This includes locals and currently-visible globals.
-If \fIpattern\fR is specified, only those names matching \fIpattern\fR
-are returned. Matching is determined using the same rules as for
-\fBstring match\fR.
-\fIpattern\fR can be a qualified name like \fBFoo::option*\fR.
-That is, it may specify a particular namespace
-using a sequence of namespace names separated by double colons (\fB::\fR),
-and may have pattern matching special characters
-at the end to specify a set of variables in that namespace.
-If \fIpattern\fR is a qualified name,
-the resulting list of variable names
-has each matching namespace variable qualified with the name
-of its namespace.
-Note that a currently-visible variable may not yet
-.QW exist
-if it has not
-been set (e.g. a variable declared but not set by \fBvariable\fR).
+If \fIpattern\fR is not given, returns the names of all visible variables. If
+\fIpattern\fR is given, returns only those names that match according to
+\fBstring match\fR. Only the last component of \fIpattern\fR is a pattern.
+Other components identify a namespace. See \fBNAMESPACE RESOLUTION\fR in the
+\fBnamespace\fR(n) documentation. When \fIpattern\fR is a qualified name,
+results are fully qualified.
+
+A variable that has declared but not yet defined is included in the results.
.SS "CLASS INTROSPECTION"
.PP
The following \fIsubcommand\fR values are supported by \fBinfo class\fR:
@@ -492,7 +402,7 @@ the class \fIclass\fR; the definition namespace only affects the instances of
actually useful on classes that are subclasses of \fBoo::class\fR).
.RS
.PP
-If \fIclass\fR does not provide a definition namespace of the specified kind,
+If \fIclass\fR does not provide a definition namespace of the given kind,
this command returns the empty string. In those circumstances, the
\fBoo::define\fR and \fBoo::objdefine\fR commands look up which definition
namespace to use using the class inheritance hierarchy.
@@ -523,7 +433,7 @@ instances to those that match it according to the rules of \fBstring match\fR.
.
This subcommand returns a list of all public (i.e. exported) methods of the
class called \fIclass\fR. Any of the following \fIoption\fRs may be
-specified, controlling exactly which method names are returned:
+given, controlling exactly which method names are returned:
.RS
.TP
\fB\-all\fR
@@ -600,7 +510,7 @@ This subcommand returns a list of all variables that have been declared for
the class named \fIclass\fR (i.e. that are automatically present in the
class's methods, constructor and destructor).
.VS TIP500
-If the \fB\-private\fR option is specified, this lists the private variables
+If the \fB\-private\fR option is given, this lists the private variables
declared instead.
.VE TIP500
.SS "OBJECT INTROSPECTION"
@@ -638,7 +548,7 @@ methods.
.TP
\fBinfo object class\fI object\fR ?\fIclassName\fR?
.
-If \fIclassName\fR is unspecified, this subcommand returns class of the
+If \fIclassName\fR is not given, this subcommand returns class of the
\fIobject\fR object. If \fIclassName\fR is present, this subcommand returns a
boolean value indicating whether the \fIobject\fR is of that class.
.TP
@@ -707,7 +617,7 @@ direct or indirect).
.
This subcommand returns a list of all public (i.e. exported) methods of the
object called \fIobject\fR. Any of the following \fIoption\fRs may be
-specified, controlling exactly which method names are returned:
+given, controlling exactly which method names are returned:
.RS
.TP
\fB\-all\fR
@@ -777,7 +687,7 @@ This subcommand returns a list of all variables that have been declared for
the object named \fIobject\fR (i.e. that are automatically present in the
object's methods).
.VS TIP500
-If the \fB\-private\fR option is specified, this lists the private variables
+If the \fB\-private\fR option is given, this lists the private variables
declared instead.
.VE TIP500
.TP
diff --git a/doc/mathop.n b/doc/mathop.n
index 4c16d76..84cf308 100644
--- a/doc/mathop.n
+++ b/doc/mathop.n
@@ -151,10 +151,11 @@ is the same as
.QW "\fB** 2 [** 3 4]\fR" .
Each \fInumber\fR may be
any numeric value, though the second number must not be fractional if the
-first is negative. If no arguments are given, the result will be one, and if
-only one argument is given, the result will be that argument. The
-result will have an integral value only when all arguments are
-integral values.
+first is negative. The maximum exponent value that Tcl can handle if the
+first number is an integer > 1 is 268435455. If no arguments are given,
+the result will be one, and if only one argument is given, the result will
+be that argument. The result will have an integral value only when all
+arguments are integral values.
.SS "COMPARISON OPERATORS"
.PP
The behaviors of the comparison operator commands (most of which operate
diff --git a/doc/timerate.n b/doc/timerate.n
new file mode 100644
index 0000000..5820d27
--- /dev/null
+++ b/doc/timerate.n
@@ -0,0 +1,129 @@
+'\"
+'\" Copyright (c) 2005 Sergey Brester aka sebres.
+'\"
+'\" See the file "license.terms" for information on usage and redistribution
+'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+'\"
+.TH timerate n "" Tcl "Tcl Built-In Commands"
+.so man.macros
+.BS
+'\" Note: do not modify the .SH NAME line immediately below!
+.SH NAME
+timerate \- Time-related execution resp. performance measurement of a script
+.SH SYNOPSIS
+\fBtimerate \fIscript\fR \fI?time ?max-count??\fR
+.sp
+\fBtimerate \fI?-direct?\fR \fI?-overhead double?\fR \fIscript\fR \fI?time ?max-count??\fR
+.sp
+\fBtimerate \fI?-calibrate?\fR \fI?-direct?\fR \fIscript\fR \fI?time ?max-count??\fR
+.BE
+.SH DESCRIPTION
+.PP
+The first and second form will evaluate \fIscript\fR until the interval
+\fItime\fR given in milliseconds elapses, or for 1000 milliseconds (1 second)
+if \fItime\fR is not specified.
+.sp
+The parameter \fImax-count\fR could additionally impose a further restriction
+by the maximal number of iterations to evaluate the script.
+If \fImax-count\fR is specified, the evalution will stop either this count of
+iterations is reached or the time is exceeded.
+.sp
+It will then return a canonical tcl-list of the form
+.PP
+.CS
+\fB0.095977 \(mcs/# 52095836 # 10419167 #/sec 5000.000 nett-ms\fR
+.CE
+.PP
+which indicates:
+.IP \(bu
+the average amount of time required per iteration, in microseconds ([\fBlindex\fR $result 0])
+.IP \(bu
+the count how many times it was executed ([\fBlindex\fR $result 2])
+.IP \(bu
+the estimated rate per second ([\fBlindex\fR $result 4])
+.IP \(bu
+the estimated real execution time without measurement overhead ([\fBlindex\fR $result 6])
+.PP
+Time is measured in elapsed time using the finest timer resolution as possible,
+not CPU time.
+This command may be used to provide information as to how well the script or a
+tcl-command is performing and can help determine bottlenecks and fine-tune
+application performance.
+.TP
+\fI-calibrate\fR
+.
+To measure very fast scripts as exact as posible the calibration process
+may be required.
+
+The \fI-calibrate\fR option is used to calibrate timerate, calculating the
+estimated overhead of the given script as the default overhead for future
+invocations of the \fBtimerate\fR command. If the \fItime\fR parameter is not
+specified, the calibrate procedure runs for up to 10 seconds.
+.TP
+\fI-overhead double\fR
+.
+The \fI-overhead\fR parameter supplies an estimate (in microseconds) of the
+measurement overhead of each iteration of the tested script. This quantity
+will be subtracted from the measured time prior to reporting results.
+.TP
+\fI-direct\fR
+.
+The \fI-direct\fR option causes direct execution of the supplied script,
+without compilation, in a manner similar to the \fBtime\fR command. It can be
+used to measure the cost of \fBTcl_EvalObjEx\fR, of the invocation of canonical
+lists, and of the uncompiled versions of bytecoded commands.
+.PP
+As opposed to the \fBtime\fR commmand, which runs the tested script for a fixed
+number of iterations, the timerate command runs it for a fixed time.
+Additionally, the compiled variant of the script will be used during the entire
+measurement, as if the script were part of a compiled procedure, if the \fI-direct\fR
+option is not specified. The fixed time period and possibility of compilation allow
+for more precise results and prevent very long execution times by slow scripts, making
+it practical for measuring scripts with highly uncertain execution times.
+
+.SH EXAMPLE
+Estimate how fast it takes for a simple Tcl \fBfor\fR loop (including
+operations on variable \fIi\fR) to count to a ten:
+.PP
+.CS
+# calibrate:
+timerate -calibrate {}
+# measure:
+timerate { for {set i 0} {$i<10} {incr i} {} } 5000
+.CE
+.PP
+Estimate how fast it takes for a simple Tcl \fBfor\fR loop, ignoring the
+overhead for to perform ten iterations, ignoring the overhead of the management
+of the variable that controls the loop:
+.PP
+.CS
+# calibrate for overhead of variable operations:
+set i 0; timerate -calibrate {expr {$i<10}; incr i} 1000
+# measure:
+timerate { for {set i 0} {$i<10} {incr i} {} } 5000
+.CE
+.PP
+Estimate the speed of calculating the hour of the day using \fBclock format\fR only,
+ignoring overhead of the portion of the script that prepares the time for it to
+calculate:
+.PP
+.CS
+# calibrate:
+timerate -calibrate {}
+# estimate overhead:
+set tm 0
+set ovh [lindex [timerate { incr tm [expr {24*60*60}] }] 0]
+# measure using esimated overhead:
+set tm 0
+timerate -overhead $ovh {
+ clock format $tm -format %H
+ incr tm [expr {24*60*60}]; # overhead for this is ignored
+} 5000
+.CE
+.SH "SEE ALSO"
+time(n)
+.SH KEYWORDS
+script, timerate, time
+.\" Local Variables:
+.\" mode: nroff
+.\" End:
diff --git a/doc/zipfs.n b/doc/zipfs.n
index c27b5d5..2d84173 100644
--- a/doc/zipfs.n
+++ b/doc/zipfs.n
@@ -110,7 +110,6 @@ for the current platform. On Windows, this value is
.QW \fBzipfs:/\fR .
On Unix, this value is
.QW \fB//zipfs:/\fR .
-.RE
.TP
\fBzipfs unmount \fImountpoint\fR
.
@@ -184,7 +183,7 @@ before unmounting it again:
.PP
.CS
set zip myApp.zip
-set base [file join [\fbzipfs root\fR] myApp]
+set base [file join [\fBzipfs root\fR] myApp]
\fBzipfs mount\fR $base $zip
# $base now has the contents of myApp.zip
@@ -213,7 +212,7 @@ building the ZIP and when mounting it.
set zip myApp.zip
set sourceDir [file normalize myApp]
set password "hunter2"
-set base [file join [\fbzipfs root\fR] myApp]
+set base [file join [\fBzipfs root\fR] myApp]
# Create with password
\fBzipfs mkzip\fR $targetZip $sourceDir $sourceDir $password
diff --git a/generic/regc_locale.c b/generic/regc_locale.c
index 002b264..0614fb6 100644
--- a/generic/regc_locale.c
+++ b/generic/regc_locale.c
@@ -153,46 +153,46 @@ static const crange alphaRangeTable[] = {
{0xc92, 0xca8}, {0xcaa, 0xcb3}, {0xcb5, 0xcb9}, {0xd05, 0xd0c},
{0xd0e, 0xd10}, {0xd12, 0xd3a}, {0xd54, 0xd56}, {0xd5f, 0xd61},
{0xd7a, 0xd7f}, {0xd85, 0xd96}, {0xd9a, 0xdb1}, {0xdb3, 0xdbb},
- {0xdc0, 0xdc6}, {0xe01, 0xe30}, {0xe40, 0xe46}, {0xe94, 0xe97},
- {0xe99, 0xe9f}, {0xea1, 0xea3}, {0xead, 0xeb0}, {0xec0, 0xec4},
- {0xedc, 0xedf}, {0xf40, 0xf47}, {0xf49, 0xf6c}, {0xf88, 0xf8c},
- {0x1000, 0x102a}, {0x1050, 0x1055}, {0x105a, 0x105d}, {0x106e, 0x1070},
- {0x1075, 0x1081}, {0x10a0, 0x10c5}, {0x10d0, 0x10fa}, {0x10fc, 0x1248},
- {0x124a, 0x124d}, {0x1250, 0x1256}, {0x125a, 0x125d}, {0x1260, 0x1288},
- {0x128a, 0x128d}, {0x1290, 0x12b0}, {0x12b2, 0x12b5}, {0x12b8, 0x12be},
- {0x12c2, 0x12c5}, {0x12c8, 0x12d6}, {0x12d8, 0x1310}, {0x1312, 0x1315},
- {0x1318, 0x135a}, {0x1380, 0x138f}, {0x13a0, 0x13f5}, {0x13f8, 0x13fd},
- {0x1401, 0x166c}, {0x166f, 0x167f}, {0x1681, 0x169a}, {0x16a0, 0x16ea},
- {0x16f1, 0x16f8}, {0x1700, 0x170c}, {0x170e, 0x1711}, {0x1720, 0x1731},
- {0x1740, 0x1751}, {0x1760, 0x176c}, {0x176e, 0x1770}, {0x1780, 0x17b3},
- {0x1820, 0x1878}, {0x1880, 0x1884}, {0x1887, 0x18a8}, {0x18b0, 0x18f5},
- {0x1900, 0x191e}, {0x1950, 0x196d}, {0x1970, 0x1974}, {0x1980, 0x19ab},
- {0x19b0, 0x19c9}, {0x1a00, 0x1a16}, {0x1a20, 0x1a54}, {0x1b05, 0x1b33},
- {0x1b45, 0x1b4b}, {0x1b83, 0x1ba0}, {0x1bba, 0x1be5}, {0x1c00, 0x1c23},
- {0x1c4d, 0x1c4f}, {0x1c5a, 0x1c7d}, {0x1c80, 0x1c88}, {0x1c90, 0x1cba},
- {0x1cbd, 0x1cbf}, {0x1ce9, 0x1cec}, {0x1cee, 0x1cf1}, {0x1d00, 0x1dbf},
- {0x1e00, 0x1f15}, {0x1f18, 0x1f1d}, {0x1f20, 0x1f45}, {0x1f48, 0x1f4d},
- {0x1f50, 0x1f57}, {0x1f5f, 0x1f7d}, {0x1f80, 0x1fb4}, {0x1fb6, 0x1fbc},
- {0x1fc2, 0x1fc4}, {0x1fc6, 0x1fcc}, {0x1fd0, 0x1fd3}, {0x1fd6, 0x1fdb},
- {0x1fe0, 0x1fec}, {0x1ff2, 0x1ff4}, {0x1ff6, 0x1ffc}, {0x2090, 0x209c},
- {0x210a, 0x2113}, {0x2119, 0x211d}, {0x212a, 0x212d}, {0x212f, 0x2139},
- {0x213c, 0x213f}, {0x2145, 0x2149}, {0x2c00, 0x2c2e}, {0x2c30, 0x2c5e},
- {0x2c60, 0x2ce4}, {0x2ceb, 0x2cee}, {0x2d00, 0x2d25}, {0x2d30, 0x2d67},
- {0x2d80, 0x2d96}, {0x2da0, 0x2da6}, {0x2da8, 0x2dae}, {0x2db0, 0x2db6},
- {0x2db8, 0x2dbe}, {0x2dc0, 0x2dc6}, {0x2dc8, 0x2dce}, {0x2dd0, 0x2dd6},
- {0x2dd8, 0x2dde}, {0x3031, 0x3035}, {0x3041, 0x3096}, {0x309d, 0x309f},
- {0x30a1, 0x30fa}, {0x30fc, 0x30ff}, {0x3105, 0x312f}, {0x3131, 0x318e},
- {0x31a0, 0x31ba}, {0x31f0, 0x31ff}, {0x3400, 0x4db5}, {0x4e00, 0x9fef},
- {0xa000, 0xa48c}, {0xa4d0, 0xa4fd}, {0xa500, 0xa60c}, {0xa610, 0xa61f},
- {0xa640, 0xa66e}, {0xa67f, 0xa69d}, {0xa6a0, 0xa6e5}, {0xa717, 0xa71f},
- {0xa722, 0xa788}, {0xa78b, 0xa7b9}, {0xa7f7, 0xa801}, {0xa803, 0xa805},
+ {0xdc0, 0xdc6}, {0xe01, 0xe30}, {0xe40, 0xe46}, {0xe86, 0xe8a},
+ {0xe8c, 0xea3}, {0xea7, 0xeb0}, {0xec0, 0xec4}, {0xedc, 0xedf},
+ {0xf40, 0xf47}, {0xf49, 0xf6c}, {0xf88, 0xf8c}, {0x1000, 0x102a},
+ {0x1050, 0x1055}, {0x105a, 0x105d}, {0x106e, 0x1070}, {0x1075, 0x1081},
+ {0x10a0, 0x10c5}, {0x10d0, 0x10fa}, {0x10fc, 0x1248}, {0x124a, 0x124d},
+ {0x1250, 0x1256}, {0x125a, 0x125d}, {0x1260, 0x1288}, {0x128a, 0x128d},
+ {0x1290, 0x12b0}, {0x12b2, 0x12b5}, {0x12b8, 0x12be}, {0x12c2, 0x12c5},
+ {0x12c8, 0x12d6}, {0x12d8, 0x1310}, {0x1312, 0x1315}, {0x1318, 0x135a},
+ {0x1380, 0x138f}, {0x13a0, 0x13f5}, {0x13f8, 0x13fd}, {0x1401, 0x166c},
+ {0x166f, 0x167f}, {0x1681, 0x169a}, {0x16a0, 0x16ea}, {0x16f1, 0x16f8},
+ {0x1700, 0x170c}, {0x170e, 0x1711}, {0x1720, 0x1731}, {0x1740, 0x1751},
+ {0x1760, 0x176c}, {0x176e, 0x1770}, {0x1780, 0x17b3}, {0x1820, 0x1878},
+ {0x1880, 0x1884}, {0x1887, 0x18a8}, {0x18b0, 0x18f5}, {0x1900, 0x191e},
+ {0x1950, 0x196d}, {0x1970, 0x1974}, {0x1980, 0x19ab}, {0x19b0, 0x19c9},
+ {0x1a00, 0x1a16}, {0x1a20, 0x1a54}, {0x1b05, 0x1b33}, {0x1b45, 0x1b4b},
+ {0x1b83, 0x1ba0}, {0x1bba, 0x1be5}, {0x1c00, 0x1c23}, {0x1c4d, 0x1c4f},
+ {0x1c5a, 0x1c7d}, {0x1c80, 0x1c88}, {0x1c90, 0x1cba}, {0x1cbd, 0x1cbf},
+ {0x1ce9, 0x1cec}, {0x1cee, 0x1cf3}, {0x1d00, 0x1dbf}, {0x1e00, 0x1f15},
+ {0x1f18, 0x1f1d}, {0x1f20, 0x1f45}, {0x1f48, 0x1f4d}, {0x1f50, 0x1f57},
+ {0x1f5f, 0x1f7d}, {0x1f80, 0x1fb4}, {0x1fb6, 0x1fbc}, {0x1fc2, 0x1fc4},
+ {0x1fc6, 0x1fcc}, {0x1fd0, 0x1fd3}, {0x1fd6, 0x1fdb}, {0x1fe0, 0x1fec},
+ {0x1ff2, 0x1ff4}, {0x1ff6, 0x1ffc}, {0x2090, 0x209c}, {0x210a, 0x2113},
+ {0x2119, 0x211d}, {0x212a, 0x212d}, {0x212f, 0x2139}, {0x213c, 0x213f},
+ {0x2145, 0x2149}, {0x2c00, 0x2c2e}, {0x2c30, 0x2c5e}, {0x2c60, 0x2ce4},
+ {0x2ceb, 0x2cee}, {0x2d00, 0x2d25}, {0x2d30, 0x2d67}, {0x2d80, 0x2d96},
+ {0x2da0, 0x2da6}, {0x2da8, 0x2dae}, {0x2db0, 0x2db6}, {0x2db8, 0x2dbe},
+ {0x2dc0, 0x2dc6}, {0x2dc8, 0x2dce}, {0x2dd0, 0x2dd6}, {0x2dd8, 0x2dde},
+ {0x3031, 0x3035}, {0x3041, 0x3096}, {0x309d, 0x309f}, {0x30a1, 0x30fa},
+ {0x30fc, 0x30ff}, {0x3105, 0x312f}, {0x3131, 0x318e}, {0x31a0, 0x31ba},
+ {0x31f0, 0x31ff}, {0x3400, 0x4db5}, {0x4e00, 0x9fef}, {0xa000, 0xa48c},
+ {0xa4d0, 0xa4fd}, {0xa500, 0xa60c}, {0xa610, 0xa61f}, {0xa640, 0xa66e},
+ {0xa67f, 0xa69d}, {0xa6a0, 0xa6e5}, {0xa717, 0xa71f}, {0xa722, 0xa788},
+ {0xa78b, 0xa7bf}, {0xa7c2, 0xa7c6}, {0xa7f7, 0xa801}, {0xa803, 0xa805},
{0xa807, 0xa80a}, {0xa80c, 0xa822}, {0xa840, 0xa873}, {0xa882, 0xa8b3},
{0xa8f2, 0xa8f7}, {0xa90a, 0xa925}, {0xa930, 0xa946}, {0xa960, 0xa97c},
{0xa984, 0xa9b2}, {0xa9e0, 0xa9e4}, {0xa9e6, 0xa9ef}, {0xa9fa, 0xa9fe},
{0xaa00, 0xaa28}, {0xaa40, 0xaa42}, {0xaa44, 0xaa4b}, {0xaa60, 0xaa76},
{0xaa7e, 0xaaaf}, {0xaab9, 0xaabd}, {0xaadb, 0xaadd}, {0xaae0, 0xaaea},
{0xaaf2, 0xaaf4}, {0xab01, 0xab06}, {0xab09, 0xab0e}, {0xab11, 0xab16},
- {0xab20, 0xab26}, {0xab28, 0xab2e}, {0xab30, 0xab5a}, {0xab5c, 0xab65},
+ {0xab20, 0xab26}, {0xab28, 0xab2e}, {0xab30, 0xab5a}, {0xab5c, 0xab67},
{0xab70, 0xabe2}, {0xac00, 0xd7a3}, {0xd7b0, 0xd7c6}, {0xd7cb, 0xd7fb},
{0xf900, 0xfa6d}, {0xfa70, 0xfad9}, {0xfb00, 0xfb06}, {0xfb13, 0xfb17},
{0xfb1f, 0xfb28}, {0xfb2a, 0xfb36}, {0xfb38, 0xfb3c}, {0xfb46, 0xfbb1},
@@ -213,21 +213,22 @@ static const crange alphaRangeTable[] = {
{0x10a80, 0x10a9c}, {0x10ac0, 0x10ac7}, {0x10ac9, 0x10ae4}, {0x10b00, 0x10b35},
{0x10b40, 0x10b55}, {0x10b60, 0x10b72}, {0x10b80, 0x10b91}, {0x10c00, 0x10c48},
{0x10c80, 0x10cb2}, {0x10cc0, 0x10cf2}, {0x10d00, 0x10d23}, {0x10f00, 0x10f1c},
- {0x10f30, 0x10f45}, {0x11003, 0x11037}, {0x11083, 0x110af}, {0x110d0, 0x110e8},
- {0x11103, 0x11126}, {0x11150, 0x11172}, {0x11183, 0x111b2}, {0x111c1, 0x111c4},
- {0x11200, 0x11211}, {0x11213, 0x1122b}, {0x11280, 0x11286}, {0x1128a, 0x1128d},
- {0x1128f, 0x1129d}, {0x1129f, 0x112a8}, {0x112b0, 0x112de}, {0x11305, 0x1130c},
- {0x11313, 0x11328}, {0x1132a, 0x11330}, {0x11335, 0x11339}, {0x1135d, 0x11361},
- {0x11400, 0x11434}, {0x11447, 0x1144a}, {0x11480, 0x114af}, {0x11580, 0x115ae},
- {0x115d8, 0x115db}, {0x11600, 0x1162f}, {0x11680, 0x116aa}, {0x11700, 0x1171a},
- {0x11800, 0x1182b}, {0x118a0, 0x118df}, {0x11a0b, 0x11a32}, {0x11a5c, 0x11a83},
- {0x11a86, 0x11a89}, {0x11ac0, 0x11af8}, {0x11c00, 0x11c08}, {0x11c0a, 0x11c2e},
- {0x11c72, 0x11c8f}, {0x11d00, 0x11d06}, {0x11d0b, 0x11d30}, {0x11d60, 0x11d65},
- {0x11d6a, 0x11d89}, {0x11ee0, 0x11ef2}, {0x12000, 0x12399}, {0x12480, 0x12543},
- {0x13000, 0x1342e}, {0x14400, 0x14646}, {0x16800, 0x16a38}, {0x16a40, 0x16a5e},
- {0x16ad0, 0x16aed}, {0x16b00, 0x16b2f}, {0x16b40, 0x16b43}, {0x16b63, 0x16b77},
- {0x16b7d, 0x16b8f}, {0x16e40, 0x16e7f}, {0x16f00, 0x16f44}, {0x16f93, 0x16f9f},
- {0x17000, 0x187f1}, {0x18800, 0x18af2}, {0x1b000, 0x1b11e}, {0x1b170, 0x1b2fb},
+ {0x10f30, 0x10f45}, {0x10fe0, 0x10ff6}, {0x11003, 0x11037}, {0x11083, 0x110af},
+ {0x110d0, 0x110e8}, {0x11103, 0x11126}, {0x11150, 0x11172}, {0x11183, 0x111b2},
+ {0x111c1, 0x111c4}, {0x11200, 0x11211}, {0x11213, 0x1122b}, {0x11280, 0x11286},
+ {0x1128a, 0x1128d}, {0x1128f, 0x1129d}, {0x1129f, 0x112a8}, {0x112b0, 0x112de},
+ {0x11305, 0x1130c}, {0x11313, 0x11328}, {0x1132a, 0x11330}, {0x11335, 0x11339},
+ {0x1135d, 0x11361}, {0x11400, 0x11434}, {0x11447, 0x1144a}, {0x11480, 0x114af},
+ {0x11580, 0x115ae}, {0x115d8, 0x115db}, {0x11600, 0x1162f}, {0x11680, 0x116aa},
+ {0x11700, 0x1171a}, {0x11800, 0x1182b}, {0x118a0, 0x118df}, {0x119a0, 0x119a7},
+ {0x119aa, 0x119d0}, {0x11a0b, 0x11a32}, {0x11a5c, 0x11a89}, {0x11ac0, 0x11af8},
+ {0x11c00, 0x11c08}, {0x11c0a, 0x11c2e}, {0x11c72, 0x11c8f}, {0x11d00, 0x11d06},
+ {0x11d0b, 0x11d30}, {0x11d60, 0x11d65}, {0x11d6a, 0x11d89}, {0x11ee0, 0x11ef2},
+ {0x12000, 0x12399}, {0x12480, 0x12543}, {0x13000, 0x1342e}, {0x14400, 0x14646},
+ {0x16800, 0x16a38}, {0x16a40, 0x16a5e}, {0x16ad0, 0x16aed}, {0x16b00, 0x16b2f},
+ {0x16b40, 0x16b43}, {0x16b63, 0x16b77}, {0x16b7d, 0x16b8f}, {0x16e40, 0x16e7f},
+ {0x16f00, 0x16f4a}, {0x16f93, 0x16f9f}, {0x17000, 0x187f7}, {0x18800, 0x18af2},
+ {0x1b000, 0x1b11e}, {0x1b150, 0x1b152}, {0x1b164, 0x1b167}, {0x1b170, 0x1b2fb},
{0x1bc00, 0x1bc6a}, {0x1bc70, 0x1bc7c}, {0x1bc80, 0x1bc88}, {0x1bc90, 0x1bc99},
{0x1d400, 0x1d454}, {0x1d456, 0x1d49c}, {0x1d4a9, 0x1d4ac}, {0x1d4ae, 0x1d4b9},
{0x1d4bd, 0x1d4c3}, {0x1d4c5, 0x1d505}, {0x1d507, 0x1d50a}, {0x1d50d, 0x1d514},
@@ -235,12 +236,13 @@ static const crange alphaRangeTable[] = {
{0x1d54a, 0x1d550}, {0x1d552, 0x1d6a5}, {0x1d6a8, 0x1d6c0}, {0x1d6c2, 0x1d6da},
{0x1d6dc, 0x1d6fa}, {0x1d6fc, 0x1d714}, {0x1d716, 0x1d734}, {0x1d736, 0x1d74e},
{0x1d750, 0x1d76e}, {0x1d770, 0x1d788}, {0x1d78a, 0x1d7a8}, {0x1d7aa, 0x1d7c2},
- {0x1d7c4, 0x1d7cb}, {0x1e800, 0x1e8c4}, {0x1e900, 0x1e943}, {0x1ee00, 0x1ee03},
- {0x1ee05, 0x1ee1f}, {0x1ee29, 0x1ee32}, {0x1ee34, 0x1ee37}, {0x1ee4d, 0x1ee4f},
- {0x1ee67, 0x1ee6a}, {0x1ee6c, 0x1ee72}, {0x1ee74, 0x1ee77}, {0x1ee79, 0x1ee7c},
- {0x1ee80, 0x1ee89}, {0x1ee8b, 0x1ee9b}, {0x1eea1, 0x1eea3}, {0x1eea5, 0x1eea9},
- {0x1eeab, 0x1eebb}, {0x20000, 0x2a6d6}, {0x2a700, 0x2b734}, {0x2b740, 0x2b81d},
- {0x2b820, 0x2cea1}, {0x2ceb0, 0x2ebe0}, {0x2f800, 0x2fa1d}
+ {0x1d7c4, 0x1d7cb}, {0x1e100, 0x1e12c}, {0x1e137, 0x1e13d}, {0x1e2c0, 0x1e2eb},
+ {0x1e800, 0x1e8c4}, {0x1e900, 0x1e943}, {0x1ee00, 0x1ee03}, {0x1ee05, 0x1ee1f},
+ {0x1ee29, 0x1ee32}, {0x1ee34, 0x1ee37}, {0x1ee4d, 0x1ee4f}, {0x1ee67, 0x1ee6a},
+ {0x1ee6c, 0x1ee72}, {0x1ee74, 0x1ee77}, {0x1ee79, 0x1ee7c}, {0x1ee80, 0x1ee89},
+ {0x1ee8b, 0x1ee9b}, {0x1eea1, 0x1eea3}, {0x1eea5, 0x1eea9}, {0x1eeab, 0x1eebb},
+ {0x20000, 0x2a6d6}, {0x2a700, 0x2b734}, {0x2b740, 0x2b81d}, {0x2b820, 0x2cea1},
+ {0x2ceb0, 0x2ebe0}, {0x2f800, 0x2fa1d}
#endif
};
@@ -257,24 +259,24 @@ static const chr alphaCharTable[] = {
0xb83, 0xb99, 0xb9a, 0xb9c, 0xb9e, 0xb9f, 0xba3, 0xba4, 0xbd0,
0xc3d, 0xc60, 0xc61, 0xc80, 0xcbd, 0xcde, 0xce0, 0xce1, 0xcf1,
0xcf2, 0xd3d, 0xd4e, 0xdbd, 0xe32, 0xe33, 0xe81, 0xe82, 0xe84,
- 0xe87, 0xe88, 0xe8a, 0xe8d, 0xea5, 0xea7, 0xeaa, 0xeab, 0xeb2,
- 0xeb3, 0xebd, 0xec6, 0xf00, 0x103f, 0x1061, 0x1065, 0x1066, 0x108e,
- 0x10c7, 0x10cd, 0x1258, 0x12c0, 0x17d7, 0x17dc, 0x18aa, 0x1aa7, 0x1bae,
- 0x1baf, 0x1cf5, 0x1cf6, 0x1f59, 0x1f5b, 0x1f5d, 0x1fbe, 0x2071, 0x207f,
- 0x2102, 0x2107, 0x2115, 0x2124, 0x2126, 0x2128, 0x214e, 0x2183, 0x2184,
- 0x2cf2, 0x2cf3, 0x2d27, 0x2d2d, 0x2d6f, 0x2e2f, 0x3005, 0x3006, 0x303b,
- 0x303c, 0xa62a, 0xa62b, 0xa8fb, 0xa8fd, 0xa8fe, 0xa9cf, 0xaa7a, 0xaab1,
- 0xaab5, 0xaab6, 0xaac0, 0xaac2, 0xfb1d, 0xfb3e, 0xfb40, 0xfb41, 0xfb43,
- 0xfb44
+ 0xea5, 0xeb2, 0xeb3, 0xebd, 0xec6, 0xf00, 0x103f, 0x1061, 0x1065,
+ 0x1066, 0x108e, 0x10c7, 0x10cd, 0x1258, 0x12c0, 0x17d7, 0x17dc, 0x18aa,
+ 0x1aa7, 0x1bae, 0x1baf, 0x1cf5, 0x1cf6, 0x1cfa, 0x1f59, 0x1f5b, 0x1f5d,
+ 0x1fbe, 0x2071, 0x207f, 0x2102, 0x2107, 0x2115, 0x2124, 0x2126, 0x2128,
+ 0x214e, 0x2183, 0x2184, 0x2cf2, 0x2cf3, 0x2d27, 0x2d2d, 0x2d6f, 0x2e2f,
+ 0x3005, 0x3006, 0x303b, 0x303c, 0xa62a, 0xa62b, 0xa8fb, 0xa8fd, 0xa8fe,
+ 0xa9cf, 0xaa7a, 0xaab1, 0xaab5, 0xaab6, 0xaac0, 0xaac2, 0xfb1d, 0xfb3e,
+ 0xfb40, 0xfb41, 0xfb43, 0xfb44
#if CHRBITS > 16
,0x1003c, 0x1003d, 0x10808, 0x10837, 0x10838, 0x1083c, 0x108f4, 0x108f5, 0x109be,
0x109bf, 0x10a00, 0x10f27, 0x11144, 0x11176, 0x111da, 0x111dc, 0x11288, 0x1130f,
- 0x11310, 0x11332, 0x11333, 0x1133d, 0x11350, 0x114c4, 0x114c5, 0x114c7, 0x11644,
- 0x118ff, 0x11a00, 0x11a3a, 0x11a50, 0x11a9d, 0x11c40, 0x11d08, 0x11d09, 0x11d46,
- 0x11d67, 0x11d68, 0x11d98, 0x16f50, 0x16fe0, 0x16fe1, 0x1d49e, 0x1d49f, 0x1d4a2,
- 0x1d4a5, 0x1d4a6, 0x1d4bb, 0x1d546, 0x1ee21, 0x1ee22, 0x1ee24, 0x1ee27, 0x1ee39,
- 0x1ee3b, 0x1ee42, 0x1ee47, 0x1ee49, 0x1ee4b, 0x1ee51, 0x1ee52, 0x1ee54, 0x1ee57,
- 0x1ee59, 0x1ee5b, 0x1ee5d, 0x1ee5f, 0x1ee61, 0x1ee62, 0x1ee64, 0x1ee7e
+ 0x11310, 0x11332, 0x11333, 0x1133d, 0x11350, 0x1145f, 0x114c4, 0x114c5, 0x114c7,
+ 0x11644, 0x116b8, 0x118ff, 0x119e1, 0x119e3, 0x11a00, 0x11a3a, 0x11a50, 0x11a9d,
+ 0x11c40, 0x11d08, 0x11d09, 0x11d46, 0x11d67, 0x11d68, 0x11d98, 0x16f50, 0x16fe0,
+ 0x16fe1, 0x16fe3, 0x1d49e, 0x1d49f, 0x1d4a2, 0x1d4a5, 0x1d4a6, 0x1d4bb, 0x1d546,
+ 0x1e14e, 0x1e94b, 0x1ee21, 0x1ee22, 0x1ee24, 0x1ee27, 0x1ee39, 0x1ee3b, 0x1ee42,
+ 0x1ee47, 0x1ee49, 0x1ee4b, 0x1ee51, 0x1ee52, 0x1ee54, 0x1ee57, 0x1ee59, 0x1ee5b,
+ 0x1ee5d, 0x1ee5f, 0x1ee61, 0x1ee62, 0x1ee64, 0x1ee7e
#endif
};
@@ -289,8 +291,8 @@ static const crange controlRangeTable[] = {
{0x202a, 0x202e}, {0x2060, 0x2064}, {0x2066, 0x206f}, {0xe000, 0xf8ff},
{0xfff9, 0xfffb}
#if CHRBITS > 16
- ,{0x1bca0, 0x1bca3}, {0x1d173, 0x1d17a}, {0xe0020, 0xe007f}, {0xf0000, 0xffffd},
- {0x100000, 0x10fffd}
+ ,{0x13430, 0x13438}, {0x1bca0, 0x1bca3}, {0x1d173, 0x1d17a}, {0xe0020, 0xe007f},
+ {0xf0000, 0xffffd}, {0x100000, 0x10fffd}
#endif
};
@@ -325,7 +327,8 @@ static const crange digitRangeTable[] = {
{0x11136, 0x1113f}, {0x111d0, 0x111d9}, {0x112f0, 0x112f9}, {0x11450, 0x11459},
{0x114d0, 0x114d9}, {0x11650, 0x11659}, {0x116c0, 0x116c9}, {0x11730, 0x11739},
{0x118e0, 0x118e9}, {0x11c50, 0x11c59}, {0x11d50, 0x11d59}, {0x11da0, 0x11da9},
- {0x16a60, 0x16a69}, {0x16b50, 0x16b59}, {0x1d7ce, 0x1d7ff}, {0x1e950, 0x1e959}
+ {0x16a60, 0x16a69}, {0x16b50, 0x16b59}, {0x1d7ce, 0x1d7ff}, {0x1e140, 0x1e149},
+ {0x1e2f0, 0x1e2f9}, {0x1e950, 0x1e959}
#endif
};
@@ -348,7 +351,7 @@ static const crange punctRangeTable[] = {
{0x1b5a, 0x1b60}, {0x1bfc, 0x1bff}, {0x1c3b, 0x1c3f}, {0x1cc0, 0x1cc7},
{0x2010, 0x2027}, {0x2030, 0x2043}, {0x2045, 0x2051}, {0x2053, 0x205e},
{0x2308, 0x230b}, {0x2768, 0x2775}, {0x27e6, 0x27ef}, {0x2983, 0x2998},
- {0x29d8, 0x29db}, {0x2cf9, 0x2cfc}, {0x2e00, 0x2e2e}, {0x2e30, 0x2e4e},
+ {0x29d8, 0x29db}, {0x2cf9, 0x2cfc}, {0x2e00, 0x2e2e}, {0x2e30, 0x2e4f},
{0x3001, 0x3003}, {0x3008, 0x3011}, {0x3014, 0x301f}, {0xa60d, 0xa60f},
{0xa6f2, 0xa6f7}, {0xa874, 0xa877}, {0xa8f8, 0xa8fa}, {0xa9c1, 0xa9cd},
{0xaa5c, 0xaa5f}, {0xfe10, 0xfe19}, {0xfe30, 0xfe52}, {0xfe54, 0xfe61},
@@ -372,8 +375,8 @@ static const chr punctCharTable[] = {
0xab, 0xb6, 0xb7, 0xbb, 0xbf, 0x37e, 0x387, 0x589, 0x58a,
0x5be, 0x5c0, 0x5c3, 0x5c6, 0x5f3, 0x5f4, 0x609, 0x60a, 0x60c,
0x60d, 0x61b, 0x61e, 0x61f, 0x6d4, 0x85e, 0x964, 0x965, 0x970,
- 0x9fd, 0xa76, 0xaf0, 0xc84, 0xdf4, 0xe4f, 0xe5a, 0xe5b, 0xf14,
- 0xf85, 0xfd9, 0xfda, 0x10fb, 0x1400, 0x166d, 0x166e, 0x169b, 0x169c,
+ 0x9fd, 0xa76, 0xaf0, 0xc77, 0xc84, 0xdf4, 0xe4f, 0xe5a, 0xe5b,
+ 0xf14, 0xf85, 0xfd9, 0xfda, 0x10fb, 0x1400, 0x166e, 0x169b, 0x169c,
0x1735, 0x1736, 0x1944, 0x1945, 0x1a1e, 0x1a1f, 0x1c7e, 0x1c7f, 0x1cd3,
0x207d, 0x207e, 0x208d, 0x208e, 0x2329, 0x232a, 0x27c5, 0x27c6, 0x29fc,
0x29fd, 0x2cfe, 0x2cff, 0x2d70, 0x3030, 0x303d, 0x30a0, 0x30fb, 0xa4fe,
@@ -384,8 +387,8 @@ static const chr punctCharTable[] = {
#if CHRBITS > 16
,0x1039f, 0x103d0, 0x1056f, 0x10857, 0x1091f, 0x1093f, 0x10a7f, 0x110bb, 0x110bc,
0x11174, 0x11175, 0x111cd, 0x111db, 0x112a9, 0x1145b, 0x1145d, 0x114c6, 0x1183b,
- 0x11c70, 0x11c71, 0x11ef7, 0x11ef8, 0x16a6e, 0x16a6f, 0x16af5, 0x16b44, 0x1bc9f,
- 0x1e95e, 0x1e95f
+ 0x119e2, 0x11c70, 0x11c71, 0x11ef7, 0x11ef8, 0x11fff, 0x16a6e, 0x16a6f, 0x16af5,
+ 0x16b44, 0x16fe2, 0x1bc9f, 0x1e95e, 0x1e95f
#endif
};
@@ -424,7 +427,7 @@ static const crange lowerRangeTable[] = {
{0x1f90, 0x1f97}, {0x1fa0, 0x1fa7}, {0x1fb0, 0x1fb4}, {0x1fc2, 0x1fc4},
{0x1fd0, 0x1fd3}, {0x1fe0, 0x1fe7}, {0x1ff2, 0x1ff4}, {0x2146, 0x2149},
{0x2c30, 0x2c5e}, {0x2c76, 0x2c7b}, {0x2d00, 0x2d25}, {0xa72f, 0xa731},
- {0xa771, 0xa778}, {0xa793, 0xa795}, {0xab30, 0xab5a}, {0xab60, 0xab65},
+ {0xa771, 0xa778}, {0xa793, 0xa795}, {0xab30, 0xab5a}, {0xab60, 0xab67},
{0xab70, 0xabbf}, {0xfb00, 0xfb06}, {0xfb13, 0xfb17}, {0xff41, 0xff5a}
#if CHRBITS > 16
,{0x10428, 0x1044f}, {0x104d8, 0x104fb}, {0x10cc0, 0x10cf2}, {0x118c0, 0x118df},
@@ -504,7 +507,7 @@ static const chr lowerCharTable[] = {
0xa763, 0xa765, 0xa767, 0xa769, 0xa76b, 0xa76d, 0xa76f, 0xa77a, 0xa77c,
0xa77f, 0xa781, 0xa783, 0xa785, 0xa787, 0xa78c, 0xa78e, 0xa791, 0xa797,
0xa799, 0xa79b, 0xa79d, 0xa79f, 0xa7a1, 0xa7a3, 0xa7a5, 0xa7a7, 0xa7a9,
- 0xa7af, 0xa7b5, 0xa7b7, 0xa7b9, 0xa7fa
+ 0xa7af, 0xa7b5, 0xa7b7, 0xa7b9, 0xa7bb, 0xa7bd, 0xa7bf, 0xa7c3, 0xa7fa
#if CHRBITS > 16
,0x1d4bb, 0x1d7cb
#endif
@@ -527,7 +530,7 @@ static const crange upperRangeTable[] = {
{0x1fe8, 0x1fec}, {0x1ff8, 0x1ffb}, {0x210b, 0x210d}, {0x2110, 0x2112},
{0x2119, 0x211d}, {0x212a, 0x212d}, {0x2130, 0x2133}, {0x2c00, 0x2c2e},
{0x2c62, 0x2c64}, {0x2c6d, 0x2c70}, {0x2c7e, 0x2c80}, {0xa7aa, 0xa7ae},
- {0xa7b0, 0xa7b4}, {0xff21, 0xff3a}
+ {0xa7b0, 0xa7b4}, {0xa7c4, 0xa7c6}, {0xff21, 0xff3a}
#if CHRBITS > 16
,{0x10400, 0x10427}, {0x104b0, 0x104d3}, {0x10c80, 0x10cb2}, {0x118a0, 0x118bf},
{0x16e40, 0x16e5f}, {0x1d400, 0x1d419}, {0x1d434, 0x1d44d}, {0x1d468, 0x1d481},
@@ -606,7 +609,7 @@ static const chr upperCharTable[] = {
0xa768, 0xa76a, 0xa76c, 0xa76e, 0xa779, 0xa77b, 0xa77d, 0xa77e, 0xa780,
0xa782, 0xa784, 0xa786, 0xa78b, 0xa78d, 0xa790, 0xa792, 0xa796, 0xa798,
0xa79a, 0xa79c, 0xa79e, 0xa7a0, 0xa7a2, 0xa7a4, 0xa7a6, 0xa7a8, 0xa7b6,
- 0xa7b8
+ 0xa7b8, 0xa7ba, 0xa7bc, 0xa7be, 0xa7c2
#if CHRBITS > 16
,0x1d49c, 0x1d49e, 0x1d49f, 0x1d4a2, 0x1d4a5, 0x1d4a6, 0x1d504, 0x1d505, 0x1d538,
0x1d539, 0x1d546, 0x1d7ca
@@ -640,54 +643,53 @@ static const crange graphRangeTable[] = {
{0xbae, 0xbb9}, {0xbbe, 0xbc2}, {0xbc6, 0xbc8}, {0xbca, 0xbcd},
{0xbe6, 0xbfa}, {0xc00, 0xc0c}, {0xc0e, 0xc10}, {0xc12, 0xc28},
{0xc2a, 0xc39}, {0xc3d, 0xc44}, {0xc46, 0xc48}, {0xc4a, 0xc4d},
- {0xc58, 0xc5a}, {0xc60, 0xc63}, {0xc66, 0xc6f}, {0xc78, 0xc8c},
+ {0xc58, 0xc5a}, {0xc60, 0xc63}, {0xc66, 0xc6f}, {0xc77, 0xc8c},
{0xc8e, 0xc90}, {0xc92, 0xca8}, {0xcaa, 0xcb3}, {0xcb5, 0xcb9},
{0xcbc, 0xcc4}, {0xcc6, 0xcc8}, {0xcca, 0xccd}, {0xce0, 0xce3},
{0xce6, 0xcef}, {0xd00, 0xd03}, {0xd05, 0xd0c}, {0xd0e, 0xd10},
{0xd12, 0xd44}, {0xd46, 0xd48}, {0xd4a, 0xd4f}, {0xd54, 0xd63},
{0xd66, 0xd7f}, {0xd85, 0xd96}, {0xd9a, 0xdb1}, {0xdb3, 0xdbb},
{0xdc0, 0xdc6}, {0xdcf, 0xdd4}, {0xdd8, 0xddf}, {0xde6, 0xdef},
- {0xdf2, 0xdf4}, {0xe01, 0xe3a}, {0xe3f, 0xe5b}, {0xe94, 0xe97},
- {0xe99, 0xe9f}, {0xea1, 0xea3}, {0xead, 0xeb9}, {0xebb, 0xebd},
- {0xec0, 0xec4}, {0xec8, 0xecd}, {0xed0, 0xed9}, {0xedc, 0xedf},
- {0xf00, 0xf47}, {0xf49, 0xf6c}, {0xf71, 0xf97}, {0xf99, 0xfbc},
- {0xfbe, 0xfcc}, {0xfce, 0xfda}, {0x1000, 0x10c5}, {0x10d0, 0x1248},
- {0x124a, 0x124d}, {0x1250, 0x1256}, {0x125a, 0x125d}, {0x1260, 0x1288},
- {0x128a, 0x128d}, {0x1290, 0x12b0}, {0x12b2, 0x12b5}, {0x12b8, 0x12be},
- {0x12c2, 0x12c5}, {0x12c8, 0x12d6}, {0x12d8, 0x1310}, {0x1312, 0x1315},
- {0x1318, 0x135a}, {0x135d, 0x137c}, {0x1380, 0x1399}, {0x13a0, 0x13f5},
- {0x13f8, 0x13fd}, {0x1400, 0x167f}, {0x1681, 0x169c}, {0x16a0, 0x16f8},
- {0x1700, 0x170c}, {0x170e, 0x1714}, {0x1720, 0x1736}, {0x1740, 0x1753},
- {0x1760, 0x176c}, {0x176e, 0x1770}, {0x1780, 0x17dd}, {0x17e0, 0x17e9},
- {0x17f0, 0x17f9}, {0x1800, 0x180d}, {0x1810, 0x1819}, {0x1820, 0x1878},
- {0x1880, 0x18aa}, {0x18b0, 0x18f5}, {0x1900, 0x191e}, {0x1920, 0x192b},
- {0x1930, 0x193b}, {0x1944, 0x196d}, {0x1970, 0x1974}, {0x1980, 0x19ab},
- {0x19b0, 0x19c9}, {0x19d0, 0x19da}, {0x19de, 0x1a1b}, {0x1a1e, 0x1a5e},
- {0x1a60, 0x1a7c}, {0x1a7f, 0x1a89}, {0x1a90, 0x1a99}, {0x1aa0, 0x1aad},
- {0x1ab0, 0x1abe}, {0x1b00, 0x1b4b}, {0x1b50, 0x1b7c}, {0x1b80, 0x1bf3},
- {0x1bfc, 0x1c37}, {0x1c3b, 0x1c49}, {0x1c4d, 0x1c88}, {0x1c90, 0x1cba},
- {0x1cbd, 0x1cc7}, {0x1cd0, 0x1cf9}, {0x1d00, 0x1df9}, {0x1dfb, 0x1f15},
- {0x1f18, 0x1f1d}, {0x1f20, 0x1f45}, {0x1f48, 0x1f4d}, {0x1f50, 0x1f57},
- {0x1f5f, 0x1f7d}, {0x1f80, 0x1fb4}, {0x1fb6, 0x1fc4}, {0x1fc6, 0x1fd3},
- {0x1fd6, 0x1fdb}, {0x1fdd, 0x1fef}, {0x1ff2, 0x1ff4}, {0x1ff6, 0x1ffe},
- {0x2010, 0x2027}, {0x2030, 0x205e}, {0x2074, 0x208e}, {0x2090, 0x209c},
- {0x20a0, 0x20bf}, {0x20d0, 0x20f0}, {0x2100, 0x218b}, {0x2190, 0x2426},
- {0x2440, 0x244a}, {0x2460, 0x2b73}, {0x2b76, 0x2b95}, {0x2b98, 0x2bc8},
- {0x2bca, 0x2bfe}, {0x2c00, 0x2c2e}, {0x2c30, 0x2c5e}, {0x2c60, 0x2cf3},
+ {0xdf2, 0xdf4}, {0xe01, 0xe3a}, {0xe3f, 0xe5b}, {0xe86, 0xe8a},
+ {0xe8c, 0xea3}, {0xea7, 0xebd}, {0xec0, 0xec4}, {0xec8, 0xecd},
+ {0xed0, 0xed9}, {0xedc, 0xedf}, {0xf00, 0xf47}, {0xf49, 0xf6c},
+ {0xf71, 0xf97}, {0xf99, 0xfbc}, {0xfbe, 0xfcc}, {0xfce, 0xfda},
+ {0x1000, 0x10c5}, {0x10d0, 0x1248}, {0x124a, 0x124d}, {0x1250, 0x1256},
+ {0x125a, 0x125d}, {0x1260, 0x1288}, {0x128a, 0x128d}, {0x1290, 0x12b0},
+ {0x12b2, 0x12b5}, {0x12b8, 0x12be}, {0x12c2, 0x12c5}, {0x12c8, 0x12d6},
+ {0x12d8, 0x1310}, {0x1312, 0x1315}, {0x1318, 0x135a}, {0x135d, 0x137c},
+ {0x1380, 0x1399}, {0x13a0, 0x13f5}, {0x13f8, 0x13fd}, {0x1400, 0x167f},
+ {0x1681, 0x169c}, {0x16a0, 0x16f8}, {0x1700, 0x170c}, {0x170e, 0x1714},
+ {0x1720, 0x1736}, {0x1740, 0x1753}, {0x1760, 0x176c}, {0x176e, 0x1770},
+ {0x1780, 0x17dd}, {0x17e0, 0x17e9}, {0x17f0, 0x17f9}, {0x1800, 0x180d},
+ {0x1810, 0x1819}, {0x1820, 0x1878}, {0x1880, 0x18aa}, {0x18b0, 0x18f5},
+ {0x1900, 0x191e}, {0x1920, 0x192b}, {0x1930, 0x193b}, {0x1944, 0x196d},
+ {0x1970, 0x1974}, {0x1980, 0x19ab}, {0x19b0, 0x19c9}, {0x19d0, 0x19da},
+ {0x19de, 0x1a1b}, {0x1a1e, 0x1a5e}, {0x1a60, 0x1a7c}, {0x1a7f, 0x1a89},
+ {0x1a90, 0x1a99}, {0x1aa0, 0x1aad}, {0x1ab0, 0x1abe}, {0x1b00, 0x1b4b},
+ {0x1b50, 0x1b7c}, {0x1b80, 0x1bf3}, {0x1bfc, 0x1c37}, {0x1c3b, 0x1c49},
+ {0x1c4d, 0x1c88}, {0x1c90, 0x1cba}, {0x1cbd, 0x1cc7}, {0x1cd0, 0x1cfa},
+ {0x1d00, 0x1df9}, {0x1dfb, 0x1f15}, {0x1f18, 0x1f1d}, {0x1f20, 0x1f45},
+ {0x1f48, 0x1f4d}, {0x1f50, 0x1f57}, {0x1f5f, 0x1f7d}, {0x1f80, 0x1fb4},
+ {0x1fb6, 0x1fc4}, {0x1fc6, 0x1fd3}, {0x1fd6, 0x1fdb}, {0x1fdd, 0x1fef},
+ {0x1ff2, 0x1ff4}, {0x1ff6, 0x1ffe}, {0x2010, 0x2027}, {0x2030, 0x205e},
+ {0x2074, 0x208e}, {0x2090, 0x209c}, {0x20a0, 0x20bf}, {0x20d0, 0x20f0},
+ {0x2100, 0x218b}, {0x2190, 0x2426}, {0x2440, 0x244a}, {0x2460, 0x2b73},
+ {0x2b76, 0x2b95}, {0x2b98, 0x2c2e}, {0x2c30, 0x2c5e}, {0x2c60, 0x2cf3},
{0x2cf9, 0x2d25}, {0x2d30, 0x2d67}, {0x2d7f, 0x2d96}, {0x2da0, 0x2da6},
{0x2da8, 0x2dae}, {0x2db0, 0x2db6}, {0x2db8, 0x2dbe}, {0x2dc0, 0x2dc6},
- {0x2dc8, 0x2dce}, {0x2dd0, 0x2dd6}, {0x2dd8, 0x2dde}, {0x2de0, 0x2e4e},
+ {0x2dc8, 0x2dce}, {0x2dd0, 0x2dd6}, {0x2dd8, 0x2dde}, {0x2de0, 0x2e4f},
{0x2e80, 0x2e99}, {0x2e9b, 0x2ef3}, {0x2f00, 0x2fd5}, {0x2ff0, 0x2ffb},
{0x3001, 0x303f}, {0x3041, 0x3096}, {0x3099, 0x30ff}, {0x3105, 0x312f},
{0x3131, 0x318e}, {0x3190, 0x31ba}, {0x31c0, 0x31e3}, {0x31f0, 0x321e},
- {0x3220, 0x32fe}, {0x3300, 0x4db5}, {0x4dc0, 0x9fef}, {0xa000, 0xa48c},
- {0xa490, 0xa4c6}, {0xa4d0, 0xa62b}, {0xa640, 0xa6f7}, {0xa700, 0xa7b9},
+ {0x3220, 0x4db5}, {0x4dc0, 0x9fef}, {0xa000, 0xa48c}, {0xa490, 0xa4c6},
+ {0xa4d0, 0xa62b}, {0xa640, 0xa6f7}, {0xa700, 0xa7bf}, {0xa7c2, 0xa7c6},
{0xa7f7, 0xa82b}, {0xa830, 0xa839}, {0xa840, 0xa877}, {0xa880, 0xa8c5},
{0xa8ce, 0xa8d9}, {0xa8e0, 0xa953}, {0xa95f, 0xa97c}, {0xa980, 0xa9cd},
{0xa9cf, 0xa9d9}, {0xa9de, 0xa9fe}, {0xaa00, 0xaa36}, {0xaa40, 0xaa4d},
{0xaa50, 0xaa59}, {0xaa5c, 0xaac2}, {0xaadb, 0xaaf6}, {0xab01, 0xab06},
{0xab09, 0xab0e}, {0xab11, 0xab16}, {0xab20, 0xab26}, {0xab28, 0xab2e},
- {0xab30, 0xab65}, {0xab70, 0xabed}, {0xabf0, 0xabf9}, {0xac00, 0xd7a3},
+ {0xab30, 0xab67}, {0xab70, 0xabed}, {0xabf0, 0xabf9}, {0xac00, 0xd7a3},
{0xd7b0, 0xd7c6}, {0xd7cb, 0xd7fb}, {0xf900, 0xfa6d}, {0xfa70, 0xfad9},
{0xfb00, 0xfb06}, {0xfb13, 0xfb17}, {0xfb1d, 0xfb36}, {0xfb38, 0xfb3c},
{0xfb46, 0xfbc1}, {0xfbd3, 0xfd3f}, {0xfd50, 0xfd8f}, {0xfd92, 0xfdc7},
@@ -711,29 +713,31 @@ static const crange graphRangeTable[] = {
{0x10aeb, 0x10af6}, {0x10b00, 0x10b35}, {0x10b39, 0x10b55}, {0x10b58, 0x10b72},
{0x10b78, 0x10b91}, {0x10b99, 0x10b9c}, {0x10ba9, 0x10baf}, {0x10c00, 0x10c48},
{0x10c80, 0x10cb2}, {0x10cc0, 0x10cf2}, {0x10cfa, 0x10d27}, {0x10d30, 0x10d39},
- {0x10e60, 0x10e7e}, {0x10f00, 0x10f27}, {0x10f30, 0x10f59}, {0x11000, 0x1104d},
- {0x11052, 0x1106f}, {0x1107f, 0x110bc}, {0x110be, 0x110c1}, {0x110d0, 0x110e8},
- {0x110f0, 0x110f9}, {0x11100, 0x11134}, {0x11136, 0x11146}, {0x11150, 0x11176},
- {0x11180, 0x111cd}, {0x111d0, 0x111df}, {0x111e1, 0x111f4}, {0x11200, 0x11211},
- {0x11213, 0x1123e}, {0x11280, 0x11286}, {0x1128a, 0x1128d}, {0x1128f, 0x1129d},
- {0x1129f, 0x112a9}, {0x112b0, 0x112ea}, {0x112f0, 0x112f9}, {0x11300, 0x11303},
- {0x11305, 0x1130c}, {0x11313, 0x11328}, {0x1132a, 0x11330}, {0x11335, 0x11339},
- {0x1133b, 0x11344}, {0x1134b, 0x1134d}, {0x1135d, 0x11363}, {0x11366, 0x1136c},
- {0x11370, 0x11374}, {0x11400, 0x11459}, {0x11480, 0x114c7}, {0x114d0, 0x114d9},
- {0x11580, 0x115b5}, {0x115b8, 0x115dd}, {0x11600, 0x11644}, {0x11650, 0x11659},
- {0x11660, 0x1166c}, {0x11680, 0x116b7}, {0x116c0, 0x116c9}, {0x11700, 0x1171a},
- {0x1171d, 0x1172b}, {0x11730, 0x1173f}, {0x11800, 0x1183b}, {0x118a0, 0x118f2},
- {0x11a00, 0x11a47}, {0x11a50, 0x11a83}, {0x11a86, 0x11aa2}, {0x11ac0, 0x11af8},
+ {0x10e60, 0x10e7e}, {0x10f00, 0x10f27}, {0x10f30, 0x10f59}, {0x10fe0, 0x10ff6},
+ {0x11000, 0x1104d}, {0x11052, 0x1106f}, {0x1107f, 0x110bc}, {0x110be, 0x110c1},
+ {0x110d0, 0x110e8}, {0x110f0, 0x110f9}, {0x11100, 0x11134}, {0x11136, 0x11146},
+ {0x11150, 0x11176}, {0x11180, 0x111cd}, {0x111d0, 0x111df}, {0x111e1, 0x111f4},
+ {0x11200, 0x11211}, {0x11213, 0x1123e}, {0x11280, 0x11286}, {0x1128a, 0x1128d},
+ {0x1128f, 0x1129d}, {0x1129f, 0x112a9}, {0x112b0, 0x112ea}, {0x112f0, 0x112f9},
+ {0x11300, 0x11303}, {0x11305, 0x1130c}, {0x11313, 0x11328}, {0x1132a, 0x11330},
+ {0x11335, 0x11339}, {0x1133b, 0x11344}, {0x1134b, 0x1134d}, {0x1135d, 0x11363},
+ {0x11366, 0x1136c}, {0x11370, 0x11374}, {0x11400, 0x11459}, {0x1145d, 0x1145f},
+ {0x11480, 0x114c7}, {0x114d0, 0x114d9}, {0x11580, 0x115b5}, {0x115b8, 0x115dd},
+ {0x11600, 0x11644}, {0x11650, 0x11659}, {0x11660, 0x1166c}, {0x11680, 0x116b8},
+ {0x116c0, 0x116c9}, {0x11700, 0x1171a}, {0x1171d, 0x1172b}, {0x11730, 0x1173f},
+ {0x11800, 0x1183b}, {0x118a0, 0x118f2}, {0x119a0, 0x119a7}, {0x119aa, 0x119d7},
+ {0x119da, 0x119e4}, {0x11a00, 0x11a47}, {0x11a50, 0x11aa2}, {0x11ac0, 0x11af8},
{0x11c00, 0x11c08}, {0x11c0a, 0x11c36}, {0x11c38, 0x11c45}, {0x11c50, 0x11c6c},
{0x11c70, 0x11c8f}, {0x11c92, 0x11ca7}, {0x11ca9, 0x11cb6}, {0x11d00, 0x11d06},
{0x11d0b, 0x11d36}, {0x11d3f, 0x11d47}, {0x11d50, 0x11d59}, {0x11d60, 0x11d65},
{0x11d6a, 0x11d8e}, {0x11d93, 0x11d98}, {0x11da0, 0x11da9}, {0x11ee0, 0x11ef8},
- {0x12000, 0x12399}, {0x12400, 0x1246e}, {0x12470, 0x12474}, {0x12480, 0x12543},
- {0x13000, 0x1342e}, {0x14400, 0x14646}, {0x16800, 0x16a38}, {0x16a40, 0x16a5e},
- {0x16a60, 0x16a69}, {0x16ad0, 0x16aed}, {0x16af0, 0x16af5}, {0x16b00, 0x16b45},
- {0x16b50, 0x16b59}, {0x16b5b, 0x16b61}, {0x16b63, 0x16b77}, {0x16b7d, 0x16b8f},
- {0x16e40, 0x16e9a}, {0x16f00, 0x16f44}, {0x16f50, 0x16f7e}, {0x16f8f, 0x16f9f},
- {0x17000, 0x187f1}, {0x18800, 0x18af2}, {0x1b000, 0x1b11e}, {0x1b170, 0x1b2fb},
+ {0x11fc0, 0x11ff1}, {0x11fff, 0x12399}, {0x12400, 0x1246e}, {0x12470, 0x12474},
+ {0x12480, 0x12543}, {0x13000, 0x1342e}, {0x14400, 0x14646}, {0x16800, 0x16a38},
+ {0x16a40, 0x16a5e}, {0x16a60, 0x16a69}, {0x16ad0, 0x16aed}, {0x16af0, 0x16af5},
+ {0x16b00, 0x16b45}, {0x16b50, 0x16b59}, {0x16b5b, 0x16b61}, {0x16b63, 0x16b77},
+ {0x16b7d, 0x16b8f}, {0x16e40, 0x16e9a}, {0x16f00, 0x16f4a}, {0x16f4f, 0x16f87},
+ {0x16f8f, 0x16f9f}, {0x16fe0, 0x16fe3}, {0x17000, 0x187f7}, {0x18800, 0x18af2},
+ {0x1b000, 0x1b11e}, {0x1b150, 0x1b152}, {0x1b164, 0x1b167}, {0x1b170, 0x1b2fb},
{0x1bc00, 0x1bc6a}, {0x1bc70, 0x1bc7c}, {0x1bc80, 0x1bc88}, {0x1bc90, 0x1bc99},
{0x1bc9c, 0x1bc9f}, {0x1d000, 0x1d0f5}, {0x1d100, 0x1d126}, {0x1d129, 0x1d172},
{0x1d17b, 0x1d1e8}, {0x1d200, 0x1d245}, {0x1d2e0, 0x1d2f3}, {0x1d300, 0x1d356},
@@ -742,22 +746,24 @@ static const crange graphRangeTable[] = {
{0x1d50d, 0x1d514}, {0x1d516, 0x1d51c}, {0x1d51e, 0x1d539}, {0x1d53b, 0x1d53e},
{0x1d540, 0x1d544}, {0x1d54a, 0x1d550}, {0x1d552, 0x1d6a5}, {0x1d6a8, 0x1d7cb},
{0x1d7ce, 0x1da8b}, {0x1da9b, 0x1da9f}, {0x1daa1, 0x1daaf}, {0x1e000, 0x1e006},
- {0x1e008, 0x1e018}, {0x1e01b, 0x1e021}, {0x1e026, 0x1e02a}, {0x1e800, 0x1e8c4},
- {0x1e8c7, 0x1e8d6}, {0x1e900, 0x1e94a}, {0x1e950, 0x1e959}, {0x1ec71, 0x1ecb4},
- {0x1ee00, 0x1ee03}, {0x1ee05, 0x1ee1f}, {0x1ee29, 0x1ee32}, {0x1ee34, 0x1ee37},
- {0x1ee4d, 0x1ee4f}, {0x1ee67, 0x1ee6a}, {0x1ee6c, 0x1ee72}, {0x1ee74, 0x1ee77},
- {0x1ee79, 0x1ee7c}, {0x1ee80, 0x1ee89}, {0x1ee8b, 0x1ee9b}, {0x1eea1, 0x1eea3},
- {0x1eea5, 0x1eea9}, {0x1eeab, 0x1eebb}, {0x1f000, 0x1f02b}, {0x1f030, 0x1f093},
- {0x1f0a0, 0x1f0ae}, {0x1f0b1, 0x1f0bf}, {0x1f0c1, 0x1f0cf}, {0x1f0d1, 0x1f0f5},
- {0x1f100, 0x1f10c}, {0x1f110, 0x1f16b}, {0x1f170, 0x1f1ac}, {0x1f1e6, 0x1f202},
- {0x1f210, 0x1f23b}, {0x1f240, 0x1f248}, {0x1f260, 0x1f265}, {0x1f300, 0x1f6d4},
- {0x1f6e0, 0x1f6ec}, {0x1f6f0, 0x1f6f9}, {0x1f700, 0x1f773}, {0x1f780, 0x1f7d8},
- {0x1f800, 0x1f80b}, {0x1f810, 0x1f847}, {0x1f850, 0x1f859}, {0x1f860, 0x1f887},
- {0x1f890, 0x1f8ad}, {0x1f900, 0x1f90b}, {0x1f910, 0x1f93e}, {0x1f940, 0x1f970},
- {0x1f973, 0x1f976}, {0x1f97c, 0x1f9a2}, {0x1f9b0, 0x1f9b9}, {0x1f9c0, 0x1f9c2},
- {0x1f9d0, 0x1f9ff}, {0x1fa60, 0x1fa6d}, {0x20000, 0x2a6d6}, {0x2a700, 0x2b734},
- {0x2b740, 0x2b81d}, {0x2b820, 0x2cea1}, {0x2ceb0, 0x2ebe0}, {0x2f800, 0x2fa1d},
- {0xe0100, 0xe01ef}
+ {0x1e008, 0x1e018}, {0x1e01b, 0x1e021}, {0x1e026, 0x1e02a}, {0x1e100, 0x1e12c},
+ {0x1e130, 0x1e13d}, {0x1e140, 0x1e149}, {0x1e2c0, 0x1e2f9}, {0x1e800, 0x1e8c4},
+ {0x1e8c7, 0x1e8d6}, {0x1e900, 0x1e94b}, {0x1e950, 0x1e959}, {0x1ec71, 0x1ecb4},
+ {0x1ed01, 0x1ed3d}, {0x1ee00, 0x1ee03}, {0x1ee05, 0x1ee1f}, {0x1ee29, 0x1ee32},
+ {0x1ee34, 0x1ee37}, {0x1ee4d, 0x1ee4f}, {0x1ee67, 0x1ee6a}, {0x1ee6c, 0x1ee72},
+ {0x1ee74, 0x1ee77}, {0x1ee79, 0x1ee7c}, {0x1ee80, 0x1ee89}, {0x1ee8b, 0x1ee9b},
+ {0x1eea1, 0x1eea3}, {0x1eea5, 0x1eea9}, {0x1eeab, 0x1eebb}, {0x1f000, 0x1f02b},
+ {0x1f030, 0x1f093}, {0x1f0a0, 0x1f0ae}, {0x1f0b1, 0x1f0bf}, {0x1f0c1, 0x1f0cf},
+ {0x1f0d1, 0x1f0f5}, {0x1f100, 0x1f10c}, {0x1f110, 0x1f16c}, {0x1f170, 0x1f1ac},
+ {0x1f1e6, 0x1f202}, {0x1f210, 0x1f23b}, {0x1f240, 0x1f248}, {0x1f260, 0x1f265},
+ {0x1f300, 0x1f6d5}, {0x1f6e0, 0x1f6ec}, {0x1f6f0, 0x1f6fa}, {0x1f700, 0x1f773},
+ {0x1f780, 0x1f7d8}, {0x1f7e0, 0x1f7eb}, {0x1f800, 0x1f80b}, {0x1f810, 0x1f847},
+ {0x1f850, 0x1f859}, {0x1f860, 0x1f887}, {0x1f890, 0x1f8ad}, {0x1f900, 0x1f90b},
+ {0x1f90d, 0x1f971}, {0x1f973, 0x1f976}, {0x1f97a, 0x1f9a2}, {0x1f9a5, 0x1f9aa},
+ {0x1f9ae, 0x1f9ca}, {0x1f9cd, 0x1fa53}, {0x1fa60, 0x1fa6d}, {0x1fa70, 0x1fa73},
+ {0x1fa78, 0x1fa7a}, {0x1fa80, 0x1fa82}, {0x1fa90, 0x1fa95}, {0x20000, 0x2a6d6},
+ {0x2a700, 0x2b734}, {0x2b740, 0x2b81d}, {0x2b820, 0x2cea1}, {0x2ceb0, 0x2ebe0},
+ {0x2f800, 0x2fa1d}, {0xe0100, 0xe01ef}
#endif
};
@@ -770,21 +776,20 @@ static const chr graphCharTable[] = {
0xb10, 0xb32, 0xb33, 0xb47, 0xb48, 0xb56, 0xb57, 0xb5c, 0xb5d,
0xb82, 0xb83, 0xb99, 0xb9a, 0xb9c, 0xb9e, 0xb9f, 0xba3, 0xba4,
0xbd0, 0xbd7, 0xc55, 0xc56, 0xcd5, 0xcd6, 0xcde, 0xcf1, 0xcf2,
- 0xd82, 0xd83, 0xdbd, 0xdca, 0xdd6, 0xe81, 0xe82, 0xe84, 0xe87,
- 0xe88, 0xe8a, 0xe8d, 0xea5, 0xea7, 0xeaa, 0xeab, 0xec6, 0x10c7,
- 0x10cd, 0x1258, 0x12c0, 0x1772, 0x1773, 0x1940, 0x1f59, 0x1f5b, 0x1f5d,
- 0x2070, 0x2071, 0x2d27, 0x2d2d, 0x2d6f, 0x2d70, 0xfb3e, 0xfb40, 0xfb41,
- 0xfb43, 0xfb44, 0xfffc, 0xfffd
+ 0xd82, 0xd83, 0xdbd, 0xdca, 0xdd6, 0xe81, 0xe82, 0xe84, 0xea5,
+ 0xec6, 0x10c7, 0x10cd, 0x1258, 0x12c0, 0x1772, 0x1773, 0x1940, 0x1f59,
+ 0x1f5b, 0x1f5d, 0x2070, 0x2071, 0x2d27, 0x2d2d, 0x2d6f, 0x2d70, 0xfb3e,
+ 0xfb40, 0xfb41, 0xfb43, 0xfb44, 0xfffc, 0xfffd
#if CHRBITS > 16
,0x1003c, 0x1003d, 0x101a0, 0x1056f, 0x10808, 0x10837, 0x10838, 0x1083c, 0x108f4,
0x108f5, 0x1093f, 0x10a05, 0x10a06, 0x11288, 0x1130f, 0x11310, 0x11332, 0x11333,
- 0x11347, 0x11348, 0x11350, 0x11357, 0x1145b, 0x1145d, 0x1145e, 0x118ff, 0x11d08,
- 0x11d09, 0x11d3a, 0x11d3c, 0x11d3d, 0x11d67, 0x11d68, 0x11d90, 0x11d91, 0x16a6e,
- 0x16a6f, 0x16fe0, 0x16fe1, 0x1d49e, 0x1d49f, 0x1d4a2, 0x1d4a5, 0x1d4a6, 0x1d4bb,
- 0x1d546, 0x1e023, 0x1e024, 0x1e95e, 0x1e95f, 0x1ee21, 0x1ee22, 0x1ee24, 0x1ee27,
- 0x1ee39, 0x1ee3b, 0x1ee42, 0x1ee47, 0x1ee49, 0x1ee4b, 0x1ee51, 0x1ee52, 0x1ee54,
- 0x1ee57, 0x1ee59, 0x1ee5b, 0x1ee5d, 0x1ee5f, 0x1ee61, 0x1ee62, 0x1ee64, 0x1ee7e,
- 0x1eef0, 0x1eef1, 0x1f250, 0x1f251, 0x1f97a
+ 0x11347, 0x11348, 0x11350, 0x11357, 0x1145b, 0x118ff, 0x11d08, 0x11d09, 0x11d3a,
+ 0x11d3c, 0x11d3d, 0x11d67, 0x11d68, 0x11d90, 0x11d91, 0x16a6e, 0x16a6f, 0x1d49e,
+ 0x1d49f, 0x1d4a2, 0x1d4a5, 0x1d4a6, 0x1d4bb, 0x1d546, 0x1e023, 0x1e024, 0x1e14e,
+ 0x1e14f, 0x1e2ff, 0x1e95e, 0x1e95f, 0x1ee21, 0x1ee22, 0x1ee24, 0x1ee27, 0x1ee39,
+ 0x1ee3b, 0x1ee42, 0x1ee47, 0x1ee49, 0x1ee4b, 0x1ee51, 0x1ee52, 0x1ee54, 0x1ee57,
+ 0x1ee59, 0x1ee5b, 0x1ee5d, 0x1ee5f, 0x1ee61, 0x1ee62, 0x1ee64, 0x1ee7e, 0x1eef0,
+ 0x1eef1, 0x1f250, 0x1f251
#endif
};
@@ -828,7 +833,7 @@ element(
*/
Tcl_DStringInit(&ds);
- np = Tcl_UniCharToUtfDString(startp, (int)len, &ds);
+ np = Tcl_UniCharToUtfDString(startp, len, &ds);
for (cn=cnames; cn->name!=NULL; cn++) {
if (strlen(cn->name)==len && strncmp(cn->name, np, len)==0) {
break; /* NOTE BREAK OUT */
diff --git a/generic/regcomp.c b/generic/regcomp.c
index 58d55fb..49b024f 100644
--- a/generic/regcomp.c
+++ b/generic/regcomp.c
@@ -206,11 +206,11 @@ struct vars {
int cflags; /* copy of compile flags */
int lasttype; /* type of previous token */
int nexttype; /* type of next token */
- chr nextvalue; /* value (if any) of next token */
+ int nextvalue; /* value (if any) of next token */
int lexcon; /* lexical context type (see lex.c) */
int nsubexp; /* subexpression count */
struct subre **subs; /* subRE pointer vector */
- size_t nsubs; /* length of vector */
+ int nsubs; /* length of vector */
struct subre *sub10[10]; /* initial vector, enough for most */
struct nfa *nfa; /* the NFA */
struct colormap *cm; /* character color map */
@@ -287,8 +287,7 @@ compile(
{
AllocVars(v);
struct guts *g;
- int i;
- size_t j;
+ int i, j;
FILE *debug = (flags&REG_PROGRESS) ? stdout : NULL;
#define CNOERR() { if (ISERR()) return freev(v, v->err); }
@@ -477,10 +476,10 @@ moresubs(
int wanted) /* want enough room for this one */
{
struct subre **p;
- size_t n;
+ int n;
- assert(wanted > 0 && (size_t)wanted >= v->nsubs);
- n = (size_t)wanted * 3 / 2 + 1;
+ assert(wanted > 0 && wanted >= v->nsubs);
+ n = wanted * 3 / 2 + 1;
if (v->subs == v->sub10) {
p = (struct subre **) MALLOC(n * sizeof(struct subre *));
if (p != NULL) {
@@ -499,7 +498,7 @@ moresubs(
*p = NULL;
}
assert(v->nsubs == n);
- assert((size_t)wanted < v->nsubs);
+ assert(wanted < v->nsubs);
}
/*
@@ -954,10 +953,10 @@ parseqatom(
if (cap) {
v->nsubexp++;
subno = v->nsubexp;
- if ((size_t)subno >= v->nsubs) {
+ if (subno >= v->nsubs) {
moresubs(v, subno);
}
- assert((size_t)subno < v->nsubs);
+ assert(subno < v->nsubs);
} else {
atomtype = PLAIN; /* something that's not '(' */
}
diff --git a/generic/regexec.c b/generic/regexec.c
index 128d439..c57f42c 100644
--- a/generic/regexec.c
+++ b/generic/regexec.c
@@ -172,8 +172,8 @@ exec(
{
AllocVars(v);
int st, backref;
- size_t n;
- size_t i;
+ int n;
+ int i;
#define LOCALMAT 20
regmatch_t mat[LOCALMAT];
#define LOCALDFAS 40
@@ -236,7 +236,7 @@ exec(
v->stop = (chr *)string + len;
v->err = 0;
assert(v->g->ntree >= 0);
- n = (size_t) v->g->ntree;
+ n = v->g->ntree;
if (n <= LOCALDFAS)
v->subdfas = subdfas;
else
@@ -278,7 +278,7 @@ exec(
if (v->pmatch != pmatch && v->pmatch != mat) {
FREE(v->pmatch);
}
- n = (size_t) v->g->ntree;
+ n = v->g->ntree;
for (i = 0; i < n; i++) {
if (v->subdfas[i] != NULL)
freeDFA(v->subdfas[i]);
diff --git a/generic/tcl.decls b/generic/tcl.decls
index 5b3afeb..d404d25 100644
--- a/generic/tcl.decls
+++ b/generic/tcl.decls
@@ -864,7 +864,7 @@ declare 244 {nostub {Don't use this function in a stub-enabled extension}} {
void Tcl_StaticPackage(Tcl_Interp *interp, const char *pkgName,
Tcl_PackageInitProc *initProc, Tcl_PackageInitProc *safeInitProc)
}
-declare 245 {
+declare 245 {deprecated {No longer in use, changed to macro}} {
int Tcl_StringMatch(const char *str, const char *pattern)
}
declare 246 {deprecated {}} {
diff --git a/generic/tclAlloc.c b/generic/tclAlloc.c
index df1718b..bad3d8a 100644
--- a/generic/tclAlloc.c
+++ b/generic/tclAlloc.c
@@ -274,8 +274,8 @@ TclpAlloc(
if (numBytes >= MAXMALLOC - OVERHEAD) {
if (numBytes <= UINT_MAX - OVERHEAD -sizeof(struct block)) {
- bigBlockPtr = (struct block *) TclpSysAlloc((unsigned)
- (sizeof(struct block) + OVERHEAD + numBytes), 0);
+ bigBlockPtr = (struct block *) TclpSysAlloc(
+ sizeof(struct block) + OVERHEAD + numBytes, 0);
}
if (bigBlockPtr == NULL) {
Tcl_MutexUnlock(allocMutexPtr);
@@ -604,7 +604,7 @@ TclpRealloc(
if (maxSize < numBytes) {
numBytes = maxSize;
}
- memcpy(newPtr, oldPtr, (size_t) numBytes);
+ memcpy(newPtr, oldPtr, numBytes);
TclpFree(oldPtr);
return newPtr;
}
diff --git a/generic/tclBasic.c b/generic/tclBasic.c
index 44acac8..1806557 100644
--- a/generic/tclBasic.c
+++ b/generic/tclBasic.c
@@ -319,6 +319,7 @@ static const CmdInfo builtInCmds[] = {
{"source", Tcl_SourceObjCmd, NULL, TclNRSourceObjCmd, 0},
{"tell", Tcl_TellObjCmd, NULL, NULL, CMD_IS_SAFE},
{"time", Tcl_TimeObjCmd, NULL, NULL, CMD_IS_SAFE},
+ {"timerate", Tcl_TimeRateObjCmd, NULL, NULL, CMD_IS_SAFE},
{"unload", Tcl_UnloadObjCmd, NULL, NULL, 0},
{"update", Tcl_UpdateObjCmd, NULL, NULL, CMD_IS_SAFE},
{"vwait", Tcl_VwaitObjCmd, NULL, NULL, CMD_IS_SAFE},
@@ -559,7 +560,7 @@ Tcl_CreateInterp(void)
const BuiltinFuncDef *builtinFuncPtr;
const OpCmdInfo *opcmdInfoPtr;
const CmdInfo *cmdInfoPtr;
- Tcl_Namespace *mathfuncNSPtr, *mathopNSPtr;
+ Tcl_Namespace *nsPtr;
Tcl_HashEntry *hPtr;
int isNew;
CancelInfo *cancelInfo;
@@ -974,6 +975,13 @@ Tcl_CreateInterp(void)
Tcl_NRCreateCommand(interp, "::tcl::unsupported::inject", NULL,
NRCoroInjectObjCmd, NULL, NULL);
+ /* Export unsupported commands */
+ nsPtr = Tcl_FindNamespace(interp, "::tcl::unsupported", NULL, 0);
+ if (nsPtr) {
+ Tcl_Export(interp, nsPtr, "*", 1);
+ }
+
+
#ifdef USE_DTRACE
/*
* Register the tcl::dtrace command.
@@ -986,8 +994,8 @@ Tcl_CreateInterp(void)
* Register the builtin math functions.
*/
- mathfuncNSPtr = Tcl_CreateNamespace(interp, "::tcl::mathfunc", NULL,NULL);
- if (mathfuncNSPtr == NULL) {
+ nsPtr = Tcl_CreateNamespace(interp, "::tcl::mathfunc", NULL,NULL);
+ if (nsPtr == NULL) {
Tcl_Panic("Can't create math function namespace");
}
#define MATH_FUNC_PREFIX_LEN 17 /* == strlen("::tcl::mathfunc::") */
@@ -997,18 +1005,18 @@ Tcl_CreateInterp(void)
strcpy(mathFuncName+MATH_FUNC_PREFIX_LEN, builtinFuncPtr->name);
Tcl_CreateObjCommand(interp, mathFuncName,
builtinFuncPtr->objCmdProc, builtinFuncPtr->clientData, NULL);
- Tcl_Export(interp, mathfuncNSPtr, builtinFuncPtr->name, 0);
+ Tcl_Export(interp, nsPtr, builtinFuncPtr->name, 0);
}
/*
* Register the mathematical "operator" commands. [TIP #174]
*/
- mathopNSPtr = Tcl_CreateNamespace(interp, "::tcl::mathop", NULL, NULL);
- if (mathopNSPtr == NULL) {
+ nsPtr = Tcl_CreateNamespace(interp, "::tcl::mathop", NULL, NULL);
+ if (nsPtr == NULL) {
Tcl_Panic("can't create math operator namespace");
}
- Tcl_Export(interp, mathopNSPtr, "*", 1);
+ Tcl_Export(interp, nsPtr, "*", 1);
#define MATH_OP_PREFIX_LEN 15 /* == strlen("::tcl::mathop::") */
memcpy(mathFuncName, "::tcl::mathop::", MATH_OP_PREFIX_LEN);
for (opcmdInfoPtr=mathOpCmds ; opcmdInfoPtr->name!=NULL ; opcmdInfoPtr++){
@@ -4408,7 +4416,7 @@ Tcl_CancelEval(
if (resultObjPtr != NULL) {
result = TclGetStringFromObj(resultObjPtr, &cancelInfo->length);
cancelInfo->result = ckrealloc(cancelInfo->result,cancelInfo->length);
- memcpy(cancelInfo->result, result, (size_t) cancelInfo->length);
+ memcpy(cancelInfo->result, result, cancelInfo->length);
TclDecrRefCount(resultObjPtr); /* Discard their result object. */
} else {
cancelInfo->result = NULL;
@@ -7552,7 +7560,7 @@ ExprIsqrtFunc(
if (Tcl_GetBignumFromObj(interp, objv[1], &big) != TCL_OK) {
return TCL_ERROR;
}
- if (SIGN(&big) == MP_NEG) {
+ if (big.sign != MP_ZPOS) {
mp_clear(&big);
goto negarg;
}
@@ -7781,9 +7789,9 @@ ExprAbsFunc(
if (type == TCL_NUMBER_INT) {
Tcl_WideInt l = *((const Tcl_WideInt *) ptr);
- if (l > (Tcl_WideInt)0) {
+ if (l > 0) {
goto unChanged;
- } else if (l == (Tcl_WideInt)0) {
+ } else if (l == 0) {
if (TclHasStringRep(objv[1])) {
int numBytes;
const char *bytes = TclGetStringFromObj(objv[1], &numBytes);
@@ -7826,7 +7834,7 @@ ExprAbsFunc(
}
if (type == TCL_NUMBER_BIG) {
- if (mp_isneg((const mp_int *) ptr)) {
+ if (((const mp_int *) ptr)->sign != MP_ZPOS) {
Tcl_GetBignumFromObj(NULL, objv[1], &big);
tooLarge:
mp_neg(&big, &big);
@@ -7889,7 +7897,7 @@ ExprDoubleFunc(
}
if (Tcl_GetDoubleFromObj(interp, objv[1], &dResult) != TCL_OK) {
#ifdef ACCEPT_NAN
- if (objv[1]->typePtr == &tclDoubleType) {
+ if (TclHasIntRep(objv[1], &tclDoubleType)) {
Tcl_SetObjResult(interp, objv[1]);
return TCL_OK;
}
diff --git a/generic/tclBinary.c b/generic/tclBinary.c
index e912c1f..1f78d18 100644
--- a/generic/tclBinary.c
+++ b/generic/tclBinary.c
@@ -57,9 +57,12 @@
static void DupByteArrayInternalRep(Tcl_Obj *srcPtr,
Tcl_Obj *copyPtr);
+static void DupProperByteArrayInternalRep(Tcl_Obj *srcPtr,
+ Tcl_Obj *copyPtr);
static int FormatNumber(Tcl_Interp *interp, int type,
Tcl_Obj *src, unsigned char **cursorPtr);
static void FreeByteArrayInternalRep(Tcl_Obj *objPtr);
+static void FreeProperByteArrayInternalRep(Tcl_Obj *objPtr);
static int GetFormatSpec(const char **formatPtr, char *cmdPtr,
int *countPtr, int *flagsPtr);
static Tcl_Obj * ScanNumber(unsigned char *buffer, int type,
@@ -245,10 +248,10 @@ static const EnsembleImplMap decodeMap[] = {
* over which bytearray values can be useful in the meanwhile.
*/
-const Tcl_ObjType tclPureByteArrayType = {
+static const Tcl_ObjType properByteArrayType = {
"bytearray",
- FreeByteArrayInternalRep,
- DupByteArrayInternalRep,
+ FreeProperByteArrayInternalRep,
+ DupProperByteArrayInternalRep,
UpdateStringOfByteArray,
NULL
};
@@ -284,6 +287,13 @@ typedef struct ByteArray {
#define SET_BYTEARRAY(irPtr, baPtr) \
(irPtr)->twoPtrValue.ptr1 = (void *) (baPtr)
+int
+TclIsPureByteArray(
+ Tcl_Obj * objPtr)
+{
+ return TclHasIntRep(objPtr, &properByteArrayType);
+}
+
/*
*----------------------------------------------------------------------
*
@@ -411,11 +421,11 @@ Tcl_SetByteArrayObj(
byteArrayPtr->allocated = length;
if ((bytes != NULL) && (length > 0)) {
- memcpy(byteArrayPtr->bytes, bytes, (size_t) length);
+ memcpy(byteArrayPtr->bytes, bytes, length);
}
SET_BYTEARRAY(&ir, byteArrayPtr);
- Tcl_StoreIntRep(objPtr, &tclPureByteArrayType, &ir);
+ Tcl_StoreIntRep(objPtr, &properByteArrayType, &ir);
}
/*
@@ -443,13 +453,13 @@ Tcl_GetByteArrayFromObj(
* array of bytes in the ByteArray object. */
{
ByteArray *baPtr;
- const Tcl_ObjIntRep *irPtr = TclFetchIntRep(objPtr, &tclPureByteArrayType);
+ const Tcl_ObjIntRep *irPtr = TclFetchIntRep(objPtr, &properByteArrayType);
if (irPtr == NULL) {
irPtr = TclFetchIntRep(objPtr, &tclByteArrayType);
if (irPtr == NULL) {
SetByteArrayFromAny(NULL, objPtr);
- irPtr = TclFetchIntRep(objPtr, &tclPureByteArrayType);
+ irPtr = TclFetchIntRep(objPtr, &properByteArrayType);
if (irPtr == NULL) {
irPtr = TclFetchIntRep(objPtr, &tclByteArrayType);
}
@@ -501,12 +511,12 @@ Tcl_SetByteArrayLength(
Tcl_Panic("%s called with shared object", "Tcl_SetByteArrayLength");
}
- irPtr = TclFetchIntRep(objPtr, &tclPureByteArrayType);
+ irPtr = TclFetchIntRep(objPtr, &properByteArrayType);
if (irPtr == NULL) {
irPtr = TclFetchIntRep(objPtr, &tclByteArrayType);
if (irPtr == NULL) {
SetByteArrayFromAny(NULL, objPtr);
- irPtr = TclFetchIntRep(objPtr, &tclPureByteArrayType);
+ irPtr = TclFetchIntRep(objPtr, &properByteArrayType);
if (irPtr == NULL) {
irPtr = TclFetchIntRep(objPtr, &tclByteArrayType);
}
@@ -553,10 +563,10 @@ SetByteArrayFromAny(
ByteArray *byteArrayPtr;
Tcl_ObjIntRep ir;
- if (objPtr->typePtr == &tclPureByteArrayType) {
+ if (TclHasIntRep(objPtr, &properByteArrayType)) {
return TCL_OK;
}
- if (objPtr->typePtr == &tclByteArrayType) {
+ if (TclHasIntRep(objPtr, &tclByteArrayType)) {
return TCL_OK;
}
@@ -576,7 +586,7 @@ SetByteArrayFromAny(
SET_BYTEARRAY(&ir, byteArrayPtr);
Tcl_StoreIntRep(objPtr,
- improper ? &tclByteArrayType : &tclPureByteArrayType, &ir);
+ improper ? &tclByteArrayType : &properByteArrayType, &ir);
return TCL_OK;
}
@@ -601,7 +611,14 @@ static void
FreeByteArrayInternalRep(
Tcl_Obj *objPtr) /* Object with internal rep to free. */
{
- ckfree(GET_BYTEARRAY(&(objPtr->internalRep)));
+ ckfree(GET_BYTEARRAY(TclFetchIntRep(objPtr, &tclByteArrayType)));
+}
+
+static void
+FreeProperByteArrayInternalRep(
+ Tcl_Obj *objPtr) /* Object with internal rep to free. */
+{
+ ckfree(GET_BYTEARRAY(TclFetchIntRep(objPtr, &properByteArrayType)));
}
/*
@@ -630,7 +647,28 @@ DupByteArrayInternalRep(
ByteArray *srcArrayPtr, *copyArrayPtr;
Tcl_ObjIntRep ir;
- srcArrayPtr = GET_BYTEARRAY(&(srcPtr->internalRep));
+ srcArrayPtr = GET_BYTEARRAY(TclFetchIntRep(srcPtr, &tclByteArrayType));
+ length = srcArrayPtr->used;
+
+ copyArrayPtr = ckalloc(BYTEARRAY_SIZE(length));
+ copyArrayPtr->used = length;
+ copyArrayPtr->allocated = length;
+ memcpy(copyArrayPtr->bytes, srcArrayPtr->bytes, length);
+
+ SET_BYTEARRAY(&ir, copyArrayPtr);
+ Tcl_StoreIntRep(copyPtr, &tclByteArrayType, &ir);
+}
+
+static void
+DupProperByteArrayInternalRep(
+ Tcl_Obj *srcPtr, /* Object with internal rep to copy. */
+ Tcl_Obj *copyPtr) /* Object with internal rep to set. */
+{
+ unsigned int length;
+ ByteArray *srcArrayPtr, *copyArrayPtr;
+ Tcl_ObjIntRep ir;
+
+ srcArrayPtr = GET_BYTEARRAY(TclFetchIntRep(srcPtr, &properByteArrayType));
length = srcArrayPtr->used;
copyArrayPtr = ckalloc(BYTEARRAY_SIZE(length));
@@ -639,7 +677,7 @@ DupByteArrayInternalRep(
memcpy(copyArrayPtr->bytes, srcArrayPtr->bytes, length);
SET_BYTEARRAY(&ir, copyArrayPtr);
- Tcl_StoreIntRep(copyPtr, srcPtr->typePtr, &ir);
+ Tcl_StoreIntRep(copyPtr, &properByteArrayType, &ir);
}
/*
@@ -664,7 +702,7 @@ UpdateStringOfByteArray(
Tcl_Obj *objPtr) /* ByteArray object whose string rep to
* update. */
{
- const Tcl_ObjIntRep *irPtr = TclFetchIntRep(objPtr, &tclPureByteArrayType);
+ const Tcl_ObjIntRep *irPtr = TclFetchIntRep(objPtr, &properByteArrayType);
ByteArray *byteArrayPtr = GET_BYTEARRAY(irPtr);
unsigned char *src = byteArrayPtr->bytes;
unsigned int i, length = byteArrayPtr->used;
@@ -739,12 +777,12 @@ TclAppendBytesToByteArray(
length = (unsigned int)len;
- irPtr = TclFetchIntRep(objPtr, &tclPureByteArrayType);
+ irPtr = TclFetchIntRep(objPtr, &properByteArrayType);
if (irPtr == NULL) {
irPtr = TclFetchIntRep(objPtr, &tclByteArrayType);
if (irPtr == NULL) {
SetByteArrayFromAny(NULL, objPtr);
- irPtr = TclFetchIntRep(objPtr, &tclPureByteArrayType);
+ irPtr = TclFetchIntRep(objPtr, &properByteArrayType);
if (irPtr == NULL) {
irPtr = TclFetchIntRep(objPtr, &tclByteArrayType);
}
@@ -1038,7 +1076,7 @@ BinaryFormatCmd(
resultPtr = Tcl_NewObj();
buffer = Tcl_SetByteArrayLength(resultPtr, length);
- memset(buffer, 0, (size_t) length);
+ memset(buffer, 0, length);
/*
* Pack the data into the result object. Note that we can skip the
@@ -1075,10 +1113,10 @@ BinaryFormatCmd(
count = 1;
}
if (length >= count) {
- memcpy(cursor, bytes, (size_t) count);
+ memcpy(cursor, bytes, count);
} else {
- memcpy(cursor, bytes, (size_t) length);
- memset(cursor + length, pad, (size_t) (count - length));
+ memcpy(cursor, bytes, length);
+ memset(cursor + length, pad, count - length);
}
cursor += count;
break;
@@ -1267,7 +1305,7 @@ BinaryFormatCmd(
if (count == BINARY_NOCOUNT) {
count = 1;
}
- memset(cursor, 0, (size_t) count);
+ memset(cursor, 0, count);
cursor += count;
break;
case 'X':
@@ -1316,7 +1354,7 @@ BinaryFormatCmd(
badField:
{
Tcl_UniChar ch = 0;
- char buf[TCL_UTF_MAX + 1];
+ char buf[TCL_UTF_MAX + 1] = "";
TclUtfToUniChar(errorString, &ch);
buf[Tcl_UniCharToUtf(ch, buf)] = '\0';
@@ -1686,7 +1724,7 @@ BinaryScanCmd(
badField:
{
Tcl_UniChar ch = 0;
- char buf[TCL_UTF_MAX + 1];
+ char buf[TCL_UTF_MAX + 1] = "";
TclUtfToUniChar(errorString, &ch);
buf[Tcl_UniCharToUtf(ch, buf)] = '\0';
diff --git a/generic/tclCkalloc.c b/generic/tclCkalloc.c
index e3fb98e..94327b5 100644
--- a/generic/tclCkalloc.c
+++ b/generic/tclCkalloc.c
@@ -405,7 +405,7 @@ Tcl_DbCkalloc(
/* Don't let size argument to TclpAlloc overflow */
if (size <= UINT_MAX - HIGH_GUARD_SIZE -sizeof(struct mem_header)) {
- result = (struct mem_header *) TclpAlloc((unsigned)size +
+ result = (struct mem_header *) TclpAlloc(size +
sizeof(struct mem_header) + HIGH_GUARD_SIZE);
}
if (result == NULL) {
@@ -495,7 +495,7 @@ Tcl_AttemptDbCkalloc(
/* Don't let size argument to TclpAlloc overflow */
if (size <= UINT_MAX - HIGH_GUARD_SIZE - sizeof(struct mem_header)) {
- result = (struct mem_header *) TclpAlloc((unsigned)size +
+ result = (struct mem_header *) TclpAlloc(size +
sizeof(struct mem_header) + HIGH_GUARD_SIZE);
}
if (result == NULL) {
@@ -691,7 +691,7 @@ Tcl_DbCkrealloc(
copySize = memp->length;
}
newPtr = Tcl_DbCkalloc(size, file, line);
- memcpy(newPtr, ptr, (size_t) copySize);
+ memcpy(newPtr, ptr, copySize);
Tcl_DbCkfree(ptr, file, line);
return newPtr;
}
@@ -725,7 +725,7 @@ Tcl_AttemptDbCkrealloc(
if (newPtr == NULL) {
return NULL;
}
- memcpy(newPtr, ptr, (size_t) copySize);
+ memcpy(newPtr, ptr, copySize);
Tcl_DbCkfree(ptr, file, line);
return newPtr;
}
diff --git a/generic/tclClock.c b/generic/tclClock.c
index 2c25f6c..aeff164 100644
--- a/generic/tclClock.c
+++ b/generic/tclClock.c
@@ -452,7 +452,7 @@ ClockGetdatefieldsObjCmd(
* that it isn't.
*/
- if (objv[1]->typePtr == &tclBignumType) {
+ if (TclHasIntRep(objv[1], &tclBignumType)) {
Tcl_SetObjResult(interp, literals[LIT_INTEGER_VALUE_TOO_LARGE]);
return TCL_ERROR;
}
@@ -1772,8 +1772,7 @@ ClockClicksObjCmd(
#endif
break;
case CLICKS_MICROS:
- Tcl_GetTime(&now);
- clicks = ((Tcl_WideInt) now.sec * 1000000) + now.usec;
+ clicks = TclpGetMicroseconds();
break;
}
@@ -1843,15 +1842,11 @@ ClockMicrosecondsObjCmd(
int objc, /* Parameter count */
Tcl_Obj *const *objv) /* Parameter values */
{
- Tcl_Time now;
-
if (objc != 1) {
Tcl_WrongNumArgs(interp, 1, objv, NULL);
return TCL_ERROR;
}
- Tcl_GetTime(&now);
- Tcl_SetObjResult(interp, Tcl_NewWideIntObj(
- ((Tcl_WideInt) now.sec * 1000000) + now.usec));
+ Tcl_SetObjResult(interp, Tcl_NewWideIntObj(TclpGetMicroseconds()));
return TCL_OK;
}
diff --git a/generic/tclCmdAH.c b/generic/tclCmdAH.c
index 331f791..1811c5c 100644
--- a/generic/tclCmdAH.c
+++ b/generic/tclCmdAH.c
@@ -932,7 +932,7 @@ Tcl_ExitObjCmd(
int objc, /* Number of arguments. */
Tcl_Obj *const objv[]) /* Argument objects. */
{
- int value;
+ Tcl_WideInt value;
if ((objc != 1) && (objc != 2)) {
Tcl_WrongNumArgs(interp, 1, objv, "?returnCode?");
@@ -941,10 +941,10 @@ Tcl_ExitObjCmd(
if (objc == 1) {
value = 0;
- } else if (Tcl_GetIntFromObj(interp, objv[1], &value) != TCL_OK) {
+ } else if (TclGetWideBitsFromObj(interp, objv[1], &value) != TCL_OK) {
return TCL_ERROR;
}
- Tcl_Exit(value);
+ Tcl_Exit((int)value);
/*NOTREACHED*/
return TCL_OK; /* Better not ever reach this! */
}
diff --git a/generic/tclCmdMZ.c b/generic/tclCmdMZ.c
index e759392..3bf485b 100644
--- a/generic/tclCmdMZ.c
+++ b/generic/tclCmdMZ.c
@@ -17,6 +17,7 @@
*/
#include "tclInt.h"
+#include "tclCompile.h"
#include "tclRegexp.h"
#include "tclStringTrim.h"
@@ -1221,8 +1222,8 @@ Tcl_SplitObjCmd(
fullchar = ch;
#if TCL_UTF_MAX <= 4
- if (!len) {
- len += TclUtfToUniChar(stringPtr, &ch);
+ if ((ch >= 0xD800) && (len < 3)) {
+ len += TclUtfToUniChar(stringPtr + len, &ch);
fullchar = (((fullchar & 0x3ff) << 10) | (ch & 0x3ff)) + 0x10000;
}
#endif
@@ -1444,11 +1445,11 @@ StringIndexCmd(
Tcl_SetObjResult(interp, Tcl_NewByteArrayObj(&uch, 1));
} else {
- char buf[4];
+ char buf[4] = "";
length = Tcl_UniCharToUtf(ch, buf);
- if (!length) {
- length = Tcl_UniCharToUtf(-1, buf);
+ if ((ch >= 0xD800) && (length < 3)) {
+ length += Tcl_UniCharToUtf(-1, buf + length);
}
Tcl_SetObjResult(interp, Tcl_NewStringObj(buf, length));
}
@@ -1628,7 +1629,7 @@ StringIsCmd(
case STR_IS_BOOL:
case STR_IS_TRUE:
case STR_IS_FALSE:
- if ((objPtr->typePtr != &tclBooleanType)
+ if (!TclHasIntRep(objPtr, &tclBooleanType)
&& (TCL_OK != TclSetBooleanFromAny(NULL, objPtr))) {
if (strict) {
result = 0;
@@ -1698,9 +1699,9 @@ StringIsCmd(
chcomp = Tcl_UniCharIsDigit;
break;
case STR_IS_DOUBLE: {
- if ((objPtr->typePtr == &tclDoubleType) ||
- (objPtr->typePtr == &tclIntType) ||
- (objPtr->typePtr == &tclBignumType)) {
+ if (TclHasIntRep(objPtr, &tclDoubleType) ||
+ TclHasIntRep(objPtr, &tclIntType) ||
+ TclHasIntRep(objPtr, &tclBignumType)) {
break;
}
string1 = TclGetStringFromObj(objPtr, &length1);
@@ -1729,8 +1730,8 @@ StringIsCmd(
break;
case STR_IS_INT:
case STR_IS_ENTIER:
- if ((objPtr->typePtr == &tclIntType) ||
- (objPtr->typePtr == &tclBignumType)) {
+ if (TclHasIntRep(objPtr, &tclIntType) ||
+ TclHasIntRep(objPtr, &tclBignumType)) {
break;
}
string1 = TclGetStringFromObj(objPtr, &length1);
@@ -1911,8 +1912,8 @@ StringIsCmd(
length2 = TclUtfToUniChar(string1, &ch);
fullchar = ch;
#if TCL_UTF_MAX <= 4
- if (!length2) {
- length2 = TclUtfToUniChar(string1, &ch);
+ if ((ch >= 0xD800) && (length2 < 3)) {
+ length2 += TclUtfToUniChar(string1 + length2, &ch);
fullchar = (((fullchar & 0x3ff) << 10) | (ch & 0x3ff)) + 0x10000;
}
#endif
@@ -1992,7 +1993,7 @@ StringMapCmd(
const char *string = TclGetStringFromObj(objv[1], &length2);
if ((length2 > 1) &&
- strncmp(string, "-nocase", (size_t) length2) == 0) {
+ strncmp(string, "-nocase", length2) == 0) {
nocase = 1;
} else {
Tcl_SetObjResult(interp, Tcl_ObjPrintf(
@@ -2009,7 +2010,7 @@ StringMapCmd(
*/
if (!TclHasStringRep(objv[objc-2])
- && (objv[objc-2]->typePtr == &tclDictType)){
+ && TclHasIntRep(objv[objc-2], &tclDictType)){
int i, done;
Tcl_DictSearch search;
@@ -2171,7 +2172,7 @@ StringMapCmd(
(Tcl_UniCharToLower(*ustring1) == u2lc[index/2]))) &&
/* Restrict max compare length. */
(end-ustring1 >= length2) && ((length2 == 1) ||
- !strCmpFn(ustring2, ustring1, (unsigned) length2))) {
+ !strCmpFn(ustring2, ustring1, length2))) {
if (p != ustring1) {
/*
* Put the skipped chars onto the result first.
@@ -2260,7 +2261,7 @@ StringMatchCmd(
const char *string = TclGetStringFromObj(objv[1], &length);
if ((length > 1) &&
- strncmp(string, "-nocase", (size_t) length) == 0) {
+ strncmp(string, "-nocase", length) == 0) {
nocase = TCL_MATCH_NOCASE;
} else {
Tcl_SetObjResult(interp, Tcl_ObjPrintf(
@@ -2662,10 +2663,10 @@ StringEqualCmd(
for (i = 1; i < objc-2; i++) {
string2 = TclGetStringFromObj(objv[i], &length);
- if ((length > 1) && !strncmp(string2, "-nocase", (size_t)length)) {
+ if ((length > 1) && !strncmp(string2, "-nocase", length)) {
nocase = 1;
} else if ((length > 1)
- && !strncmp(string2, "-length", (size_t)length)) {
+ && !strncmp(string2, "-length", length)) {
if (i+1 >= objc-2) {
goto str_cmp_args;
}
@@ -2760,10 +2761,10 @@ TclStringCmpOpts(
for (i = 1; i < objc-2; i++) {
string = TclGetStringFromObj(objv[i], &length);
- if ((length > 1) && !strncmp(string, "-nocase", (size_t)length)) {
+ if ((length > 1) && !strncmp(string, "-nocase", length)) {
*nocase = 1;
} else if ((length > 1)
- && !strncmp(string, "-length", (size_t)length)) {
+ && !strncmp(string, "-length", length)) {
if (i+1 >= objc-2) {
goto str_cmp_args;
}
@@ -4088,7 +4089,7 @@ Tcl_TimeObjCmd(
start = TclpGetWideClicks();
#endif
while (i-- > 0) {
- result = Tcl_EvalObjEx(interp, objPtr, 0);
+ result = TclEvalObjEx(interp, objPtr, 0, NULL, 0);
if (result != TCL_OK) {
return result;
}
@@ -4128,6 +4129,399 @@ Tcl_TimeObjCmd(
/*
*----------------------------------------------------------------------
*
+ * Tcl_TimeRateObjCmd --
+ *
+ * This object-based procedure is invoked to process the "timerate" Tcl
+ * command.
+ * This is similar to command "time", except the execution limited by
+ * given time (in milliseconds) instead of repetition count.
+ *
+ * Example:
+ * timerate {after 5} 1000 ; # equivalent for `time {after 5} [expr 1000/5]`
+ *
+ * Results:
+ * A standard Tcl object result.
+ *
+ * Side effects:
+ * See the user documentation.
+ *
+ *----------------------------------------------------------------------
+ */
+
+int
+Tcl_TimeRateObjCmd(
+ ClientData dummy, /* Not used. */
+ Tcl_Interp *interp, /* Current interpreter. */
+ int objc, /* Number of arguments. */
+ Tcl_Obj *const objv[]) /* Argument objects. */
+{
+ static double measureOverhead = 0; /* global measure-overhead */
+ double overhead = -1; /* given measure-overhead */
+ register Tcl_Obj *objPtr;
+ register int result, i;
+ Tcl_Obj *calibrate = NULL, *direct = NULL;
+ Tcl_WideUInt count = 0; /* Holds repetition count */
+ Tcl_WideInt maxms = WIDE_MIN;
+ /* Maximal running time (in milliseconds) */
+ Tcl_WideUInt maxcnt = WIDE_MAX;
+ /* Maximal count of iterations. */
+ Tcl_WideUInt threshold = 1; /* Current threshold for check time (faster
+ * repeat count without time check) */
+ Tcl_WideUInt maxIterTm = 1; /* Max time of some iteration as max threshold
+ * additionally avoid divide to zero (never < 1) */
+ unsigned short factor = 50; /* Factor (4..50) limiting threshold to avoid
+ * growth of execution time. */
+ register Tcl_WideInt start, middle, stop;
+#ifndef TCL_WIDE_CLICKS
+ Tcl_Time now;
+#endif
+
+ static const char *const options[] = {
+ "-direct", "-overhead", "-calibrate", "--", NULL
+ };
+ enum options {
+ TMRT_EV_DIRECT, TMRT_OVERHEAD, TMRT_CALIBRATE, TMRT_LAST
+ };
+
+ NRE_callback *rootPtr;
+ ByteCode *codePtr = NULL;
+
+ for (i = 1; i < objc - 1; i++) {
+ int index;
+ if (Tcl_GetIndexFromObj(NULL, objv[i], options, "option", TCL_EXACT,
+ &index) != TCL_OK) {
+ break;
+ }
+ if (index == TMRT_LAST) {
+ i++;
+ break;
+ }
+ switch (index) {
+ case TMRT_EV_DIRECT:
+ direct = objv[i];
+ break;
+ case TMRT_OVERHEAD:
+ if (++i >= objc - 1) {
+ goto usage;
+ }
+ if (Tcl_GetDoubleFromObj(interp, objv[i], &overhead) != TCL_OK) {
+ return TCL_ERROR;
+ }
+ break;
+ case TMRT_CALIBRATE:
+ calibrate = objv[i];
+ break;
+ }
+ }
+
+ if (i >= objc || i < objc-3) {
+usage:
+ Tcl_WrongNumArgs(interp, 1, objv, "?-direct? ?-calibrate? ?-overhead double? command ?time ?max-count??");
+ return TCL_ERROR;
+ }
+ objPtr = objv[i++];
+ if (i < objc) { /* max-time */
+ result = Tcl_GetWideIntFromObj(interp, objv[i++], &maxms);
+ if (result != TCL_OK) {
+ return result;
+ }
+ if (i < objc) { /* max-count*/
+ Tcl_WideInt v;
+ result = Tcl_GetWideIntFromObj(interp, objv[i], &v);
+ if (result != TCL_OK) {
+ return result;
+ }
+ maxcnt = (v > 0) ? v : 0;
+ }
+ }
+
+ /* if calibrate */
+ if (calibrate) {
+
+ /* if no time specified for the calibration */
+ if (maxms == WIDE_MIN) {
+ Tcl_Obj *clobjv[6];
+ Tcl_WideInt maxCalTime = 5000;
+ double lastMeasureOverhead = measureOverhead;
+
+ clobjv[0] = objv[0];
+ i = 1;
+ if (direct) {
+ clobjv[i++] = direct;
+ }
+ clobjv[i++] = objPtr;
+
+ /* reset last measurement overhead */
+ measureOverhead = (double)0;
+
+ /* self-call with 100 milliseconds to warm-up,
+ * before entering the calibration cycle */
+ TclNewIntObj(clobjv[i], 100);
+ Tcl_IncrRefCount(clobjv[i]);
+ result = Tcl_TimeRateObjCmd(dummy, interp, i+1, clobjv);
+ Tcl_DecrRefCount(clobjv[i]);
+ if (result != TCL_OK) {
+ return result;
+ }
+
+ i--;
+ clobjv[i++] = calibrate;
+ clobjv[i++] = objPtr;
+
+ /* set last measurement overhead to max */
+ measureOverhead = (double)UWIDE_MAX;
+
+ /* calibration cycle until it'll be preciser */
+ maxms = -1000;
+ do {
+ lastMeasureOverhead = measureOverhead;
+ TclNewIntObj(clobjv[i], (int)maxms);
+ Tcl_IncrRefCount(clobjv[i]);
+ result = Tcl_TimeRateObjCmd(dummy, interp, i+1, clobjv);
+ Tcl_DecrRefCount(clobjv[i]);
+ if (result != TCL_OK) {
+ return result;
+ }
+ maxCalTime += maxms;
+ /* increase maxms for preciser calibration */
+ maxms -= (-maxms / 4);
+ /* as long as new value more as 0.05% better */
+ } while ( (measureOverhead >= lastMeasureOverhead
+ || measureOverhead / lastMeasureOverhead <= 0.9995)
+ && maxCalTime > 0
+ );
+
+ return result;
+ }
+ if (maxms == 0) {
+ /* reset last measurement overhead */
+ measureOverhead = 0;
+ Tcl_SetObjResult(interp, Tcl_NewLongObj(0));
+ return TCL_OK;
+ }
+
+ /* if time is negative - make current overhead more precise */
+ if (maxms > 0) {
+ /* set last measurement overhead to max */
+ measureOverhead = (double)UWIDE_MAX;
+ } else {
+ maxms = -maxms;
+ }
+
+ }
+
+ if (maxms == WIDE_MIN) {
+ maxms = 1000;
+ }
+ if (overhead == -1) {
+ overhead = measureOverhead;
+ }
+
+ /* be sure that resetting of result will not smudge the further measurement */
+ Tcl_ResetResult(interp);
+
+ /* compile object */
+ if (!direct) {
+ if (TclInterpReady(interp) != TCL_OK) {
+ return TCL_ERROR;
+ }
+ codePtr = TclCompileObj(interp, objPtr, NULL, 0);
+ TclPreserveByteCode(codePtr);
+ }
+
+ /* get start and stop time */
+#ifdef TCL_WIDE_CLICKS
+ start = middle = TclpGetWideClicks();
+ /* time to stop execution (in wide clicks) */
+ stop = start + (maxms * 1000 / TclpWideClickInMicrosec());
+#else
+ Tcl_GetTime(&now);
+ start = now.sec; start *= 1000000; start += now.usec;
+ middle = start;
+ /* time to stop execution (in microsecs) */
+ stop = start + maxms * 1000;
+#endif
+
+ /* start measurement */
+ if (maxcnt > 0)
+ while (1) {
+ /* eval single iteration */
+ count++;
+
+ if (!direct) {
+ /* precompiled */
+ rootPtr = TOP_CB(interp);
+ result = TclNRExecuteByteCode(interp, codePtr);
+ result = TclNRRunCallbacks(interp, result, rootPtr);
+ } else {
+ /* eval */
+ result = TclEvalObjEx(interp, objPtr, 0, NULL, 0);
+ }
+ if (result != TCL_OK) {
+ /* allow break from measurement cycle (used for conditional stop) */
+ if (result != TCL_BREAK) {
+ goto done;
+ }
+ /* force stop immediately */
+ threshold = 1;
+ maxcnt = 0;
+ result = TCL_OK;
+ }
+
+ /* don't check time up to threshold */
+ if (--threshold > 0) continue;
+
+ /* check stop time reached, estimate new threshold */
+ #ifdef TCL_WIDE_CLICKS
+ middle = TclpGetWideClicks();
+ #else
+ Tcl_GetTime(&now);
+ middle = now.sec; middle *= 1000000; middle += now.usec;
+ #endif
+ if (middle >= stop || count >= maxcnt) {
+ break;
+ }
+
+ /* don't calculate threshold by few iterations, because sometimes first
+ * iteration(s) can be too fast or slow (cached, delayed clean up, etc) */
+ if (count < 10) {
+ threshold = 1; continue;
+ }
+
+ /* average iteration time in microsecs */
+ threshold = (middle - start) / count;
+ if (threshold > maxIterTm) {
+ maxIterTm = threshold;
+ /* interations seems to be longer */
+ if (threshold > (maxIterTm * 2)) {
+ if ((factor *= 2) > 50) factor = 50;
+ } else {
+ if (factor < 50) factor++;
+ }
+ } else if (factor > 4) {
+ /* interations seems to be shorter */
+ if (threshold < (maxIterTm / 2)) {
+ if ((factor /= 2) < 4) factor = 4;
+ } else {
+ factor--;
+ }
+ }
+ /* as relation between remaining time and time since last check,
+ * maximal some % of time (by factor), so avoid growing of the execution time
+ * if iterations are not consistent, e. g. wax continuously on time) */
+ threshold = ((stop - middle) / maxIterTm) / factor + 1;
+ if (threshold > 100000) { /* fix for too large threshold */
+ threshold = 100000;
+ }
+ /* consider max-count */
+ if (threshold > maxcnt - count) {
+ threshold = maxcnt - count;
+ }
+ }
+
+ {
+ Tcl_Obj *objarr[8], **objs = objarr;
+ Tcl_WideInt val;
+ const char *fmt;
+
+ middle -= start; /* execution time in microsecs */
+
+ #ifdef TCL_WIDE_CLICKS
+ /* convert execution time in wide clicks to microsecs */
+ middle *= TclpWideClickInMicrosec();
+ #endif
+
+ if (!count) { /* no iterations - avoid divide by zero */
+ objs[0] = objs[2] = objs[4] = Tcl_NewWideIntObj(0);
+ goto retRes;
+ }
+
+ /* if not calibrate */
+ if (!calibrate) {
+ /* minimize influence of measurement overhead */
+ if (overhead > 0) {
+ /* estimate the time of overhead (microsecs) */
+ Tcl_WideUInt curOverhead = overhead * count;
+ if (middle > (Tcl_WideInt)curOverhead) {
+ middle -= curOverhead;
+ } else {
+ middle = 0;
+ }
+ }
+ } else {
+ /* calibration - obtaining new measurement overhead */
+ if (measureOverhead > (double)middle / count) {
+ measureOverhead = (double)middle / count;
+ }
+ objs[0] = Tcl_NewDoubleObj(measureOverhead);
+ TclNewLiteralStringObj(objs[1], "\xC2\xB5s/#-overhead"); /* mics */
+ objs += 2;
+ }
+
+ val = middle / count; /* microsecs per iteration */
+ if (val >= 1000000) {
+ objs[0] = Tcl_NewWideIntObj(val);
+ } else {
+ if (val < 10) { fmt = "%.6f"; } else
+ if (val < 100) { fmt = "%.4f"; } else
+ if (val < 1000) { fmt = "%.3f"; } else
+ if (val < 10000) { fmt = "%.2f"; } else
+ { fmt = "%.1f"; };
+ objs[0] = Tcl_ObjPrintf(fmt, ((double)middle)/count);
+ }
+
+ objs[2] = Tcl_NewWideIntObj(count); /* iterations */
+
+ /* calculate speed as rate (count) per sec */
+ if (!middle) middle++; /* +1 ms, just to avoid divide by zero */
+ if (count < (WIDE_MAX / 1000000)) {
+ val = (count * 1000000) / middle;
+ if (val < 100000) {
+ if (val < 100) { fmt = "%.3f"; } else
+ if (val < 1000) { fmt = "%.2f"; } else
+ { fmt = "%.1f"; };
+ objs[4] = Tcl_ObjPrintf(fmt, ((double)(count * 1000000)) / middle);
+ } else {
+ objs[4] = Tcl_NewWideIntObj(val);
+ }
+ } else {
+ objs[4] = Tcl_NewWideIntObj((count / middle) * 1000000);
+ }
+
+ retRes:
+ /* estimated net execution time (in millisecs) */
+ if (!calibrate) {
+ if (middle >= 1) {
+ objs[6] = Tcl_ObjPrintf("%.3f", (double)middle / 1000);
+ } else {
+ objs[6] = Tcl_NewWideIntObj(0);
+ }
+ TclNewLiteralStringObj(objs[7], "nett-ms");
+ }
+
+ /*
+ * Construct the result as a list because many programs have always parsed
+ * as such (extracting the first element, typically).
+ */
+
+ TclNewLiteralStringObj(objs[1], "\xC2\xB5s/#"); /* mics/# */
+ TclNewLiteralStringObj(objs[3], "#");
+ TclNewLiteralStringObj(objs[5], "#/sec");
+ Tcl_SetObjResult(interp, Tcl_NewListObj(8, objarr));
+ }
+
+done:
+
+ if (codePtr != NULL) {
+ TclReleaseByteCode(codePtr);
+ }
+
+ return result;
+}
+
+/*
+ *----------------------------------------------------------------------
+ *
* Tcl_TryObjCmd, TclNRTryObjCmd --
*
* This procedure is invoked to process the "try" Tcl command. See the
@@ -4476,18 +4870,24 @@ TryPostBody(
Tcl_Obj *varName;
Tcl_ListObjIndex(NULL, info[3], 0, &varName);
+ Tcl_IncrRefCount(varName);
if (Tcl_ObjSetVar2(interp, varName, NULL, resultObj,
TCL_LEAVE_ERR_MSG) == NULL) {
+ Tcl_DecrRefCount(varName);
Tcl_DecrRefCount(resultObj);
goto handlerFailed;
}
+ Tcl_DecrRefCount(varName);
Tcl_DecrRefCount(resultObj);
if (dummy > 1) {
Tcl_ListObjIndex(NULL, info[3], 1, &varName);
+ Tcl_IncrRefCount(varName);
if (Tcl_ObjSetVar2(interp, varName, NULL, options,
TCL_LEAVE_ERR_MSG) == NULL) {
+ Tcl_DecrRefCount(varName);
goto handlerFailed;
}
+ Tcl_DecrRefCount(varName);
}
} else {
/*
diff --git a/generic/tclCompCmdsGR.c b/generic/tclCompCmdsGR.c
index 26e9c87..441611e 100644
--- a/generic/tclCompCmdsGR.c
+++ b/generic/tclCompCmdsGR.c
@@ -2121,7 +2121,7 @@ TclCompileRegexpCmd(
sawLast++;
i++;
break;
- } else if ((len > 1) && (strncmp(str,"-nocase",(unsigned)len) == 0)) {
+ } else if ((len > 1) && (strncmp(str, "-nocase", len) == 0)) {
nocase = 1;
} else {
/*
diff --git a/generic/tclCompCmdsSZ.c b/generic/tclCompCmdsSZ.c
index 72cb6f2..4663fac 100644
--- a/generic/tclCompCmdsSZ.c
+++ b/generic/tclCompCmdsSZ.c
@@ -1559,7 +1559,7 @@ TclSubstCompile(
for (endTokenPtr = tokenPtr + parse.numTokens;
tokenPtr < endTokenPtr; tokenPtr = TokenAfter(tokenPtr)) {
int length, literal, catchRange, breakJump;
- char buf[TCL_UTF_MAX];
+ char buf[4] = "";
JumpFixup startFixup, okFixup, returnFixup, breakFixup;
JumpFixup continueFixup, otherFixup, endFixup;
diff --git a/generic/tclCompExpr.c b/generic/tclCompExpr.c
index e96e264..56c8931 100644
--- a/generic/tclCompExpr.c
+++ b/generic/tclCompExpr.c
@@ -2027,7 +2027,7 @@ ParseLexeme(
* Example: Inf + luence + () becomes a valid function call.
* [Bug 3401704]
*/
- if (literal->typePtr == &tclDoubleType) {
+ if (TclHasIntRep(literal, &tclDoubleType)) {
const char *p = start;
while (p < end) {
@@ -2066,9 +2066,9 @@ ParseLexeme(
if (Tcl_UtfCharComplete(start, numBytes)) {
scanned = TclUtfToUniChar(start, &ch);
} else {
- char utfBytes[TCL_UTF_MAX];
+ char utfBytes[4];
- memcpy(utfBytes, start, (size_t) numBytes);
+ memcpy(utfBytes, start, numBytes);
utfBytes[numBytes] = '\0';
scanned = TclUtfToUniChar(utfBytes, &ch);
}
diff --git a/generic/tclCompile.c b/generic/tclCompile.c
index f6e6b81..c0e8c62 100644
--- a/generic/tclCompile.c
+++ b/generic/tclCompile.c
@@ -1744,7 +1744,7 @@ TclWordKnownAtCompileTime(
case TCL_TOKEN_BS:
if (tempPtr != NULL) {
- char utfBuf[TCL_UTF_MAX];
+ char utfBuf[4] = "";
int length = TclParseBackslash(tokenPtr->start,
tokenPtr->size, NULL, utfBuf);
@@ -2358,7 +2358,7 @@ TclCompileTokens(
{
Tcl_DString textBuffer; /* Holds concatenated chars from adjacent
* TCL_TOKEN_TEXT, TCL_TOKEN_BS tokens. */
- char buffer[TCL_UTF_MAX];
+ char buffer[4] = "";
int i, numObjsToConcat, length, adjust;
unsigned char *entryCodeNext = envPtr->codeNext;
#define NUM_STATIC_POS 20
@@ -2837,7 +2837,7 @@ TclInitByteCode(
p += sizeof(ByteCode);
codePtr->codeStart = p;
- memcpy(p, envPtr->codeStart, (size_t) codeBytes);
+ memcpy(p, envPtr->codeStart, codeBytes);
p += TCL_ALIGN(codeBytes); /* align object array */
codePtr->objArrayPtr = (Tcl_Obj **) p;
@@ -2848,7 +2848,7 @@ TclInitByteCode(
p += TCL_ALIGN(objArrayBytes); /* align exception range array */
if (exceptArrayBytes > 0) {
codePtr->exceptArrayPtr = (ExceptionRange *) p;
- memcpy(p, envPtr->exceptArrayPtr, (size_t) exceptArrayBytes);
+ memcpy(p, envPtr->exceptArrayPtr, exceptArrayBytes);
} else {
codePtr->exceptArrayPtr = NULL;
}
@@ -2856,7 +2856,7 @@ TclInitByteCode(
p += TCL_ALIGN(exceptArrayBytes); /* align AuxData array */
if (auxDataArrayBytes > 0) {
codePtr->auxDataArrayPtr = (AuxData *) p;
- memcpy(p, envPtr->auxDataArrayPtr, (size_t) auxDataArrayBytes);
+ memcpy(p, envPtr->auxDataArrayPtr, auxDataArrayBytes);
} else {
codePtr->auxDataArrayPtr = NULL;
}
@@ -3008,7 +3008,7 @@ TclFindCompiledLocal(
char *localName = localPtr->name;
if ((nameBytes == localPtr->nameLength) &&
- (strncmp(name,localName,(unsigned)nameBytes) == 0)) {
+ (strncmp(name, localName, nameBytes) == 0)) {
return i;
}
}
@@ -3040,7 +3040,7 @@ TclFindCompiledLocal(
localPtr->resolveInfo = NULL;
if (name != NULL) {
- memcpy(localPtr->name, name, (size_t) nameBytes);
+ memcpy(localPtr->name, name, nameBytes);
}
localPtr->name[nameBytes] = '\0';
procPtr->numCompiledLocals++;
diff --git a/generic/tclDecls.h b/generic/tclDecls.h
index 865c960..c50b41f 100644
--- a/generic/tclDecls.h
+++ b/generic/tclDecls.h
@@ -754,7 +754,8 @@ EXTERN void Tcl_StaticPackage(Tcl_Interp *interp,
Tcl_PackageInitProc *initProc,
Tcl_PackageInitProc *safeInitProc);
/* 245 */
-EXTERN int Tcl_StringMatch(const char *str, const char *pattern);
+TCL_DEPRECATED("No longer in use, changed to macro")
+int Tcl_StringMatch(const char *str, const char *pattern);
/* 246 */
TCL_DEPRECATED("")
int Tcl_TellOld(Tcl_Channel chan);
@@ -2176,7 +2177,7 @@ typedef struct TclStubs {
int (*tcl_SplitList) (Tcl_Interp *interp, const char *listStr, int *argcPtr, const char ***argvPtr); /* 242 */
void (*tcl_SplitPath) (const char *path, int *argcPtr, const char ***argvPtr); /* 243 */
TCL_DEPRECATED_API("Don't use this function in a stub-enabled extension") void (*tcl_StaticPackage) (Tcl_Interp *interp, const char *pkgName, Tcl_PackageInitProc *initProc, Tcl_PackageInitProc *safeInitProc); /* 244 */
- int (*tcl_StringMatch) (const char *str, const char *pattern); /* 245 */
+ TCL_DEPRECATED_API("No longer in use, changed to macro") int (*tcl_StringMatch) (const char *str, const char *pattern); /* 245 */
TCL_DEPRECATED_API("") int (*tcl_TellOld) (Tcl_Channel chan); /* 246 */
TCL_DEPRECATED_API("No longer in use, changed to macro") int (*tcl_TraceVar) (Tcl_Interp *interp, const char *varName, int flags, Tcl_VarTraceProc *proc, ClientData clientData); /* 247 */
int (*tcl_TraceVar2) (Tcl_Interp *interp, const char *part1, const char *part2, int flags, Tcl_VarTraceProc *proc, ClientData clientData); /* 248 */
@@ -4073,6 +4074,8 @@ extern const TclStubs *tclStubsPtr;
#define Tcl_GetUnicode(objPtr) Tcl_GetUnicodeFromObj((objPtr), NULL)
#undef Tcl_BackgroundError
#define Tcl_BackgroundError(interp) Tcl_BackgroundException((interp), TCL_ERROR)
+#undef Tcl_StringMatch
+#define Tcl_StringMatch(str, pattern) Tcl_StringCaseMatch((str), (pattern), 0)
/*
* Deprecated Tcl procedures:
diff --git a/generic/tclDictObj.c b/generic/tclDictObj.c
index 629a3f0..baf96a8 100644
--- a/generic/tclDictObj.c
+++ b/generic/tclDictObj.c
@@ -623,7 +623,7 @@ SetDictFromAny(
* the conversion from lists to dictionaries.
*/
- if (objPtr->typePtr == &tclListType) {
+ if (TclHasIntRep(objPtr, &tclListType)) {
int objc, i;
Tcl_Obj **objv;
diff --git a/generic/tclDisassemble.c b/generic/tclDisassemble.c
index 027683d..e5fce72 100644
--- a/generic/tclDisassemble.c
+++ b/generic/tclDisassemble.c
@@ -1384,7 +1384,7 @@ Tcl_DisassembleObjCmd(
return TCL_ERROR;
}
- if ((objv[2]->typePtr != &tclByteCodeType) && (TCL_OK
+ if (!TclHasIntRep(objv[2], &tclByteCodeType) && (TCL_OK
!= TclSetByteCodeFromAny(interp, objv[2], NULL, NULL))) {
return TCL_ERROR;
}
@@ -1435,7 +1435,7 @@ Tcl_DisassembleObjCmd(
* Compile if necessary.
*/
- if (procPtr->bodyPtr->typePtr != &tclByteCodeType) {
+ if (!TclHasIntRep(procPtr->bodyPtr, &tclByteCodeType)) {
Command cmd;
/*
@@ -1500,7 +1500,7 @@ Tcl_DisassembleObjCmd(
* Compile if necessary.
*/
- if (procPtr->bodyPtr->typePtr != &tclByteCodeType) {
+ if (!TclHasIntRep(procPtr->bodyPtr, &tclByteCodeType)) {
Command cmd;
/*
@@ -1585,7 +1585,7 @@ Tcl_DisassembleObjCmd(
"METHODTYPE", NULL);
return TCL_ERROR;
}
- if (procPtr->bodyPtr->typePtr != &tclByteCodeType) {
+ if (!TclHasIntRep(procPtr->bodyPtr, &tclByteCodeType)) {
Command cmd;
/*
diff --git a/generic/tclEncoding.c b/generic/tclEncoding.c
index e601c3a..7eb73e8 100644
--- a/generic/tclEncoding.c
+++ b/generic/tclEncoding.c
@@ -234,12 +234,12 @@ static int TableToUtfProc(ClientData clientData, const char *src,
char *dst, int dstLen, int *srcReadPtr,
int *dstWrotePtr, int *dstCharsPtr);
static size_t unilen(const char *src);
-static int UnicodeToUtfProc(ClientData clientData,
+static int UniCharToUtfProc(ClientData clientData,
const char *src, int srcLen, int flags,
Tcl_EncodingState *statePtr, char *dst, int dstLen,
int *srcReadPtr, int *dstWrotePtr,
int *dstCharsPtr);
-static int UtfToUnicodeProc(ClientData clientData,
+static int UtfToUniCharProc(ClientData clientData,
const char *src, int srcLen, int flags,
Tcl_EncodingState *statePtr, char *dst, int dstLen,
int *srcReadPtr, int *dstWrotePtr,
@@ -596,8 +596,8 @@ TclInitEncodingSubsystem(void)
Tcl_CreateEncoding(&type);
type.encodingName = "unicode";
- type.toUtfProc = UnicodeToUtfProc;
- type.fromUtfProc = UtfToUnicodeProc;
+ type.toUtfProc = UniCharToUtfProc;
+ type.fromUtfProc = UtfToUniCharProc;
type.freeProc = NULL;
type.nullSize = 2;
type.clientData = NULL;
@@ -2073,9 +2073,9 @@ LoadEscapeEncoding(
+ Tcl_DStringLength(&escapeData);
dataPtr = ckalloc(size);
dataPtr->initLen = strlen(init);
- memcpy(dataPtr->init, init, (unsigned) dataPtr->initLen + 1);
+ memcpy(dataPtr->init, init, dataPtr->initLen + 1);
dataPtr->finalLen = strlen(final);
- memcpy(dataPtr->final, final, (unsigned) dataPtr->finalLen + 1);
+ memcpy(dataPtr->final, final, dataPtr->finalLen + 1);
dataPtr->numSubTables =
Tcl_DStringLength(&escapeData) / sizeof(EscapeSubTable);
memcpy(dataPtr->subTables, Tcl_DStringValue(&escapeData),
@@ -2167,7 +2167,7 @@ BinaryProc(
*srcReadPtr = srcLen;
*dstWrotePtr = srcLen;
*dstCharsPtr = srcLen;
- memcpy(dst, src, (size_t) srcLen);
+ memcpy(dst, src, srcLen);
return result;
}
@@ -2384,8 +2384,8 @@ UtfToUtfProc(
src += len;
dst += Tcl_UniCharToUtf(*chPtr, dst);
#if TCL_UTF_MAX <= 4
- if (!len) {
- src += TclUtfToUniChar(src, chPtr);
+ if ((*chPtr >= 0xD800) && (len < 3)) {
+ src += TclUtfToUniChar(src + len, chPtr);
dst += Tcl_UniCharToUtf(*chPtr, dst);
}
#endif
@@ -2401,7 +2401,7 @@ UtfToUtfProc(
/*
*-------------------------------------------------------------------------
*
- * UnicodeToUtfProc --
+ * UniCharToUtfProc --
*
* Convert from Unicode to UTF-8.
*
@@ -2415,7 +2415,7 @@ UtfToUtfProc(
*/
static int
-UnicodeToUtfProc(
+UniCharToUtfProc(
ClientData clientData, /* Not used. */
const char *src, /* Source string in Unicode. */
int srcLen, /* Source string length in bytes. */
@@ -2444,19 +2444,16 @@ UnicodeToUtfProc(
const char *srcStart, *srcEnd;
const char *dstEnd, *dstStart;
int result, numChars, charLimit = INT_MAX;
- Tcl_UniChar *chPtr = (Tcl_UniChar *) statePtr;
+ unsigned short ch;
- if (flags & TCL_ENCODING_START) {
- *statePtr = 0;
- }
if (flags & TCL_ENCODING_CHAR_LIMIT) {
charLimit = *dstCharsPtr;
}
result = TCL_OK;
- if ((srcLen % sizeof(Tcl_UniChar)) != 0) {
+ if ((srcLen % sizeof(unsigned short)) != 0) {
result = TCL_CONVERT_MULTIBYTE;
- srcLen /= sizeof(Tcl_UniChar);
- srcLen *= sizeof(Tcl_UniChar);
+ srcLen /= sizeof(unsigned short);
+ srcLen *= sizeof(unsigned short);
}
srcStart = src;
@@ -2473,16 +2470,16 @@ UnicodeToUtfProc(
/*
* Special case for 1-byte utf chars for speed. Make sure we work with
- * Tcl_UniChar-size data.
+ * unsigned short-size data.
*/
- *chPtr = *(Tcl_UniChar *)src;
- if (*chPtr && *chPtr < 0x80) {
- *dst++ = (*chPtr & 0xFF);
+ ch = *(unsigned short *)src;
+ if (ch && ch < 0x80) {
+ *dst++ = (ch & 0xFF);
} else {
- dst += Tcl_UniCharToUtf(*chPtr, dst);
+ dst += Tcl_UniCharToUtf(ch, dst);
}
- src += sizeof(Tcl_UniChar);
+ src += sizeof(unsigned short);
}
*srcReadPtr = src - srcStart;
@@ -2494,7 +2491,7 @@ UnicodeToUtfProc(
/*
*-------------------------------------------------------------------------
*
- * UtfToUnicodeProc --
+ * UtfToUniCharProc --
*
* Convert from UTF-8 to Unicode.
*
@@ -2508,7 +2505,7 @@ UnicodeToUtfProc(
*/
static int
-UtfToUnicodeProc(
+UtfToUniCharProc(
ClientData clientData, /* TableEncodingData that specifies
* encoding. */
const char *src, /* Source string in UTF-8. */
@@ -2576,20 +2573,30 @@ UtfToUnicodeProc(
#ifdef WORDS_BIGENDIAN
#if TCL_UTF_MAX > 4
- *dst++ = (*chPtr >> 24);
- *dst++ = ((*chPtr >> 16) & 0xFF);
- *dst++ = ((*chPtr >> 8) & 0xFF);
- *dst++ = (*chPtr & 0xFF);
+ if (*chPtr <= 0xFFFF) {
+ *dst++ = (*chPtr >> 8);
+ *dst++ = (*chPtr & 0xFF);
+ } else {
+ *dst++ = ((*chPtr & 0x3) >> 8) | 0xDC;
+ *dst++ = (*chPtr & 0xFF);
+ *dst++ = (((*chPtr - 0x10000) >> 18) & 0x3) | 0xD8;
+ *dst++ = (((*chPtr - 0x10000) >> 10) & 0xFF);
+ }
#else
*dst++ = (*chPtr >> 8);
*dst++ = (*chPtr & 0xFF);
#endif
#else
#if TCL_UTF_MAX > 4
- *dst++ = (*chPtr & 0xFF);
- *dst++ = ((*chPtr >> 8) & 0xFF);
- *dst++ = ((*chPtr >> 16) & 0xFF);
- *dst++ = (*chPtr >> 24);
+ if (*chPtr <= 0xFFFF) {
+ *dst++ = (*chPtr & 0xFF);
+ *dst++ = (*chPtr >> 8);
+ } else {
+ *dst++ = (((*chPtr - 0x10000) >> 10) & 0xFF);
+ *dst++ = (((*chPtr - 0x10000) >> 18) & 0x3) | 0xD8;
+ *dst++ = (*chPtr & 0xFF);
+ *dst++ = ((*chPtr & 0x3) >> 8) | 0xDC;
+ }
#else
*dst++ = (*chPtr & 0xFF);
*dst++ = (*chPtr >> 8);
@@ -3006,7 +3013,7 @@ Iso88591FromUtfProc(
if (ch > 0xff
#if TCL_UTF_MAX <= 4
- || !len
+ || ((ch >= 0xD800) && (len < 3))
#endif
) {
if (flags & TCL_ENCODING_STOPONERROR) {
@@ -3014,7 +3021,7 @@ Iso88591FromUtfProc(
break;
}
#if TCL_UTF_MAX <= 4
- if (!len) len = 4;
+ if ((ch >= 0xD800) && (len < 3)) len = 4;
#endif
/*
* Plunge on, using '?' as a fallback character.
@@ -3364,7 +3371,7 @@ EscapeFromUtfProc(
*dstWrotePtr = 0;
return TCL_CONVERT_NOSPACE;
}
- memcpy(dst, dataPtr->init, (size_t)dataPtr->initLen);
+ memcpy(dst, dataPtr->init, dataPtr->initLen);
dst += dataPtr->initLen;
} else {
state = PTR2INT(*statePtr);
@@ -3443,7 +3450,7 @@ EscapeFromUtfProc(
break;
}
memcpy(dst, subTablePtr->sequence,
- (size_t) subTablePtr->sequenceLen);
+ subTablePtr->sequenceLen);
dst += subTablePtr->sequenceLen;
}
}
@@ -3486,7 +3493,7 @@ EscapeFromUtfProc(
memcpy(dst, dataPtr->subTables[0].sequence, len);
dst += len;
}
- memcpy(dst, dataPtr->final, (size_t) dataPtr->finalLen);
+ memcpy(dst, dataPtr->final, dataPtr->finalLen);
dst += dataPtr->finalLen;
state &= ~TCL_ENCODING_END;
}
diff --git a/generic/tclEnsemble.c b/generic/tclEnsemble.c
index 73e3ce7..53b8bfb 100644
--- a/generic/tclEnsemble.c
+++ b/generic/tclEnsemble.c
@@ -1815,7 +1815,7 @@ NsEnsembleImplementationCmdNR(
for (i=0 ; i<tableLength ; i++) {
register int cmp = strncmp(subcmdName,
ensemblePtr->subcommandArrayPtr[i],
- (unsigned) stringLength);
+ stringLength);
if (cmp == 0) {
if (fullName != NULL) {
@@ -2769,7 +2769,7 @@ BuildEnsembleConfig(
hPtr = Tcl_NextHashEntry(&search);
}
if (hash->numEntries > 1) {
- qsort(ensemblePtr->subcommandArrayPtr, (unsigned) hash->numEntries,
+ qsort(ensemblePtr->subcommandArrayPtr, hash->numEntries,
sizeof(char *), NsEnsembleStringOrder);
}
}
diff --git a/generic/tclEnv.c b/generic/tclEnv.c
index 40ced17..9677b86 100644
--- a/generic/tclEnv.c
+++ b/generic/tclEnv.c
@@ -119,7 +119,8 @@ TclSetupEnv(
Tcl_MutexLock(&envMutex);
for (i = 0; environ[i] != NULL; i++) {
Tcl_Obj *obj1, *obj2;
- char *p1, *p2;
+ const char *p1;
+ char *p2;
p1 = Tcl_ExternalToUtfDString(NULL, environ[i], -1, &envString);
p2 = strchr(p1, '=');
@@ -135,6 +136,18 @@ TclSetupEnv(
}
p2++;
p2[-1] = '\0';
+#if defined(_WIN32)
+ /*
+ * Enforce PATH and COMSPEC to be all uppercase. This eliminates
+ * additional trace logic otherwise required in init.tcl.
+ */
+
+ if (strcasecmp(p1, "PATH") == 0) {
+ p1 = "PATH";
+ } else if (strcasecmp(p1, "COMSPEC") == 0) {
+ p1 = "COMSPEC";
+ }
+#endif
obj1 = Tcl_NewStringObj(p1, -1);
obj2 = Tcl_NewStringObj(p2, -1);
Tcl_DStringFree(&envString);
@@ -260,7 +273,7 @@ TclSetEnv(
Tcl_DStringFree(&envString);
oldValue = environ[index];
- nameLength = (unsigned) length;
+ nameLength = length;
}
/*
@@ -281,7 +294,7 @@ TclSetEnv(
*/
p = ckrealloc(p, Tcl_DStringLength(&envString) + 1);
- memcpy(p, p2, (unsigned) Tcl_DStringLength(&envString) + 1);
+ memcpy(p, p2, Tcl_DStringLength(&envString) + 1);
Tcl_DStringFree(&envString);
#ifdef USE_PUTENV
@@ -442,19 +455,19 @@ TclUnsetEnv(
#if defined(_WIN32)
string = ckalloc(length + 2);
- memcpy(string, name, (size_t) length);
+ memcpy(string, name, length);
string[length] = '=';
string[length+1] = '\0';
#else
string = ckalloc(length + 1);
- memcpy(string, name, (size_t) length);
+ memcpy(string, name, length);
string[length] = '\0';
#endif /* _WIN32 */
Tcl_UtfToExternalDString(NULL, string, -1, &envString);
string = ckrealloc(string, Tcl_DStringLength(&envString) + 1);
memcpy(string, Tcl_DStringValue(&envString),
- (unsigned) Tcl_DStringLength(&envString)+1);
+ Tcl_DStringLength(&envString)+1);
Tcl_DStringFree(&envString);
putenv(string);
diff --git a/generic/tclExecute.c b/generic/tclExecute.c
index 17ad0bb..680bdd0 100644
--- a/generic/tclExecute.c
+++ b/generic/tclExecute.c
@@ -499,11 +499,11 @@ VarHashCreateVar(
*/
#define GetNumberFromObj(interp, objPtr, ptrPtr, tPtr) \
- (((objPtr)->typePtr == &tclIntType) \
+ ((TclHasIntRep((objPtr), &tclIntType)) \
? (*(tPtr) = TCL_NUMBER_INT, \
*(ptrPtr) = (ClientData) \
(&((objPtr)->internalRep.wideValue)), TCL_OK) : \
- ((objPtr)->typePtr == &tclDoubleType) \
+ TclHasIntRep((objPtr), &tclDoubleType) \
? (((TclIsNaN((objPtr)->internalRep.doubleValue)) \
? (*(tPtr) = TCL_NUMBER_NAN) \
: (*(tPtr) = TCL_NUMBER_DOUBLE)), \
@@ -4768,7 +4768,7 @@ TEBCresume(
*/
if ((TclListObjGetElements(interp, valuePtr, &objc, &objv) == TCL_OK)
- && (value2Ptr->typePtr != &tclListType)
+ && !TclHasIntRep(value2Ptr, &tclListType)
&& (TclGetIntForIndexM(NULL, value2Ptr, objc-1,
&index) == TCL_OK)) {
TclDecrRefCount(value2Ptr);
@@ -5215,7 +5215,7 @@ TEBCresume(
objResultPtr = Tcl_NewStringObj((const char *)
valuePtr->bytes+index, 1);
} else {
- char buf[4];
+ char buf[4] = "";
int ch = Tcl_GetUniChar(valuePtr, index);
/*
@@ -5227,8 +5227,8 @@ TEBCresume(
objResultPtr = Tcl_NewObj();
} else {
length = Tcl_UniCharToUtf(ch, buf);
- if (!length) {
- length = Tcl_UniCharToUtf(-1, buf);
+ if ((ch >= 0xD800) && (length < 3)) {
+ length += Tcl_UniCharToUtf(-1, buf + length);
}
objResultPtr = Tcl_NewStringObj(buf, length);
}
@@ -5486,8 +5486,8 @@ TEBCresume(
* both.
*/
- if ((valuePtr->typePtr == &tclStringType)
- || (value2Ptr->typePtr == &tclStringType)) {
+ if (TclHasIntRep(valuePtr, &tclStringType)
+ || TclHasIntRep(value2Ptr, &tclStringType)) {
Tcl_UniChar *ustring1, *ustring2;
ustring1 = Tcl_GetUnicodeFromObj(valuePtr, &length);
@@ -6293,7 +6293,7 @@ TEBCresume(
case INST_TRY_CVT_TO_BOOLEAN:
valuePtr = OBJ_AT_TOS;
- if (valuePtr->typePtr == &tclBooleanType) {
+ if (TclHasIntRep(valuePtr, &tclBooleanType)) {
objResultPtr = TCONST(1);
} else {
int result = (TclSetBooleanFromAny(NULL, valuePtr) == TCL_OK);
@@ -7108,7 +7108,7 @@ TEBCresume(
}
varPtr = LOCAL(opnd);
if (varPtr->value.objPtr) {
- if (varPtr->value.objPtr->typePtr == &dictIteratorType) {
+ if (TclHasIntRep(varPtr->value.objPtr, &dictIteratorType)) {
Tcl_Panic("mis-issued dictFirst!");
}
TclDecrRefCount(varPtr->value.objPtr);
@@ -7985,8 +7985,8 @@ ExecuteExtendedBinaryMathOp(
if (((wQuotient < (Tcl_WideInt) 0)
|| ((wQuotient == (Tcl_WideInt) 0)
- && ((w1 < (Tcl_WideInt)0 && w2 > (Tcl_WideInt)0)
- || (w1 > (Tcl_WideInt)0 && w2 < (Tcl_WideInt)0))))
+ && ((w1 < 0 && w2 > 0)
+ || (w1 > 0 && w2 < 0))))
&& (wQuotient * w2 != w1)) {
wQuotient -= (Tcl_WideInt) 1;
}
@@ -8020,7 +8020,7 @@ ExecuteExtendedBinaryMathOp(
mp_init(&bigResult);
mp_init(&bigRemainder);
mp_div(&big1, &big2, &bigResult, &bigRemainder);
- if (!mp_iszero(&bigRemainder) && (bigRemainder.sign != big2.sign)) {
+ if ((bigRemainder.used != 0) && (bigRemainder.sign != big2.sign)) {
/*
* Convert to Tcl's integer division rules.
*/
@@ -8042,11 +8042,11 @@ ExecuteExtendedBinaryMathOp(
switch (type2) {
case TCL_NUMBER_INT:
- invalid = (*((const Tcl_WideInt *)ptr2) < (Tcl_WideInt)0);
+ invalid = (*((const Tcl_WideInt *)ptr2) < 0);
break;
case TCL_NUMBER_BIG:
Tcl_TakeBignumFromObj(NULL, value2Ptr, &big2);
- invalid = mp_isneg(&big2);
+ invalid = big2.sign != MP_ZPOS;
mp_clear(&big2);
break;
default:
@@ -8063,7 +8063,7 @@ ExecuteExtendedBinaryMathOp(
* Zero shifted any number of bits is still zero.
*/
- if ((type1==TCL_NUMBER_INT) && (*((const Tcl_WideInt *)ptr1) == (Tcl_WideInt)0)) {
+ if ((type1==TCL_NUMBER_INT) && (*((const Tcl_WideInt *)ptr1) == 0)) {
return constants[0];
}
@@ -8121,11 +8121,11 @@ ExecuteExtendedBinaryMathOp(
switch (type1) {
case TCL_NUMBER_INT:
- zero = (*(const Tcl_WideInt *)ptr1 > (Tcl_WideInt)0);
+ zero = (*(const Tcl_WideInt *)ptr1 > 0);
break;
case TCL_NUMBER_BIG:
Tcl_TakeBignumFromObj(NULL, valuePtr, &big1);
- zero = (!mp_isneg(&big1));
+ zero = (big1.sign == MP_ZPOS);
mp_clear(&big1);
break;
default:
@@ -8146,7 +8146,7 @@ ExecuteExtendedBinaryMathOp(
if (type1 == TCL_NUMBER_INT) {
w1 = *(const Tcl_WideInt *)ptr1;
if ((size_t)shift >= CHAR_BIT*sizeof(Tcl_WideInt)) {
- if (w1 >= (Tcl_WideInt)0) {
+ if (w1 >= 0) {
return constants[0];
}
WIDE_RESULT(-1);
@@ -8249,9 +8249,9 @@ ExecuteExtendedBinaryMathOp(
oddExponent = (int) (w2 & (Tcl_WideInt)1);
} else {
Tcl_TakeBignumFromObj(NULL, value2Ptr, &big2);
- negativeExponent = mp_isneg(&big2);
+ negativeExponent = big2.sign != MP_ZPOS;
mp_mod_2d(&big2, 1, &big2);
- oddExponent = !mp_iszero(&big2);
+ oddExponent = big2.used != 0;
mp_clear(&big2);
}
@@ -8400,7 +8400,11 @@ ExecuteExtendedBinaryMathOp(
overflowExpon:
Tcl_TakeBignumFromObj(NULL, value2Ptr, &big2);
- if (big2.used > 1) {
+ if ((big2.used > 1)
+#if DIGIT_BIT > 28
+ || ((big2.used == 1) && (big2.dp[0] >= (1<<28)))
+#endif
+ ) {
mp_clear(&big2);
Tcl_SetObjResult(interp, Tcl_NewStringObj(
"exponent too large", -1));
@@ -8568,7 +8572,7 @@ ExecuteExtendedBinaryMathOp(
mp_mul(&big1, &big2, &bigResult);
break;
case INST_DIV:
- if (mp_iszero(&big2)) {
+ if (big2.used == 0) {
mp_clear(&big1);
mp_clear(&big2);
mp_clear(&bigResult);
@@ -8577,7 +8581,7 @@ ExecuteExtendedBinaryMathOp(
mp_init(&bigRemainder);
mp_div(&big1, &big2, &bigResult, &bigRemainder);
/* TODO: internals intrusion */
- if (!mp_iszero(&bigRemainder)
+ if ((bigRemainder.used != 0)
&& (bigRemainder.sign != big2.sign)) {
/*
* Convert to Tcl's integer division rules.
@@ -8724,7 +8728,7 @@ TclCompareTwoNumbers(
goto wideCompare;
case TCL_NUMBER_BIG:
Tcl_TakeBignumFromObj(NULL, value2Ptr, &big2);
- if (mp_isneg(&big2)) {
+ if (big2.sign != MP_ZPOS) {
compare = MP_GT;
} else {
compare = MP_LT;
@@ -8761,7 +8765,7 @@ TclCompareTwoNumbers(
}
Tcl_TakeBignumFromObj(NULL, value2Ptr, &big2);
if ((d1 < (double)WIDE_MAX) && (d1 > (double)WIDE_MIN)) {
- if (mp_isneg(&big2)) {
+ if (big2.sign != MP_ZPOS) {
compare = MP_GT;
} else {
compare = MP_LT;
@@ -9622,7 +9626,7 @@ EvalStatsCmd(
for (i = 0; i < globalTablePtr->numBuckets; i++) {
for (entryPtr = globalTablePtr->buckets[i]; entryPtr != NULL;
entryPtr = entryPtr->nextPtr) {
- if (entryPtr->objPtr->typePtr == &tclByteCodeType) {
+ if (TclHasIntRep(entryPtr->objPtr, &tclByteCodeType)) {
numByteCodeLits++;
}
(void) TclGetStringFromObj(entryPtr->objPtr, &length);
diff --git a/generic/tclFileName.c b/generic/tclFileName.c
index 7dba19c..98ee37c 100644
--- a/generic/tclFileName.c
+++ b/generic/tclFileName.c
@@ -598,7 +598,7 @@ Tcl_SplitPath(
for (i = 0; i < *argcPtr; i++) {
Tcl_ListObjIndex(NULL, resultPtr, i, &eltPtr);
str = TclGetStringFromObj(eltPtr, &len);
- memcpy(p, str, (size_t) len+1);
+ memcpy(p, str, len+1);
p += len+1;
}
@@ -2548,21 +2548,21 @@ unsigned
Tcl_GetFSDeviceFromStat(
const Tcl_StatBuf *statPtr)
{
- return (unsigned) statPtr->st_dev;
+ return statPtr->st_dev;
}
unsigned
Tcl_GetFSInodeFromStat(
const Tcl_StatBuf *statPtr)
{
- return (unsigned) statPtr->st_ino;
+ return statPtr->st_ino;
}
unsigned
Tcl_GetModeFromStat(
const Tcl_StatBuf *statPtr)
{
- return (unsigned) statPtr->st_mode;
+ return statPtr->st_mode;
}
int
@@ -2639,7 +2639,7 @@ Tcl_GetBlockSizeFromStat(
const Tcl_StatBuf *statPtr)
{
#ifdef HAVE_STRUCT_STAT_ST_BLKSIZE
- return (unsigned) statPtr->st_blksize;
+ return statPtr->st_blksize;
#else
/*
* Not a great guess, but will do...
diff --git a/generic/tclHash.c b/generic/tclHash.c
index 32c9aec..f7f9b32 100644
--- a/generic/tclHash.c
+++ b/generic/tclHash.c
@@ -1015,8 +1015,8 @@ RebuildTable(
tablePtr->numBuckets *= 4;
if (typePtr->flags & TCL_HASH_KEY_SYSTEM_HASH) {
- tablePtr->buckets = (Tcl_HashEntry **) TclpSysAlloc((unsigned)
- (tablePtr->numBuckets * sizeof(Tcl_HashEntry *)), 0);
+ tablePtr->buckets = (Tcl_HashEntry **) TclpSysAlloc(
+ tablePtr->numBuckets * sizeof(Tcl_HashEntry *), 0);
} else {
tablePtr->buckets =
ckalloc(tablePtr->numBuckets * sizeof(Tcl_HashEntry *));
diff --git a/generic/tclIO.c b/generic/tclIO.c
index 7c93e1a..cf91307 100644
--- a/generic/tclIO.c
+++ b/generic/tclIO.c
@@ -4320,7 +4320,7 @@ Write(
* that we need to stick at the beginning of this buffer.
*/
- memcpy(InsertPoint(bufPtr), safe, (size_t) saved);
+ memcpy(InsertPoint(bufPtr), safe, saved);
bufPtr->nextAdded += saved;
saved = 0;
}
@@ -4408,7 +4408,7 @@ Write(
*/
saved = -SpaceLeft(bufPtr);
- memcpy(safe, dst + dstLen, (size_t) saved);
+ memcpy(safe, dst + dstLen, saved);
bufPtr->nextAdded = bufPtr->bufLength;
}
@@ -5086,7 +5086,7 @@ TclGetsObjBinary(
rawLen = dstEnd - dst;
byteArray = Tcl_SetByteArrayLength(objPtr, byteLen + rawLen);
- memcpy(byteArray + byteLen, dst, (size_t) rawLen);
+ memcpy(byteArray + byteLen, dst, rawLen);
byteLen += rawLen;
}
@@ -5103,7 +5103,7 @@ TclGetsObjBinary(
rawLen = eol - dst;
byteArray = Tcl_SetByteArrayLength(objPtr, byteLen + rawLen);
- memcpy(byteArray + byteLen, dst, (size_t) rawLen);
+ memcpy(byteArray + byteLen, dst, rawLen);
byteLen += rawLen;
bufPtr->nextRemoved += rawLen + skip;
@@ -5654,7 +5654,7 @@ Tcl_ReadRaw(
* Copy the current chunk into the read buffer.
*/
- memcpy(readBuf, RemovePoint(bufPtr), (size_t) toCopy);
+ memcpy(readBuf, RemovePoint(bufPtr), toCopy);
bufPtr->nextRemoved += toCopy;
copied += toCopy;
readBuf += toCopy;
@@ -6216,7 +6216,7 @@ ReadChars(
* and do not encounter the eof char this time.
*/
- dstLimit = dstRead - 1 + TCL_UTF_MAX;
+ dstLimit = dstRead + (TCL_UTF_MAX - 1);
statePtr->flags = savedFlags;
statePtr->inputEncodingFlags = savedIEFlags;
statePtr->inputEncodingState = savedState;
@@ -6241,7 +6241,7 @@ ReadChars(
* here in this call.
*/
- dstLimit = dstRead - 1 + TCL_UTF_MAX;
+ dstLimit = dstRead + (TCL_UTF_MAX - 1);
statePtr->flags = savedFlags;
statePtr->inputEncodingFlags = savedIEFlags;
statePtr->inputEncodingState = savedState;
@@ -6334,7 +6334,7 @@ ReadChars(
* bytes demanded by the Tcl_ExternalToUtf() call!
*/
- dstLimit = Tcl_UtfAtIndex(dst, charsToRead) - 1 + TCL_UTF_MAX - dst;
+ dstLimit = Tcl_UtfAtIndex(dst, charsToRead) - dst + (TCL_UTF_MAX - 1);
statePtr->flags = savedFlags;
statePtr->inputEncodingFlags = savedIEFlags;
statePtr->inputEncodingState = savedState;
@@ -6402,7 +6402,7 @@ ReadChars(
}
nextPtr->nextRemoved -= srcLen;
- memcpy(RemovePoint(nextPtr), src, (size_t) srcLen);
+ memcpy(RemovePoint(nextPtr), src, srcLen);
RecycleBuffer(statePtr, bufPtr, 0);
statePtr->inQueueHead = nextPtr;
Tcl_SetObjLength(objPtr, numBytes);
@@ -6508,7 +6508,7 @@ TranslateInputEOL(
case TCL_TRANSLATE_LF:
case TCL_TRANSLATE_CR:
if (dstStart != srcStart) {
- memcpy(dstStart, srcStart, (size_t) srcLen);
+ memcpy(dstStart, srcStart, srcLen);
}
if (statePtr->inputTranslation == TCL_TRANSLATE_CR) {
char *dst = dstStart;
@@ -6665,7 +6665,7 @@ Tcl_Ungets(
statePtr->inputEncodingFlags &= ~TCL_ENCODING_END;
bufPtr = AllocChannelBuffer(len);
- memcpy(InsertPoint(bufPtr), str, (size_t) len);
+ memcpy(InsertPoint(bufPtr), str, len);
bufPtr->nextAdded += len;
if (statePtr->inQueueHead == NULL) {
diff --git a/generic/tclIOCmd.c b/generic/tclIOCmd.c
index 1dd8666..271fc57 100644
--- a/generic/tclIOCmd.c
+++ b/generic/tclIOCmd.c
@@ -952,7 +952,7 @@ Tcl_ExecObjCmd(
*/
argc = objc - skip;
- argv = TclStackAlloc(interp, (unsigned)(argc + 1) * sizeof(char *));
+ argv = TclStackAlloc(interp, (argc + 1) * sizeof(char *));
/*
* Copy the string conversions of each (post option) object into the
diff --git a/generic/tclIORChan.c b/generic/tclIORChan.c
index 611ee3f..be82b48 100644
--- a/generic/tclIORChan.c
+++ b/generic/tclIORChan.c
@@ -1326,7 +1326,7 @@ ReflectInput(
*errorCodePtr = EOK;
if (bytec > 0) {
- memcpy(buf, bytev, (size_t) bytec);
+ memcpy(buf, bytev, bytec);
}
stop:
@@ -3008,7 +3008,7 @@ ForwardProc(
paramPtr->input.toRead = -1;
} else {
if (bytec > 0) {
- memcpy(paramPtr->input.buf, bytev, (size_t) bytec);
+ memcpy(paramPtr->input.buf, bytev, bytec);
}
paramPtr->input.toRead = bytec;
}
@@ -3298,7 +3298,7 @@ ForwardSetObjError(
len++;
ForwardSetDynamicError(paramPtr, ckalloc(len));
- memcpy(paramPtr->base.msgStr, msgStr, (unsigned) len);
+ memcpy(paramPtr->base.msgStr, msgStr, len);
}
#endif
diff --git a/generic/tclIORTrans.c b/generic/tclIORTrans.c
index 4841e39..8e24cf7 100644
--- a/generic/tclIORTrans.c
+++ b/generic/tclIORTrans.c
@@ -2607,7 +2607,7 @@ ForwardProc(
if (bytec > 0) {
paramPtr->transform.buf = ckalloc(bytec);
- memcpy(paramPtr->transform.buf, bytev, (size_t)bytec);
+ memcpy(paramPtr->transform.buf, bytev, bytec);
} else {
paramPtr->transform.buf = NULL;
}
@@ -2641,7 +2641,7 @@ ForwardProc(
if (bytec > 0) {
paramPtr->transform.buf = ckalloc(bytec);
- memcpy(paramPtr->transform.buf, bytev, (size_t)bytec);
+ memcpy(paramPtr->transform.buf, bytev, bytec);
} else {
paramPtr->transform.buf = NULL;
}
@@ -2670,7 +2670,7 @@ ForwardProc(
if (bytec > 0) {
paramPtr->transform.buf = ckalloc(bytec);
- memcpy(paramPtr->transform.buf, bytev, (size_t)bytec);
+ memcpy(paramPtr->transform.buf, bytev, bytec);
} else {
paramPtr->transform.buf = NULL;
}
@@ -2697,7 +2697,7 @@ ForwardProc(
if (bytec > 0) {
paramPtr->transform.buf = ckalloc(bytec);
- memcpy(paramPtr->transform.buf, bytev, (size_t)bytec);
+ memcpy(paramPtr->transform.buf, bytev, bytec);
} else {
paramPtr->transform.buf = NULL;
}
@@ -2810,7 +2810,7 @@ ForwardSetObjError(
len++;
ForwardSetDynamicError(paramPtr, ckalloc(len));
- memcpy(paramPtr->base.msgStr, msgStr, (unsigned) len);
+ memcpy(paramPtr->base.msgStr, msgStr, len);
}
#endif /* TCL_THREADS */
diff --git a/generic/tclIOUtil.c b/generic/tclIOUtil.c
index 63d16be..4b3eaa5 100644
--- a/generic/tclIOUtil.c
+++ b/generic/tclIOUtil.c
@@ -4699,7 +4699,7 @@ Tcl_FSGetFileSystemForPath(
* Tcl_FSGetNativePath --
*
* This function is for use by the Win/Unix native filesystems, so that
- * they can easily retrieve the native (char* or TCHAR*) representation
+ * they can easily retrieve the native (char* or WCHAR*) representation
* of a path. Other filesystems will probably want to implement similar
* functions. They basically act as a safety net around
* Tcl_FSGetInternalRep. Normally your file-system functions will always
diff --git a/generic/tclIndexObj.c b/generic/tclIndexObj.c
index 965ec24..919db92 100644
--- a/generic/tclIndexObj.c
+++ b/generic/tclIndexObj.c
@@ -978,8 +978,7 @@ Tcl_WrongNumArgs(
len = TclScanElement(elementStr, elemLen, &flags);
if (MAY_QUOTE_WORD && len != elemLen) {
- char *quotedElementStr = TclStackAlloc(interp,
- (unsigned)len + 1);
+ char *quotedElementStr = TclStackAlloc(interp, len + 1);
len = TclConvertElement(elementStr, elemLen,
quotedElementStr, flags);
@@ -1030,8 +1029,7 @@ Tcl_WrongNumArgs(
len = TclScanElement(elementStr, elemLen, &flags);
if (MAY_QUOTE_WORD && len != elemLen) {
- char *quotedElementStr = TclStackAlloc(interp,
- (unsigned) len + 1);
+ char *quotedElementStr = TclStackAlloc(interp, len + 1);
len = TclConvertElement(elementStr, elemLen,
quotedElementStr, flags);
@@ -1464,7 +1462,7 @@ TclGetCompletionCodeFromObj(
"ok", "error", "return", "break", "continue", NULL
};
- if ((value->typePtr != &indexType)
+ if (!TclHasIntRep(value, &indexType)
&& TclGetIntFromObj(NULL, value, codePtr) == TCL_OK) {
return TCL_OK;
}
diff --git a/generic/tclInt.h b/generic/tclInt.h
index fb6fe1a..c98aeed 100644
--- a/generic/tclInt.h
+++ b/generic/tclInt.h
@@ -2748,7 +2748,6 @@ MODULE_SCOPE ClientData tclTimeClientData;
MODULE_SCOPE const Tcl_ObjType tclBignumType;
MODULE_SCOPE const Tcl_ObjType tclBooleanType;
MODULE_SCOPE const Tcl_ObjType tclByteArrayType;
-MODULE_SCOPE const Tcl_ObjType tclPureByteArrayType;
MODULE_SCOPE const Tcl_ObjType tclByteCodeType;
MODULE_SCOPE const Tcl_ObjType tclDoubleType;
MODULE_SCOPE const Tcl_ObjType tclIntType;
@@ -2877,8 +2876,6 @@ struct Tcl_LoadHandle_ {
#define TCL_DD_SHORTEST 0x4
/* Use the shortest possible string */
-#define TCL_DD_STEELE 0x5
- /* Use the original Steele&White algorithm */
#define TCL_DD_E_FORMAT 0x2
/* Use a fixed-length string of digits,
* suitable for E format*/
@@ -2894,10 +2891,6 @@ struct Tcl_LoadHandle_ {
#define TCL_DD_CONVERSION_TYPE_MASK 0x3
/* Mask to isolate the conversion type */
-#define TCL_DD_STEELE0 0x1
- /* 'Steele&White' after masking */
-#define TCL_DD_SHORTEST0 0x0
- /* 'Shortest possible' after masking */
/*
*----------------------------------------------------------------
@@ -3067,7 +3060,6 @@ MODULE_SCOPE int TclInfoLocalsCmd(ClientData dummy, Tcl_Interp *interp,
MODULE_SCOPE int TclInfoVarsCmd(ClientData dummy, Tcl_Interp *interp,
int objc, Tcl_Obj *const objv[]);
MODULE_SCOPE void TclInitAlloc(void);
-MODULE_SCOPE void TclInitBignumFromLong(mp_int *, long);
MODULE_SCOPE void TclInitBignumFromWideInt(mp_int *, Tcl_WideInt);
MODULE_SCOPE void TclInitBignumFromWideUInt(mp_int *, Tcl_WideUInt);
MODULE_SCOPE void TclInitDbCkalloc(void);
@@ -3248,6 +3240,17 @@ MODULE_SCOPE const char*TclGetCommandTypeName(Tcl_Command command);
MODULE_SCOPE void TclRegisterCommandTypeName(
Tcl_ObjCmdProc *implementationProc,
const char *nameStr);
+#if (TCL_UTF_MAX > 4) && (defined(__CYGWIN__) || defined(_WIN32))
+MODULE_SCOPE int TclUtfToWChar(const char *src, WCHAR *chPtr);
+MODULE_SCOPE char * TclWCharToUtfDString(const WCHAR *uniStr,
+ int uniLength, Tcl_DString *dsPtr);
+MODULE_SCOPE WCHAR * TclUtfToWCharDString(const char *src,
+ int length, Tcl_DString *dsPtr);
+#else
+# define TclUtfToWChar TclUtfToUniChar
+# define TclWCharToUtfDString Tcl_UniCharToUtfDString
+# define TclUtfToWCharDString Tcl_UtfToUniCharDString
+#endif
MODULE_SCOPE int TclUtfCmp(const char *cs, const char *ct);
MODULE_SCOPE int TclUtfCasecmp(const char *cs, const char *ct);
MODULE_SCOPE int TclUtfCount(int ch);
@@ -3266,10 +3269,22 @@ MODULE_SCOPE int TclpLoadMemory(Tcl_Interp *interp, void *buffer,
MODULE_SCOPE void TclInitThreadStorage(void);
MODULE_SCOPE void TclFinalizeThreadDataThread(void);
MODULE_SCOPE void TclFinalizeThreadStorage(void);
+
#ifdef TCL_WIDE_CLICKS
MODULE_SCOPE Tcl_WideInt TclpGetWideClicks(void);
MODULE_SCOPE double TclpWideClicksToNanoseconds(Tcl_WideInt clicks);
+MODULE_SCOPE double TclpWideClickInMicrosec(void);
+#else
+# ifdef _WIN32
+# define TCL_WIDE_CLICKS 1
+MODULE_SCOPE Tcl_WideInt TclpGetWideClicks(void);
+MODULE_SCOPE double TclpWideClickInMicrosec(void);
+# define TclpWideClicksToNanoseconds(clicks) \
+ ((double)(clicks) * TclpWideClickInMicrosec() * 1000)
+# endif
#endif
+MODULE_SCOPE Tcl_WideInt TclpGetMicroseconds(void);
+
MODULE_SCOPE int TclZlibInit(Tcl_Interp *interp);
MODULE_SCOPE void * TclpThreadCreateKey(void);
MODULE_SCOPE void TclpThreadDeleteKey(void *keyPtr);
@@ -3545,6 +3560,9 @@ MODULE_SCOPE int Tcl_ThrowObjCmd(ClientData dummy, Tcl_Interp *interp,
MODULE_SCOPE int Tcl_TimeObjCmd(ClientData clientData,
Tcl_Interp *interp, int objc,
Tcl_Obj *const objv[]);
+MODULE_SCOPE int Tcl_TimeRateObjCmd(ClientData clientData,
+ Tcl_Interp *interp, int objc,
+ Tcl_Obj *const objv[]);
MODULE_SCOPE int Tcl_TraceObjCmd(ClientData clientData,
Tcl_Interp *interp, int objc,
Tcl_Obj *const objv[]);
@@ -4424,8 +4442,8 @@ MODULE_SCOPE void TclDbInitNewObj(Tcl_Obj *objPtr, const char *file,
(objPtr)->bytes = &tclEmptyString; \
(objPtr)->length = 0; \
} else { \
- (objPtr)->bytes = (char *) ckalloc((unsigned) ((len) + 1)); \
- memcpy((objPtr)->bytes, (bytePtr) ? (bytePtr) : &tclEmptyString, (unsigned) (len)); \
+ (objPtr)->bytes = (char *) ckalloc((len) + 1); \
+ memcpy((objPtr)->bytes, (bytePtr) ? (bytePtr) : &tclEmptyString, (len)); \
(objPtr)->bytes[len] = '\0'; \
(objPtr)->length = (len); \
}
@@ -4545,19 +4563,19 @@ MODULE_SCOPE void TclDbInitNewObj(Tcl_Obj *objPtr, const char *file,
allocated = TCL_MAX_TOKENS; \
} \
newPtr = (Tcl_Token *) attemptckrealloc((char *) oldPtr, \
- (unsigned int) (allocated * sizeof(Tcl_Token))); \
+ allocated * sizeof(Tcl_Token)); \
if (newPtr == NULL) { \
allocated = _needed + (append) + TCL_MIN_TOKEN_GROWTH; \
if (allocated > TCL_MAX_TOKENS) { \
allocated = TCL_MAX_TOKENS; \
} \
newPtr = (Tcl_Token *) ckrealloc((char *) oldPtr, \
- (unsigned int) (allocated * sizeof(Tcl_Token))); \
+ allocated * sizeof(Tcl_Token)); \
} \
(available) = allocated; \
if (oldPtr == NULL) { \
memcpy(newPtr, staticPtr, \
- (size_t) ((used) * sizeof(Tcl_Token))); \
+ (used) * sizeof(Tcl_Token)); \
} \
(tokenPtr) = newPtr; \
} \
@@ -4624,12 +4642,13 @@ MODULE_SCOPE void TclDbInitNewObj(Tcl_Obj *objPtr, const char *file,
*----------------------------------------------------------------
*/
-#define TclIsPureByteArray(objPtr) \
- ((objPtr)->typePtr==&tclPureByteArrayType)
+MODULE_SCOPE int TclIsPureByteArray(Tcl_Obj *objPtr);
#define TclIsPureDict(objPtr) \
(((objPtr)->bytes==NULL) && ((objPtr)->typePtr==&tclDictType))
+#define TclHasIntRep(objPtr, type) \
+ ((objPtr)->typePtr == (type))
#define TclFetchIntRep(objPtr, type) \
- (((objPtr)->typePtr == type) ? &((objPtr)->internalRep) : NULL)
+ (TclHasIntRep((objPtr), (type)) ? &((objPtr)->internalRep) : NULL)
/*
diff --git a/generic/tclInterp.c b/generic/tclInterp.c
index 1863ea5..92c6159 100644
--- a/generic/tclInterp.c
+++ b/generic/tclInterp.c
@@ -1831,8 +1831,8 @@ AliasNRCmd(
cmdv = &listRep->elements;
prefv = &aliasPtr->objPtr;
- memcpy(cmdv, prefv, (size_t) (prefc * sizeof(Tcl_Obj *)));
- memcpy(cmdv+prefc, objv+1, (size_t) ((objc-1) * sizeof(Tcl_Obj *)));
+ memcpy(cmdv, prefv, prefc * sizeof(Tcl_Obj *));
+ memcpy(cmdv+prefc, objv+1, (objc-1) * sizeof(Tcl_Obj *));
for (i=0; i<cmdc; i++) {
Tcl_IncrRefCount(cmdv[i]);
@@ -1880,8 +1880,8 @@ TclAliasObjCmd(
cmdv = TclStackAlloc(interp, cmdc * sizeof(Tcl_Obj *));
}
- memcpy(cmdv, prefv, (size_t) (prefc * sizeof(Tcl_Obj *)));
- memcpy(cmdv+prefc, objv+1, (size_t) ((objc-1) * sizeof(Tcl_Obj *)));
+ memcpy(cmdv, prefv, prefc * sizeof(Tcl_Obj *));
+ memcpy(cmdv+prefc, objv+1, (objc-1) * sizeof(Tcl_Obj *));
Tcl_ResetResult(targetInterp);
@@ -1970,8 +1970,8 @@ TclLocalAliasObjCmd(
cmdv = TclStackAlloc(interp, cmdc * sizeof(Tcl_Obj *));
}
- memcpy(cmdv, prefv, (size_t) (prefc * sizeof(Tcl_Obj *)));
- memcpy(cmdv+prefc, objv+1, (size_t) ((objc-1) * sizeof(Tcl_Obj *)));
+ memcpy(cmdv, prefv, prefc * sizeof(Tcl_Obj *));
+ memcpy(cmdv+prefc, objv+1, (objc-1) * sizeof(Tcl_Obj *));
for (i=0; i<cmdc; i++) {
Tcl_IncrRefCount(cmdv[i]);
diff --git a/generic/tclLink.c b/generic/tclLink.c
index eb4155a..e7dcb8c 100644
--- a/generic/tclLink.c
+++ b/generic/tclLink.c
@@ -735,7 +735,7 @@ GetInvalidDoubleFromObj(Tcl_Obj *objPtr, double *doublePtr)
{
int intValue;
- if (objPtr->typePtr == &invalidRealType) {
+ if (TclHasIntRep(objPtr, &invalidRealType)) {
goto gotdouble;
}
if (GetInvalidIntFromObj(objPtr, &intValue) == TCL_OK) {
diff --git a/generic/tclListObj.c b/generic/tclListObj.c
index 7a90950..0180920 100644
--- a/generic/tclListObj.c
+++ b/generic/tclListObj.c
@@ -786,7 +786,7 @@ Tcl_ListObjAppendElement(
* Old intrep to be freed, re-use refCounts.
*/
- memcpy(dst, src, (size_t) numElems * sizeof(Tcl_Obj *));
+ memcpy(dst, src, numElems * sizeof(Tcl_Obj *));
ckfree(listRepPtr);
}
listRepPtr = newPtr;
@@ -1164,7 +1164,7 @@ Tcl_ListObjReplace(
*/
if (first > 0) {
- memcpy(elemPtrs, oldPtrs, (size_t) first * sizeof(Tcl_Obj *));
+ memcpy(elemPtrs, oldPtrs, first * sizeof(Tcl_Obj *));
}
/*
@@ -1997,7 +1997,7 @@ SetListFromAny(
* describe duplicate keys).
*/
- if (!TclHasStringRep(objPtr) && (objPtr->typePtr == &tclDictType)) {
+ if (!TclHasStringRep(objPtr) && TclHasIntRep(objPtr, &tclDictType)) {
Tcl_Obj *keyPtr, *valuePtr;
Tcl_DictSearch search;
int done, size;
diff --git a/generic/tclLiteral.c b/generic/tclLiteral.c
index 577c9e5..464f565 100644
--- a/generic/tclLiteral.c
+++ b/generic/tclLiteral.c
@@ -213,7 +213,7 @@ TclCreateLiteral(
if ((objLength == length) && ((length == 0)
|| ((objBytes[0] == bytes[0])
- && (memcmp(objBytes, bytes, (unsigned) length) == 0)))) {
+ && (memcmp(objBytes, bytes, length) == 0)))) {
/*
* A literal was found: return it
*/
@@ -424,7 +424,7 @@ TclRegisterLiteral(
objPtr = localPtr->objPtr;
if ((objPtr->length == length) && ((length == 0)
|| ((objPtr->bytes[0] == bytes[0])
- && (memcmp(objPtr->bytes, bytes, (unsigned) length) == 0)))) {
+ && (memcmp(objPtr->bytes, bytes, length) == 0)))) {
if ((flags & LITERAL_ON_HEAP)) {
ckfree(bytes);
}
@@ -1057,7 +1057,7 @@ TclInvalidateCmdLiteral(
strlen(name), -1, NULL, nsPtr, 0, NULL);
if (literalObjPtr != NULL) {
- if (literalObjPtr->typePtr == &tclCmdNameType) {
+ if (TclHasIntRep(literalObjPtr, &tclCmdNameType)) {
TclFreeIntRep(literalObjPtr);
}
/* Balance the refcount effects of TclCreateLiteral() above */
diff --git a/generic/tclLoad.c b/generic/tclLoad.c
index 77e6425..add4f6f 100644
--- a/generic/tclLoad.c
+++ b/generic/tclLoad.c
@@ -405,7 +405,7 @@ Tcl_LoadObjCmd(
len = strlen(fullFileName) + 1;
pkgPtr->fileName = ckalloc(len);
memcpy(pkgPtr->fileName, fullFileName, len);
- len = (unsigned) Tcl_DStringLength(&pkgName) + 1;
+ len = Tcl_DStringLength(&pkgName) + 1;
pkgPtr->packageName = ckalloc(len);
memcpy(pkgPtr->packageName, Tcl_DStringValue(&pkgName), len);
pkgPtr->loadHandle = loadHandle;
diff --git a/generic/tclMain.c b/generic/tclMain.c
index 9380fb2..4b8fa8c 100644
--- a/generic/tclMain.c
+++ b/generic/tclMain.c
@@ -59,20 +59,27 @@
* encoding to UTF-8).
*/
-#ifdef UNICODE
+#if defined(UNICODE) && (TCL_UTF_MAX <= 4)
# define NewNativeObj Tcl_NewUnicodeObj
-#else /* !UNICODE */
+#else /* !UNICODE || (TCL_UTF_MAX > 4) */
static inline Tcl_Obj *
NewNativeObj(
- char *string,
+ TCHAR *string,
int length)
{
Tcl_DString ds;
- Tcl_ExternalToUtfDString(NULL, string, length, &ds);
+#ifdef UNICODE
+ if (length > 0) {
+ length *= sizeof(WCHAR);
+ }
+ Tcl_WinTCharToUtf(string, length, &ds);
+#else
+ Tcl_ExternalToUtfDString(NULL, (char *) string, length, &ds);
+#endif
return TclDStringToObj(&ds);
}
-#endif /* !UNICODE */
+#endif /* !UNICODE || (TCL_UTF_MAX > 4) */
/*
* Declarations for various library functions and variables (don't want to
diff --git a/generic/tclNamesp.c b/generic/tclNamesp.c
index de2222e..b553880 100644
--- a/generic/tclNamesp.c
+++ b/generic/tclNamesp.c
@@ -876,7 +876,7 @@ Tcl_CreateNamespace(
name = Tcl_DStringValue(namePtr);
nameLen = Tcl_DStringLength(namePtr);
nsPtr->fullName = ckalloc(nameLen + 1);
- memcpy(nsPtr->fullName, name, (unsigned) nameLen + 1);
+ memcpy(nsPtr->fullName, name, nameLen + 1);
Tcl_DStringFree(&buffer1);
Tcl_DStringFree(&buffer2);
@@ -1462,7 +1462,7 @@ Tcl_Export(
len = strlen(pattern);
patternCpy = ckalloc(len + 1);
- memcpy(patternCpy, pattern, (unsigned) len + 1);
+ memcpy(patternCpy, pattern, len + 1);
nsPtr->exportArrayPtr[nsPtr->numExportPatterns] = patternCpy;
nsPtr->numExportPatterns++;
diff --git a/generic/tclOOCall.c b/generic/tclOOCall.c
index 908dd26..ace7fd7 100644
--- a/generic/tclOOCall.c
+++ b/generic/tclOOCall.c
@@ -631,7 +631,7 @@ SortMethodNames(
if (i > 0) {
if (i > 1) {
- qsort((void *) strings, (unsigned) i, sizeof(char *), CmpStr);
+ qsort((void *) strings, i, sizeof(char *), CmpStr);
}
*stringsPtr = strings;
} else {
diff --git a/generic/tclObj.c b/generic/tclObj.c
index 3385c0d..f233038 100644
--- a/generic/tclObj.c
+++ b/generic/tclObj.c
@@ -3030,27 +3030,23 @@ Tcl_GetLongFromObj(
*/
mp_int big;
+ unsigned long scratch, value = 0, numBytes = sizeof(unsigned long);
+ unsigned char *bytes = (unsigned char *) &scratch;
UNPACK_BIGNUM(objPtr, big);
- if ((size_t) big.used <= (CHAR_BIT * sizeof(unsigned long) + DIGIT_BIT - 1)
- / DIGIT_BIT) {
- unsigned long scratch, value = 0, numBytes = sizeof(unsigned long);
- unsigned char *bytes = (unsigned char *) &scratch;
-
- if (mp_to_unsigned_bin_n(&big, bytes, &numBytes) == MP_OKAY) {
- while (numBytes-- > 0) {
+ if (mp_to_unsigned_bin_n(&big, bytes, &numBytes) == MP_OKAY) {
+ while (numBytes-- > 0) {
value = (value << CHAR_BIT) | *bytes++;
+ }
+ if (big.sign) {
+ if (value <= 1 + (unsigned long)LONG_MAX) {
+ *longPtr = - (long) value;
+ return TCL_OK;
}
- if (big.sign) {
- if (value <= 1 + (unsigned long)LONG_MAX) {
- *longPtr = - (long) value;
- return TCL_OK;
- }
- } else {
- if (value <= (unsigned long)ULONG_MAX) {
- *longPtr = (long) value;
- return TCL_OK;
- }
+ } else {
+ if (value <= (unsigned long)ULONG_MAX) {
+ *longPtr = (long) value;
+ return TCL_OK;
}
}
}
@@ -3272,29 +3268,25 @@ Tcl_GetWideIntFromObj(
*/
mp_int big;
+ Tcl_WideUInt value = 0;
+ unsigned long numBytes = sizeof(Tcl_WideInt);
+ Tcl_WideInt scratch;
+ unsigned char *bytes = (unsigned char *) &scratch;
UNPACK_BIGNUM(objPtr, big);
- if ((size_t) big.used <= (CHAR_BIT * sizeof(Tcl_WideInt)
- + DIGIT_BIT - 1) / DIGIT_BIT) {
- Tcl_WideUInt value = 0;
- unsigned long numBytes = sizeof(Tcl_WideInt);
- Tcl_WideInt scratch;
- unsigned char *bytes = (unsigned char *) &scratch;
-
- if (mp_to_unsigned_bin_n(&big, bytes, &numBytes) == MP_OKAY) {
- while (numBytes-- > 0) {
- value = (value << CHAR_BIT) | *bytes++;
+ if (mp_to_unsigned_bin_n(&big, bytes, &numBytes) == MP_OKAY) {
+ while (numBytes-- > 0) {
+ value = (value << CHAR_BIT) | *bytes++;
+ }
+ if (big.sign) {
+ if (value <= 1 + ~(Tcl_WideUInt)WIDE_MIN) {
+ *wideIntPtr = - (Tcl_WideInt) value;
+ return TCL_OK;
}
- if (big.sign) {
- if (value <= 1 + ~(Tcl_WideUInt)WIDE_MIN) {
- *wideIntPtr = - (Tcl_WideInt) value;
- return TCL_OK;
- }
- } else {
- if (value <= (Tcl_WideUInt)WIDE_MAX) {
- *wideIntPtr = (Tcl_WideInt) value;
- return TCL_OK;
- }
+ } else {
+ if (value <= (Tcl_WideUInt)WIDE_MAX) {
+ *wideIntPtr = (Tcl_WideInt) value;
+ return TCL_OK;
}
}
}
@@ -3731,33 +3723,30 @@ Tcl_SetBignumObj(
Tcl_Obj *objPtr, /* Object to set */
mp_int *bignumValue) /* Value to store */
{
+ Tcl_WideUInt value = 0;
+ unsigned long numBytes = sizeof(Tcl_WideUInt);
+ Tcl_WideUInt scratch;
+ unsigned char *bytes = (unsigned char *) &scratch;
+
if (Tcl_IsShared(objPtr)) {
Tcl_Panic("%s called with shared object", "Tcl_SetBignumObj");
}
- if ((size_t) bignumValue->used
- <= (CHAR_BIT * sizeof(Tcl_WideUInt) + DIGIT_BIT - 1) / DIGIT_BIT) {
- Tcl_WideUInt value = 0;
- unsigned long numBytes = sizeof(Tcl_WideUInt);
- Tcl_WideUInt scratch;
- unsigned char *bytes = (unsigned char *) &scratch;
-
- if (mp_to_unsigned_bin_n(bignumValue, bytes, &numBytes) != MP_OKAY) {
- goto tooLargeForWide;
- }
- while (numBytes-- > 0) {
- value = (value << CHAR_BIT) | *bytes++;
- }
- if (value > ((Tcl_WideUInt)WIDE_MAX + bignumValue->sign)) {
- goto tooLargeForWide;
- }
- if (bignumValue->sign) {
- TclSetIntObj(objPtr, -(Tcl_WideInt)value);
- } else {
- TclSetIntObj(objPtr, (Tcl_WideInt)value);
- }
- mp_clear(bignumValue);
- return;
+ if (mp_to_unsigned_bin_n(bignumValue, bytes, &numBytes) != MP_OKAY) {
+ goto tooLargeForWide;
+ }
+ while (numBytes-- > 0) {
+ value = (value << CHAR_BIT) | *bytes++;
+ }
+ if (value > ((Tcl_WideUInt)WIDE_MAX + bignumValue->sign)) {
+ goto tooLargeForWide;
+ }
+ if (bignumValue->sign) {
+ TclSetIntObj(objPtr, -(Tcl_WideInt)value);
+ } else {
+ TclSetIntObj(objPtr, (Tcl_WideInt)value);
}
+ mp_clear(bignumValue);
+ return;
tooLargeForWide:
TclInvalidateStringRep(objPtr);
TclFreeIntRep(objPtr);
diff --git a/generic/tclParse.c b/generic/tclParse.c
index ccb648c..164905a 100644
--- a/generic/tclParse.c
+++ b/generic/tclParse.c
@@ -791,7 +791,7 @@ TclParseBackslash(
Tcl_UniChar unichar = 0;
int result;
int count;
- char buf[TCL_UTF_MAX];
+ char buf[4] = "";
if (numBytes == 0) {
if (readPtr != NULL) {
@@ -926,7 +926,7 @@ TclParseBackslash(
} else {
char utfBytes[TCL_UTF_MAX];
- memcpy(utfBytes, p, (size_t) (numBytes - 1));
+ memcpy(utfBytes, p, numBytes - 1);
utfBytes[numBytes - 1] = '\0';
count = TclUtfToUniChar(utfBytes, &unichar) + 1;
}
@@ -939,9 +939,9 @@ TclParseBackslash(
*readPtr = count;
}
count = Tcl_UniCharToUtf(result, dst);
- if (!count) {
- /* Special case for handling upper surrogates. */
- count = Tcl_UniCharToUtf(-1, dst);
+ if ((result >= 0xD800) && (count < 3)) {
+ /* Special case for handling high surrogates. */
+ count += Tcl_UniCharToUtf(-1, dst + count);
}
return count;
}
@@ -2151,7 +2151,7 @@ TclSubstTokens(
Tcl_Obj *appendObj = NULL;
const char *append = NULL;
int appendByteLength = 0;
- char utfCharBytes[TCL_UTF_MAX];
+ char utfCharBytes[4] = "";
switch (tokenPtr->type) {
case TCL_TOKEN_TEXT:
diff --git a/generic/tclPathObj.c b/generic/tclPathObj.c
index 0532b98..3703aaf 100644
--- a/generic/tclPathObj.c
+++ b/generic/tclPathObj.c
@@ -560,9 +560,7 @@ TclPathPart(
Tcl_Obj *pathPtr, /* Path to take dirname of */
Tcl_PathPart portion) /* Requested portion of name */
{
- Tcl_ObjIntRep *irPtr = TclFetchIntRep(pathPtr, &fsPathType);
-
- if (irPtr) {
+ if (TclHasIntRep(pathPtr, &fsPathType)) {
FsPath *fsPathPtr = PATHOBJ(pathPtr);
if (PATHFLAGS(pathPtr) != 0) {
@@ -1158,8 +1156,6 @@ Tcl_FSConvertToPathType(
Tcl_Obj *pathPtr) /* Object to convert to a valid, current path
* type. */
{
- Tcl_ObjIntRep *irPtr = TclFetchIntRep(pathPtr, &fsPathType);
-
/*
* While it is bad practice to examine an object's type directly, this is
* actually the best thing to do here. The reason is that if we are
@@ -1170,7 +1166,7 @@ Tcl_FSConvertToPathType(
* path.
*/
- if (irPtr) {
+ if (TclHasIntRep(pathPtr, &fsPathType)) {
if (TclFSEpochOk(PATHOBJ(pathPtr)->filesystemEpoch)) {
return TCL_OK;
}
@@ -1481,9 +1477,8 @@ MakePathFromNormalized(
Tcl_Obj *pathPtr) /* The object to convert. */
{
FsPath *fsPathPtr;
- Tcl_ObjIntRep *irPtr = TclFetchIntRep(pathPtr, &fsPathType);
- if (irPtr) {
+ if (TclHasIntRep(pathPtr, &fsPathType)) {
return TCL_OK;
}
@@ -1684,7 +1679,7 @@ Tcl_FSGetTranslatedStringPath(
const char *orig = TclGetStringFromObj(transPtr, &len);
char *result = ckalloc(len+1);
- memcpy(result, orig, (size_t) len+1);
+ memcpy(result, orig, len+1);
TclDecrRefCount(transPtr);
return result;
}
@@ -2087,9 +2082,8 @@ TclFSEnsureEpochOk(
const Tcl_Filesystem **fsPtrPtr)
{
FsPath *srcFsPathPtr;
- Tcl_ObjIntRep *irPtr = TclFetchIntRep(pathPtr, &fsPathType);
- if (irPtr == NULL) {
+ if (!TclHasIntRep(pathPtr, &fsPathType)) {
return TCL_OK;
}
@@ -2146,13 +2140,12 @@ TclFSSetPathDetails(
ClientData clientData)
{
FsPath *srcFsPathPtr;
- Tcl_ObjIntRep *irPtr = TclFetchIntRep(pathPtr, &fsPathType);;
/*
* Make sure pathPtr is of the correct type.
*/
- if (irPtr == NULL) {
+ if (!TclHasIntRep(pathPtr, &fsPathType)) {
if (SetFsPathFromAny(NULL, pathPtr) != TCL_OK) {
return;
}
@@ -2250,9 +2243,8 @@ SetFsPathFromAny(
FsPath *fsPathPtr;
Tcl_Obj *transPtr;
char *name;
- Tcl_ObjIntRep *irPtr = TclFetchIntRep(pathPtr, &fsPathType);
- if (irPtr) {
+ if (TclHasIntRep(pathPtr, &fsPathType)) {
return TCL_OK;
}
@@ -2558,8 +2550,6 @@ TclNativePathInFilesystem(
Tcl_Obj *pathPtr,
ClientData *clientDataPtr)
{
- Tcl_ObjIntRep *irPtr = TclFetchIntRep(pathPtr, &fsPathType);
-
/*
* A special case is required to handle the empty path "". This is a valid
* path (i.e. the user should be able to do 'file exists ""' without
@@ -2567,7 +2557,7 @@ TclNativePathInFilesystem(
* semantics of Tcl (at present anyway), so we have to abide by them here.
*/
- if (irPtr) {
+ if (TclHasIntRep(pathPtr, &fsPathType)) {
if (pathPtr->bytes != NULL && pathPtr->bytes[0] == '\0') {
/*
* We reject the empty path "".
diff --git a/generic/tclPipe.c b/generic/tclPipe.c
index f94fe5c..63fd2fa 100644
--- a/generic/tclPipe.c
+++ b/generic/tclPipe.c
@@ -333,7 +333,7 @@ TclCleanupChildren(
int count;
Tcl_Obj *objPtr;
- Tcl_Seek(errorChan, (Tcl_WideInt)0, SEEK_SET);
+ Tcl_Seek(errorChan, 0, SEEK_SET);
objPtr = Tcl_NewObj();
count = Tcl_ReadChars(errorChan, objPtr, -1, 0);
if (count < 0) {
diff --git a/generic/tclPkg.c b/generic/tclPkg.c
index 2c16458..95524a7 100644
--- a/generic/tclPkg.c
+++ b/generic/tclPkg.c
@@ -56,10 +56,7 @@ typedef struct PkgFiles {
*/
typedef struct Package {
- char *version; /* Version that has been supplied in this
- * interpreter via "package provide"
- * (malloc'ed). NULL means the package doesn't
- * exist in this interpreter yet. */
+ Tcl_Obj *version;
PkgAvail *availPtr; /* First in list of all available versions of
* this package. */
const void *clientData; /* Client data. */
@@ -166,12 +163,13 @@ Tcl_PkgProvideEx(
pkgPtr = FindPackage(interp, name);
if (pkgPtr->version == NULL) {
- DupString(pkgPtr->version, version);
+ pkgPtr->version = Tcl_NewStringObj(version, -1);
+ Tcl_IncrRefCount(pkgPtr->version);
pkgPtr->clientData = clientData;
return TCL_OK;
}
- if (CheckVersionAndConvert(interp, pkgPtr->version, &pvi,
+ if (CheckVersionAndConvert(interp, Tcl_GetString(pkgPtr->version), &pvi,
NULL) != TCL_OK) {
return TCL_ERROR;
} else if (CheckVersionAndConvert(interp, version, &vi, NULL) != TCL_OK) {
@@ -191,7 +189,7 @@ Tcl_PkgProvideEx(
}
Tcl_SetObjResult(interp, Tcl_ObjPrintf(
"conflicting versions provided for package \"%s\": %s, then %s",
- name, pkgPtr->version, version));
+ name, Tcl_GetString(pkgPtr->version), version));
Tcl_SetErrorCode(interp, "TCL", "PACKAGE", "VERSIONCONFLICT", NULL);
return TCL_ERROR;
}
@@ -384,7 +382,7 @@ Tcl_PkgRequireEx(
if (version == NULL) {
if (Tcl_PkgRequireProc(interp, name, 0, NULL, clientDataPtr) == TCL_OK) {
- result = Tcl_GetStringResult(interp);
+ result = Tcl_GetString(Tcl_GetObjResult(interp));
Tcl_ResetResult(interp);
}
} else {
@@ -398,7 +396,7 @@ Tcl_PkgRequireEx(
}
Tcl_IncrRefCount(ov);
if (Tcl_PkgRequireProc(interp, name, 1, &ov, clientDataPtr) == TCL_OK) {
- result = Tcl_GetStringResult(interp);
+ result = Tcl_GetString(Tcl_GetObjResult(interp));
Tcl_ResetResult(interp);
}
TclDecrRefCount(ov);
@@ -540,7 +538,8 @@ PkgRequireCoreFinal(ClientData data[], Tcl_Interp *interp, int result) {
*/
if (reqc != 0) {
- CheckVersionAndConvert(interp, reqPtr->pkgPtr->version, &pkgVersionI, NULL);
+ CheckVersionAndConvert(interp, Tcl_GetString(reqPtr->pkgPtr->version),
+ &pkgVersionI, NULL);
satisfies = SomeRequirementSatisfied(pkgVersionI, reqc, reqv);
ckfree(pkgVersionI);
@@ -548,7 +547,7 @@ PkgRequireCoreFinal(ClientData data[], Tcl_Interp *interp, int result) {
if (!satisfies) {
Tcl_SetObjResult(interp, Tcl_ObjPrintf(
"version conflict for package \"%s\": have %s, need",
- name, reqPtr->pkgPtr->version));
+ name, Tcl_GetString(reqPtr->pkgPtr->version)));
Tcl_SetErrorCode(interp, "TCL", "PACKAGE", "VERSIONCONFLICT",
NULL);
AddRequirementsToResult(interp, reqc, reqv);
@@ -561,7 +560,7 @@ PkgRequireCoreFinal(ClientData data[], Tcl_Interp *interp, int result) {
*ptr = reqPtr->pkgPtr->clientData;
}
- Tcl_SetObjResult(interp, Tcl_NewStringObj(reqPtr->pkgPtr->version, -1));
+ Tcl_SetObjResult(interp, reqPtr->pkgPtr->version);
return TCL_OK;
}
@@ -778,8 +777,8 @@ SelectPackageFinal(ClientData data[], Tcl_Interp *interp, int result) {
} else {
char *pvi, *vi;
- if (CheckVersionAndConvert(interp, reqPtr->pkgPtr->version, &pvi,
- NULL) != TCL_OK) {
+ if (TCL_OK != CheckVersionAndConvert(interp,
+ Tcl_GetString(reqPtr->pkgPtr->version), &pvi, NULL)) {
result = TCL_ERROR;
} else if (CheckVersionAndConvert(interp,
versionToProvide, &vi, NULL) != TCL_OK) {
@@ -796,7 +795,7 @@ SelectPackageFinal(ClientData data[], Tcl_Interp *interp, int result) {
"attempt to provide package %s %s failed:"
" package %s %s provided instead",
name, versionToProvide,
- name, reqPtr->pkgPtr->version));
+ name, Tcl_GetString(reqPtr->pkgPtr->version)));
Tcl_SetErrorCode(interp, "TCL", "PACKAGE",
"WRONGPROVIDE", NULL);
}
@@ -834,7 +833,7 @@ SelectPackageFinal(ClientData data[], Tcl_Interp *interp, int result) {
*/
if (reqPtr->pkgPtr->version != NULL) {
- ckfree(reqPtr->pkgPtr->version);
+ Tcl_DecrRefCount(reqPtr->pkgPtr->version);
reqPtr->pkgPtr->version = NULL;
}
reqPtr->pkgPtr->clientData = NULL;
@@ -1036,7 +1035,7 @@ TclNRPackageObjCmd(
pkgPtr = Tcl_GetHashValue(hPtr);
Tcl_DeleteHashEntry(hPtr);
if (pkgPtr->version != NULL) {
- ckfree(pkgPtr->version);
+ Tcl_DecrRefCount(pkgPtr->version);
}
while (pkgPtr->availPtr != NULL) {
availPtr = pkgPtr->availPtr;
@@ -1112,7 +1111,7 @@ TclNRPackageObjCmd(
if (availPtr == NULL) {
availPtr = ckalloc(sizeof(PkgAvail));
availPtr->pkgIndex = NULL;
- DupBlock(availPtr->version, argv3, (unsigned) length + 1);
+ DupBlock(availPtr->version, argv3, length + 1);
if (prevPtr == NULL) {
availPtr->nextPtr = pkgPtr->availPtr;
@@ -1124,10 +1123,10 @@ TclNRPackageObjCmd(
}
if (iPtr->scriptFile) {
argv4 = TclGetStringFromObj(iPtr->scriptFile, &length);
- DupBlock(availPtr->pkgIndex, argv4, (unsigned) length + 1);
+ DupBlock(availPtr->pkgIndex, argv4, length + 1);
}
argv4 = TclGetStringFromObj(objv[4], &length);
- DupBlock(availPtr->script, argv4, (unsigned) length + 1);
+ DupBlock(availPtr->script, argv4, length + 1);
break;
}
case PKG_NAMES:
@@ -1207,8 +1206,7 @@ TclNRPackageObjCmd(
if (hPtr != NULL) {
pkgPtr = Tcl_GetHashValue(hPtr);
if (pkgPtr->version != NULL) {
- Tcl_SetObjResult(interp,
- Tcl_NewStringObj(pkgPtr->version, -1));
+ Tcl_SetObjResult(interp, pkgPtr->version);
}
}
return TCL_OK;
@@ -1301,7 +1299,7 @@ TclNRPackageObjCmd(
if (argv2[0] == 0) {
iPtr->packageUnknown = NULL;
} else {
- DupBlock(iPtr->packageUnknown, argv2, (unsigned) length+1);
+ DupBlock(iPtr->packageUnknown, argv2, length+1);
}
} else {
Tcl_WrongNumArgs(interp, 2, objv, "?command?");
@@ -1501,7 +1499,7 @@ TclFreePackageInfo(
hPtr != NULL; hPtr = Tcl_NextHashEntry(&search)) {
pkgPtr = Tcl_GetHashValue(hPtr);
if (pkgPtr->version != NULL) {
- ckfree(pkgPtr->version);
+ Tcl_DecrRefCount(pkgPtr->version);
}
while (pkgPtr->availPtr != NULL) {
availPtr = pkgPtr->availPtr;
diff --git a/generic/tclProc.c b/generic/tclProc.c
index b44e54d..f24dae8 100644
--- a/generic/tclProc.c
+++ b/generic/tclProc.c
@@ -329,7 +329,7 @@ Tcl_ProcObjCmd(
* of all procs whose argument list is just _args_
*/
- if (TclFetchIntRep(objv[3], &tclProcBodyType)) {
+ if (TclHasIntRep(objv[3], &tclProcBodyType)) {
goto done;
}
diff --git a/generic/tclProcess.c b/generic/tclProcess.c
index a781386..2f3f4ba 100644
--- a/generic/tclProcess.c
+++ b/generic/tclProcess.c
@@ -540,7 +540,7 @@ ProcessStatusObjCmd(
dict = Tcl_NewDictObj();
Tcl_MutexLock(&infoTablesMutex);
for (i = 0; i < numPids; i++) {
- result = Tcl_GetIntFromObj(interp, pidObjs[i], (int *) &pid);
+ result = Tcl_GetIntFromObj(interp, pidObjs[i], &pid);
if (result != TCL_OK) {
Tcl_MutexUnlock(&infoTablesMutex);
Tcl_DecrRefCount(dict);
@@ -654,7 +654,7 @@ ProcessPurgeObjCmd(
}
Tcl_MutexLock(&infoTablesMutex);
for (i = 0; i < numPids; i++) {
- result = Tcl_GetIntFromObj(interp, pidObjs[i], (int *) &pid);
+ result = Tcl_GetIntFromObj(interp, pidObjs[i], &pid);
if (result != TCL_OK) {
Tcl_MutexUnlock(&infoTablesMutex);
return result;
diff --git a/generic/tclRegexp.c b/generic/tclRegexp.c
index ce53ced..804b117 100644
--- a/generic/tclRegexp.c
+++ b/generic/tclRegexp.c
@@ -998,7 +998,7 @@ CompileRegexp(
tsdPtr->regexps[i+1] = tsdPtr->regexps[i];
}
tsdPtr->patterns[0] = ckalloc(length + 1);
- memcpy(tsdPtr->patterns[0], string, (unsigned) length + 1);
+ memcpy(tsdPtr->patterns[0], string, length + 1);
tsdPtr->patLengths[0] = length;
tsdPtr->regexps[0] = regexpPtr;
diff --git a/generic/tclResult.c b/generic/tclResult.c
index a5ec4be..5a03421 100644
--- a/generic/tclResult.c
+++ b/generic/tclResult.c
@@ -438,7 +438,7 @@ Tcl_SetResult(
iPtr->result = iPtr->resultSpace;
iPtr->freeProc = 0;
}
- memcpy(iPtr->result, result, (unsigned) length+1);
+ memcpy(iPtr->result, result, length+1);
} else {
iPtr->result = (char *) result;
iPtr->freeProc = freeProc;
diff --git a/generic/tclScan.c b/generic/tclScan.c
index fbfba2d..74ec2da 100644
--- a/generic/tclScan.c
+++ b/generic/tclScan.c
@@ -261,7 +261,7 @@ ValidateFormat(
Tcl_UniChar ch = 0;
int objIndex, xpgSize, nspace = numVars;
int *nassign = TclStackAlloc(interp, nspace * sizeof(int));
- char buf[TCL_UTF_MAX+1];
+ char buf[TCL_UTF_MAX + 1] = "";
Tcl_Obj *errorMsg; /* Place to build an error messages. Note that
* these are messy operations because we do
* not want to use the formatting engine;
@@ -881,9 +881,9 @@ Tcl_ScanObjCmd(
offset = TclUtfToUniChar(string, &sch);
i = (int)sch;
-#if TCL_UTF_MAX == 4
- if (!offset) {
- offset = TclUtfToUniChar(string, &sch);
+#if TCL_UTF_MAX <= 4
+ if ((sch >= 0xD800) && (offset < 3)) {
+ offset += TclUtfToUniChar(string+offset, &sch);
i = (((i<<10) & 0x0FFC00) + 0x10000) + (sch & 0x3FF);
}
#endif
@@ -943,7 +943,7 @@ Tcl_ScanObjCmd(
int code = Tcl_GetBignumFromObj(interp, objPtr, &big);
if (code == TCL_OK) {
- if (mp_isneg(&big)) {
+ if (big.sign != MP_ZPOS) {
code = TCL_ERROR;
}
mp_clear(&big);
diff --git a/generic/tclStrToD.c b/generic/tclStrToD.c
index a46b29a..e7cb2c5 100644
--- a/generic/tclStrToD.c
+++ b/generic/tclStrToD.c
@@ -320,36 +320,36 @@ static char * StrictQuickFormat(double, int, int, double,
static char * QuickConversion(double, int, int, int, int, int, int,
int *, char **);
static void CastOutPowersOf2(int *, int *, int *);
-static char * ShorteningInt64Conversion(Double *, int, Tcl_WideUInt,
+static char * ShorteningInt64Conversion(Double *, Tcl_WideUInt,
int, int, int, int, int, int, int, int, int,
int, int, int *, char **);
-static char * StrictInt64Conversion(Double *, int, Tcl_WideUInt,
+static char * StrictInt64Conversion(Double *, Tcl_WideUInt,
int, int, int, int, int, int,
int, int, int *, char **);
static int ShouldBankerRoundUpPowD(mp_int *, int, int);
static int ShouldBankerRoundUpToNextPowD(mp_int *, mp_int *,
- int, int, int, mp_int *);
+ int, int, mp_int *);
static char * ShorteningBignumConversionPowD(Double *dPtr,
- int convType, Tcl_WideUInt bw, int b2, int b5,
+ Tcl_WideUInt bw, int b2, int b5,
int m2plus, int m2minus, int m5,
int sd, int k, int len,
int ilim, int ilim1, int *decpt,
char **endPtr);
-static char * StrictBignumConversionPowD(Double *dPtr, int convType,
+static char * StrictBignumConversionPowD(Double *dPtr,
Tcl_WideUInt bw, int b2, int b5,
int sd, int k, int len,
int ilim, int ilim1, int *decpt,
char **endPtr);
static int ShouldBankerRoundUp(mp_int *, mp_int *, int);
static int ShouldBankerRoundUpToNext(mp_int *, mp_int *,
- mp_int *, int, int, mp_int *);
-static char * ShorteningBignumConversion(Double *dPtr, int convType,
+ mp_int *, int);
+static char * ShorteningBignumConversion(Double *dPtr,
Tcl_WideUInt bw, int b2,
int m2plus, int m2minus,
int s2, int s5, int k, int len,
int ilim, int ilim1, int *decpt,
char **endPtr);
-static char * StrictBignumConversion(Double *dPtr, int convType,
+static char * StrictBignumConversion(Double *dPtr,
Tcl_WideUInt bw, int b2,
int s2, int s5, int k, int len,
int ilim, int ilim1, int *decpt,
@@ -530,7 +530,7 @@ TclParseNumber(
int shift = 0; /* Amount to shift when accumulating binary */
int explicitOctal = 0;
-#define ALL_BITS (~(Tcl_WideUInt)0)
+#define ALL_BITS ((Tcl_WideUInt)-1)
#define MOST_BITS (ALL_BITS >> 1)
/*
@@ -540,11 +540,11 @@ TclParseNumber(
if (bytes == NULL) {
if (interp == NULL && endPtrPtr == NULL) {
- if (objPtr->typePtr == &tclDictType) {
+ if (TclHasIntRep(objPtr, &tclDictType)) {
/* A dict can never be a (single) number */
return TCL_ERROR;
}
- if (objPtr->typePtr == &tclListType) {
+ if (TclHasIntRep(objPtr, &tclListType)) {
int length;
/* A list can only be a (single) number if its length == 1 */
TclListObjLength(NULL, objPtr, &length);
@@ -709,7 +709,7 @@ TclParseNumber(
&& (((size_t)shift >=
CHAR_BIT*sizeof(Tcl_WideUInt))
|| (octalSignificandWide >
- (~(Tcl_WideUInt)0 >> shift)))) {
+ ((Tcl_WideUInt)-1 >> shift)))) {
octalSignificandOverflow = 1;
TclInitBignumFromWideUInt(&octalSignificandBig,
octalSignificandWide);
@@ -826,7 +826,7 @@ TclParseNumber(
if (significandWide != 0 &&
((size_t)shift >= CHAR_BIT*sizeof(Tcl_WideUInt) ||
- significandWide > (~(Tcl_WideUInt)0 >> shift))) {
+ significandWide > ((Tcl_WideUInt)-1 >> shift))) {
significandOverflow = 1;
TclInitBignumFromWideUInt(&significandBig,
significandWide);
@@ -867,7 +867,7 @@ TclParseNumber(
if (significandWide != 0 &&
((size_t)shift >= CHAR_BIT*sizeof(Tcl_WideUInt) ||
- significandWide > (~(Tcl_WideUInt)0 >> shift))) {
+ significandWide > ((Tcl_WideUInt)-1 >> shift))) {
significandOverflow = 1;
TclInitBignumFromWideUInt(&significandBig,
significandWide);
@@ -1451,7 +1451,7 @@ AccumulateDecimalDigit(
*wideRepPtr = digit;
return 0;
} else if (numZeros >= maxpow10_wide
- || w > ((~(Tcl_WideUInt)0)-digit)/pow10_wide[numZeros+1]) {
+ || w > ((Tcl_WideUInt)-1-digit)/pow10_wide[numZeros+1]) {
/*
* Wide multiplication will overflow. Expand the number to a
* bignum and fall through into the bignum case.
@@ -2410,9 +2410,8 @@ ComputeScale(
static inline void
SetPrecisionLimits(
- int convType, /* Type of conversion: TCL_DD_SHORTEST,
- * TCL_DD_STEELE0, TCL_DD_E_FMT,
- * TCL_DD_F_FMT. */
+ int flags, /* Type of conversion: TCL_DD_SHORTEST,
+ * TCL_DD_E_FMT, TCL_DD_F_FMT. */
int k, /* Floor(log10(number to convert)) */
int *ndigitsPtr, /* IN/OUT: Number of digits requested (will be
* adjusted if needed). */
@@ -2422,13 +2421,7 @@ SetPrecisionLimits(
int *iLim1Ptr) /* OUT: Number of digits of significance if
* the quick method is used. */
{
- switch (convType) {
- case TCL_DD_SHORTEST0:
- case TCL_DD_STEELE0:
- *iLimPtr = *iLim1Ptr = -1;
- *iPtr = 18;
- *ndigitsPtr = 0;
- break;
+ switch (flags & TCL_DD_CONVERSION_TYPE_MASK) {
case TCL_DD_E_FORMAT:
if (*ndigitsPtr <= 0) {
*ndigitsPtr = 1;
@@ -2444,10 +2437,10 @@ SetPrecisionLimits(
}
break;
default:
- *iPtr = -1;
- *iLimPtr = -1;
- *iLim1Ptr = -1;
- Tcl_Panic("impossible conversion type in TclDoubleDigits");
+ *iLimPtr = *iLim1Ptr = -1;
+ *iPtr = 18;
+ *ndigitsPtr = 0;
+ break;
}
}
@@ -2877,8 +2870,6 @@ CastOutPowersOf2(
static inline char *
ShorteningInt64Conversion(
Double *dPtr, /* Original number to convert. */
- int convType, /* Type of conversion (shortest, Steele,
- * E format, F format). */
Tcl_WideUInt bw, /* Integer significand. */
int b2, int b5, /* Scale factor for the significand in the
* numerator. */
@@ -2945,7 +2936,7 @@ ShorteningInt64Conversion(
*/
if (b < mplus || (b == mplus
- && convType != TCL_DD_STEELE0 && (dPtr->w.word1 & 1) == 0)) {
+ && (dPtr->w.word1 & 1) == 0)) {
/*
* Make sure we shouldn't be rounding *up* instead, in case the
* next number above is closer.
@@ -2974,7 +2965,7 @@ ShorteningInt64Conversion(
*/
if (b > S - mminus || (b == S - mminus
- && convType != TCL_DD_STEELE0 && (dPtr->w.word1 & 1) == 0)) {
+ && (dPtr->w.word1 & 1) == 0)) {
if (digit == 9) {
*s++ = '9';
s = BumpUp(s, retval, &k);
@@ -3046,8 +3037,6 @@ ShorteningInt64Conversion(
static inline char *
StrictInt64Conversion(
Double *dPtr, /* Original number to convert. */
- int convType, /* Type of conversion (shortest, Steele,
- * E format, F format). */
Tcl_WideUInt bw, /* Integer significand. */
int b2, int b5, /* Scale factor for the significand in the
* numerator. */
@@ -3156,7 +3145,7 @@ ShouldBankerRoundUpPowD(
int isodd) /* 1 if the digit is odd, 0 if even. */
{
int i;
- static const mp_digit topbit = 1 << (DIGIT_BIT - 1);
+ static const mp_digit topbit = ((mp_digit)1) << (DIGIT_BIT - 1);
if (b->used < sd || (b->dp[sd-1] & topbit) == 0) {
return 0;
@@ -3192,9 +3181,6 @@ ShouldBankerRoundUpToNextPowD(
mp_int *b, /* Numerator of the fraction. */
mp_int *m, /* Numerator of the rounding tolerance. */
int sd, /* Common denominator is 2**(sd*DIGIT_BIT). */
- int convType, /* Conversion type: STEELE defeats
- * round-to-even (not sure why one wants to do
- * this; I copied it from Gay). FIXME */
int isodd, /* 1 if the integer significand is odd. */
mp_int *temp) /* Work area for the calculation. */
{
@@ -3220,10 +3206,6 @@ ShouldBankerRoundUpToNextPowD(
return 1;
}
}
- if (convType == TCL_DD_STEELE0) {
- /* Biased rounding. */
- return 0;
- }
return isodd;
}
@@ -3253,8 +3235,6 @@ ShouldBankerRoundUpToNextPowD(
static inline char *
ShorteningBignumConversionPowD(
Double *dPtr, /* Original number to convert. */
- int convType, /* Type of conversion (shortest, Steele,
- * E format, F format). */
Tcl_WideUInt bw, /* Integer significand. */
int b2, int b5, /* Scale factor for the significand in the
* numerator. */
@@ -3340,7 +3320,7 @@ ShorteningBignumConversionPowD(
r1 = mp_cmp_mag(&b, (m2plus > m2minus)? &mplus : &mminus);
if (r1 == MP_LT || (r1 == MP_EQ
- && convType != TCL_DD_STEELE0 && (dPtr->w.word1 & 1) == 0)) {
+ && (dPtr->w.word1 & 1) == 0)) {
/*
* Make sure we shouldn't be rounding *up* instead, in case the
* next number above is closer.
@@ -3368,7 +3348,7 @@ ShorteningBignumConversionPowD(
* number?
*/
- if (ShouldBankerRoundUpToNextPowD(&b, &mminus, sd, convType,
+ if (ShouldBankerRoundUpToNextPowD(&b, &mminus, sd,
dPtr->w.word1 & 1, &temp)) {
if (digit == 9) {
*s++ = '9';
@@ -3446,8 +3426,6 @@ ShorteningBignumConversionPowD(
static inline char *
StrictBignumConversionPowD(
Double *dPtr, /* Original number to convert. */
- int convType, /* Type of conversion (shortest, Steele,
- * E format, F format). */
Tcl_WideUInt bw, /* Integer significand. */
int b2, int b5, /* Scale factor for the significand in the
* numerator. */
@@ -3468,7 +3446,6 @@ StrictBignumConversionPowD(
mp_digit digit; /* Current output digit. */
char *s = retval; /* Cursor in the output buffer. */
int i; /* Index in the output buffer. */
- mp_int temp;
/*
* b = bw * 2**b2 * 5**b5
@@ -3487,7 +3464,6 @@ StrictBignumConversionPowD(
ilim = ilim1;
--k;
}
- mp_init(&temp);
/*
* Loop through the digits. Do division and mod by s == 2**(sd*DIGIT_BIT)
@@ -3536,7 +3512,7 @@ StrictBignumConversionPowD(
* string.
*/
- mp_clear_multi(&b, &temp, NULL);
+ mp_clear(&b);
*s = '\0';
*decpt = k;
if (endPtr) {
@@ -3600,29 +3576,24 @@ ShouldBankerRoundUpToNext(
* the last digit. */
mp_int *m, /* Numerator of the rounding tolerance. */
mp_int *S, /* Denominator. */
- int convType, /* Conversion type: STEELE0 defeats
- * round-to-even. (Not sure why one would want
- * this; I coped it from Gay). FIXME */
- int isodd, /* 1 if the integer significand is odd. */
- mp_int *temp) /* Work area needed for the calculation. */
+ int isodd) /* 1 if the integer significand is odd. */
{
int r;
+ mp_int temp;
/*
* Compare b and S-m: this is the same as comparing B+m and S.
*/
- mp_add(b, m, temp);
- r = mp_cmp_mag(temp, S);
+ mp_init(&temp);
+ mp_add(b, m, &temp);
+ r = mp_cmp_mag(&temp, S);
+ mp_clear(&temp);
switch(r) {
case MP_LT:
return 0;
case MP_EQ:
- if (convType == TCL_DD_STEELE0) {
- return 0;
- } else {
- return isodd;
- }
+ return isodd;
case MP_GT:
return 1;
}
@@ -3651,7 +3622,6 @@ ShouldBankerRoundUpToNext(
static inline char *
ShorteningBignumConversion(
Double *dPtr, /* Original number being converted. */
- int convType, /* Conversion type. */
Tcl_WideUInt bw, /* Integer significand and exponent. */
int b2, /* Scale factor for the significand. */
int m2plus, int m2minus, /* Scale factors for 1/2 ulp in numerator. */
@@ -3672,7 +3642,6 @@ ShorteningBignumConversion(
mp_int S; /* Denominator of the result. */
mp_int dig; /* Current digit of the result. */
int digit; /* Current digit of the result. */
- mp_int temp; /* Work area. */
int minit = 1; /* Fudge factor for when we misguess k. */
int i;
int r1;
@@ -3708,7 +3677,6 @@ ShorteningBignumConversion(
mp_init_copy(&mplus, &mminus);
mp_mul_2d(&mplus, m2plus-m2minus, &mplus);
}
- mp_init(&temp);
/*
* Loop through the digits.
@@ -3729,8 +3697,7 @@ ShorteningBignumConversion(
*/
r1 = mp_cmp_mag(&b, (m2plus > m2minus)? &mplus : &mminus);
- if (r1 == MP_LT || (r1 == MP_EQ
- && convType != TCL_DD_STEELE0 && (dPtr->w.word1 & 1) == 0)) {
+ if (r1 == MP_LT || (r1 == MP_EQ && (dPtr->w.word1 & 1) == 0)) {
mp_mul_2d(&b, 1, &b);
if (ShouldBankerRoundUp(&b, &S, digit&1)) {
++digit;
@@ -3749,8 +3716,8 @@ ShorteningBignumConversion(
* commit to rounding up to the next higher digit?
*/
- if (ShouldBankerRoundUpToNext(&b, &mminus, &S, convType,
- dPtr->w.word1 & 1, &temp)) {
+ if (ShouldBankerRoundUpToNext(&b, &mminus, &S,
+ dPtr->w.word1 & 1)) {
++digit;
if (digit == 10) {
*s++ = '9';
@@ -3837,7 +3804,7 @@ ShorteningBignumConversion(
if (m2plus > m2minus) {
mp_clear(&mplus);
}
- mp_clear_multi(&b, &mminus, &temp, &dig, &S, NULL);
+ mp_clear_multi(&b, &mminus, &dig, &S, NULL);
*s = '\0';
*decpt = k;
if (endPtr) {
@@ -3867,7 +3834,6 @@ ShorteningBignumConversion(
static inline char *
StrictBignumConversion(
Double *dPtr, /* Original number being converted. */
- int convType, /* Conversion type. */
Tcl_WideUInt bw, /* Integer significand and exponent. */
int b2, /* Scale factor for the significand. */
int s2, int s5, /* Scale factors for denominator. */
@@ -3885,7 +3851,6 @@ StrictBignumConversion(
mp_int S; /* Denominator of the result. */
mp_int dig; /* Current digit of the result. */
int digit; /* Current digit of the result. */
- mp_int temp; /* Work area. */
int g; /* Size of the current digit ground. */
int i, j;
@@ -3894,7 +3859,7 @@ StrictBignumConversion(
* S = 2**s2 * 5*s5
*/
- mp_init_multi(&temp, &dig, NULL);
+ mp_init_multi(&dig, NULL);
TclInitBignumFromWideUInt(&b, bw);
mp_mul_2d(&b, b2, &b);
mp_init_set_int(&S, 1);
@@ -4001,7 +3966,7 @@ StrictBignumConversion(
* string.
*/
- mp_clear_multi(&b, &S, &temp, &dig, NULL);
+ mp_clear_multi(&b, &S, &dig, NULL);
*s = '\0';
*decpt = k;
if (endPtr) {
@@ -4037,15 +4002,6 @@ StrictBignumConversion(
* For floating point numbers that are exactly between two
* decimal numbers, it resolves using the 'round to even' rule.
* With this value, the 'ndigits' parameter is ignored.
- * TCL_DD_STEELE - This value is not recommended and may be removed in
- * the future. It follows the conversion algorithm outlined in
- * "How to Print Floating-Point Numbers Accurately" by Guy
- * L. Steele, Jr. and Jon L. White [Proc. ACM SIGPLAN '90,
- * pp. 112-126]. This rule has the effect of rendering 1e23 as
- * 9.9999999999999999e22 - which is a 'better' approximation in
- * the sense that it will reconvert correctly even if a
- * subsequent input conversion is 'round up' or 'round down'
- * rather than 'round to nearest', but is surprising otherwise.
* TCL_DD_E_FORMAT - This value is used to prepare numbers for %e format
* conversion (or for default floating->string if tcl_precision
* is not 0). It constructs a string of at most 'ndigits' digits,
@@ -4096,10 +4052,6 @@ TclDoubleDigits(
* one character beyond the end of the
* returned string. */
{
- int convType = (flags & TCL_DD_CONVERSION_TYPE_MASK);
- /* Type of conversion being performed:
- * TCL_DD_SHORTEST0, TCL_DD_STEELE0,
- * TCL_DD_E_FORMAT, or TCL_DD_F_FORMAT. */
Double d; /* Union for deconstructing doubles. */
Tcl_WideUInt bw; /* Integer significand. */
int be; /* Power of 2 by which b must be multiplied */
@@ -4167,18 +4119,18 @@ TclDoubleDigits(
* Correct an incorrect caller-supplied 'ndigits'. Also determine:
* i = The maximum number of decimal digits that will be returned in the
* formatted string. This is k + 1 + ndigits for F format, 18 for
- * shortest and Steele, and ndigits for E format.
+ * shortest, and ndigits for E format.
* ilim = The number of significant digits to convert if k has been
- * guessed correctly. This is -1 for shortest and Steele (which
+ * guessed correctly. This is -1 for shortest (which
* stop when all significance has been lost), 'ndigits' for E
* format, and 'k + 1 + ndigits' for F format.
* ilim1 = The minimum number of significant digits to convert if k has
- * been guessed 1 too high. This, too, is -1 for shortest and
- * Steele, and 'ndigits' for E format, but it's 'ndigits-1' for F
+ * been guessed 1 too high. This, too, is -1 for shortest,
+ * and 'ndigits' for E format, but it's 'ndigits-1' for F
* format.
*/
- SetPrecisionLimits(convType, k, &ndigits, &i, &ilim, &ilim1);
+ SetPrecisionLimits(flags, k, &ndigits, &i, &ilim, &ilim1);
/*
* Try to do low-precision conversion in floating point rather than
@@ -4251,7 +4203,7 @@ TclDoubleDigits(
* [1.0e-3 .. 1.0e+24]).
*/
- return ShorteningInt64Conversion(&d, convType, bw, b2, b5, m2plus,
+ return ShorteningInt64Conversion(&d, bw, b2, b5, m2plus,
m2minus, m5, s2, s5, k, len, ilim, ilim1, decpt, endPtr);
} else if (s5 == 0) {
/*
@@ -4270,7 +4222,7 @@ TclDoubleDigits(
m2minus += delta;
s2 += delta;
}
- return ShorteningBignumConversionPowD(&d, convType, bw, b2, b5,
+ return ShorteningBignumConversionPowD(&d, bw, b2, b5,
m2plus, m2minus, m5, s2/DIGIT_BIT, k, len, ilim, ilim1,
decpt, endPtr);
} else {
@@ -4279,7 +4231,7 @@ TclDoubleDigits(
* arithmetic for the conversion.
*/
- return ShorteningBignumConversion(&d, convType, bw, b2, m2plus,
+ return ShorteningBignumConversion(&d, bw, b2, m2plus,
m2minus, s2, s5, k, len, ilim, ilim1, decpt, endPtr);
}
} else {
@@ -4307,7 +4259,7 @@ TclDoubleDigits(
* operations.
*/
- return StrictInt64Conversion(&d, convType, bw, b2, b5, s2, s5, k,
+ return StrictInt64Conversion(&d, bw, b2, b5, s2, s5, k,
len, ilim, ilim1, decpt, endPtr);
} else if (s5 == 0) {
/*
@@ -4324,7 +4276,7 @@ TclDoubleDigits(
b2 += delta;
s2 += delta;
}
- return StrictBignumConversionPowD(&d, convType, bw, b2, b5,
+ return StrictBignumConversionPowD(&d, bw, b2, b5,
s2/DIGIT_BIT, k, len, ilim, ilim1, decpt, endPtr);
} else {
/*
@@ -4334,7 +4286,7 @@ TclDoubleDigits(
* fewer mp_int divisions.
*/
- return StrictBignumConversion(&d, convType, bw, b2, s2, s5, k,
+ return StrictBignumConversion(&d, bw, b2, s2, s5, k,
len, ilim, ilim1, decpt, endPtr);
}
}
@@ -4625,7 +4577,7 @@ TclBignumToDouble(
*/
mp_div_2d(a, -shift, &b, NULL);
- if (mp_isodd(&b)) {
+ if (mp_get_bit(&b, 0)) {
if (b.sign == MP_ZPOS) {
mp_add_d(&b, 1, &b);
} else {
@@ -4697,7 +4649,7 @@ TclCeil(
mp_int b;
mp_init(&b);
- if (mp_isneg(a)) {
+ if (a->sign != MP_ZPOS) {
mp_neg(a, &b);
r = -TclFloor(&b);
} else {
@@ -4714,7 +4666,7 @@ TclCeil(
mp_int d;
mp_init(&d);
mp_div_2d(a, -shift, &b, &d);
- exact = mp_iszero(&d);
+ exact = d.used == 0;
mp_clear(&d);
} else {
mp_copy(a, &b);
@@ -4754,7 +4706,7 @@ TclFloor(
mp_int b;
mp_init(&b);
- if (mp_isneg(a)) {
+ if (a->sign != MP_ZPOS) {
mp_neg(a, &b);
r = -TclCeil(&b);
} else {
diff --git a/generic/tclStringObj.c b/generic/tclStringObj.c
index 72ca7cd..4dd334d 100644
--- a/generic/tclStringObj.c
+++ b/generic/tclStringObj.c
@@ -1391,7 +1391,7 @@ Tcl_AppendObjToObj(
* If appendObjPtr is not of the "String" type, don't convert it.
*/
- if (appendObjPtr->typePtr == &tclStringType) {
+ if (TclHasIntRep(appendObjPtr, &tclStringType)) {
Tcl_UniChar *unicode =
Tcl_GetUnicodeFromObj(appendObjPtr, &numChars);
@@ -1412,7 +1412,7 @@ Tcl_AppendObjToObj(
bytes = TclGetStringFromObj(appendObjPtr, &length);
numChars = stringPtr->numChars;
- if ((numChars >= 0) && (appendObjPtr->typePtr == &tclStringType)) {
+ if ((numChars >= 0) && TclHasIntRep(appendObjPtr, &tclStringType)) {
String *appendStringPtr = GET_STRING(appendObjPtr);
appendNumChars = appendStringPtr->numChars;
@@ -2041,16 +2041,16 @@ Tcl_AppendFormatToObj(
}
break;
case 'c': {
- char buf[4];
+ char buf[4] = "";
int code, length;
if (TclGetIntFromObj(interp, segment, &code) != TCL_OK) {
goto error;
}
length = Tcl_UniCharToUtf(code, buf);
- if (!length) {
- /* Special case for handling upper surrogates. */
- length = Tcl_UniCharToUtf(-1, buf);
+ if ((code >= 0xD800) && (length < 3)) {
+ /* Special case for handling high surrogates. */
+ length += Tcl_UniCharToUtf(-1, buf + length);
}
segment = Tcl_NewStringObj(buf, length);
Tcl_IncrRefCount(segment);
@@ -2812,7 +2812,7 @@ TclGetStringStorage(
{
String *stringPtr;
- if (objPtr->typePtr != &tclStringType || objPtr->bytes == NULL) {
+ if (!TclHasIntRep(objPtr, &tclStringType) || objPtr->bytes == NULL) {
return TclGetStringFromObj(objPtr, (int *)sizePtr);
}
@@ -2860,7 +2860,7 @@ TclStringRepeat(
*/
if (!binary) {
- if (objPtr->typePtr == &tclStringType) {
+ if (TclHasIntRep(objPtr, &tclStringType)) {
String *stringPtr = GET_STRING(objPtr);
if (stringPtr->hasUnicode) {
unichar = 1;
@@ -3037,7 +3037,7 @@ TclStringCat(
} else {
/* assert (objPtr->typePtr != NULL) -- stork! */
binary = 0;
- if (objPtr->typePtr == &tclStringType) {
+ if (TclHasIntRep(objPtr, &tclStringType)) {
/* Have a pure Unicode value; ask to preserve it */
requestUniChar = 1;
} else {
@@ -3227,7 +3227,7 @@ TclStringCat(
if (TclIsPureByteArray(objPtr)) {
int more;
unsigned char *src = Tcl_GetByteArrayFromObj(objPtr, &more);
- memcpy(dst, src, (size_t) more);
+ memcpy(dst, src, more);
dst += more;
}
}
@@ -3326,7 +3326,7 @@ TclStringCat(
int more;
char *src = Tcl_GetStringFromObj(objPtr, &more);
- memcpy(dst, src, (size_t) more);
+ memcpy(dst, src, more);
dst += more;
}
}
@@ -3390,8 +3390,8 @@ TclStringCmp(
s1 = (char *) Tcl_GetByteArrayFromObj(value1Ptr, &s1len);
s2 = (char *) Tcl_GetByteArrayFromObj(value2Ptr, &s2len);
memCmpFn = memcmp;
- } else if ((value1Ptr->typePtr == &tclStringType)
- && (value2Ptr->typePtr == &tclStringType)) {
+ } else if (TclHasIntRep(value1Ptr, &tclStringType)
+ && TclHasIntRep(value2Ptr, &tclStringType)) {
/*
* Do a unicode-specific comparison if both of the args are of
* String type. If the char length == byte length, we can do a
@@ -4166,7 +4166,7 @@ SetStringFromAny(
Tcl_Interp *interp, /* Used for error reporting if not NULL. */
Tcl_Obj *objPtr) /* The object to convert. */
{
- if (objPtr->typePtr != &tclStringType) {
+ if (!TclHasIntRep(objPtr, &tclStringType)) {
String *stringPtr = stringAlloc(0);
/*
@@ -4287,7 +4287,7 @@ ExtendStringRepWithUnicode(
copyBytes:
dst = objPtr->bytes + origLength;
for (i = 0; i < numChars; i++) {
- dst += Tcl_UniCharToUtf((int) unicode[i], dst);
+ dst += Tcl_UniCharToUtf(unicode[i], dst);
}
*dst = '\0';
objPtr->length = dst - objPtr->bytes;
diff --git a/generic/tclStubInit.c b/generic/tclStubInit.c
index 8429a2f..197ed84 100644
--- a/generic/tclStubInit.c
+++ b/generic/tclStubInit.c
@@ -57,6 +57,8 @@
#undef TclWinSetSockOpt
#undef TclWinNToHS
#undef TclStaticPackage
+#undef TclBNInitBignumFromLong
+#undef Tcl_BackgroundError
#define TclStaticPackage Tcl_StaticPackage
/* See bug 510001: TclSockMinimumBuffers needs plat imp */
@@ -101,8 +103,12 @@ static int TclSockMinimumBuffersOld(int sock, int size)
# define Tcl_NewLongObj 0
# define Tcl_DbNewLongObj 0
# define Tcl_BackgroundError 0
-
#else
+#define TclBNInitBignumFromLong initBignumFromLong
+static void TclBNInitBignumFromLong(mp_int *a, long b)
+{
+ TclInitBignumFromWideInt(a, b);
+}
#define TclSetStartupScriptPath setStartupScriptPath
static void TclSetStartupScriptPath(Tcl_Obj *path)
{
@@ -153,7 +159,6 @@ TclWinGetPlatformId(void)
#endif
# define TclBNInitBignumFromWideUInt TclInitBignumFromWideUInt
# define TclBNInitBignumFromWideInt TclInitBignumFromWideInt
-# define TclBNInitBignumFromLong TclInitBignumFromLong
#endif /* TCL_NO_DEPRECATED */
#ifdef _WIN32
@@ -239,68 +244,11 @@ Tcl_WinUtfToTChar(
int len,
Tcl_DString *dsPtr)
{
-#if TCL_UTF_MAX > 4
- Tcl_UniChar ch = 0;
- wchar_t *w, *wString;
- const char *p, *end;
- int oldLength;
-#endif
-
Tcl_DStringInit(dsPtr);
if (!string) {
return NULL;
}
-#if TCL_UTF_MAX > 4
-
- if (len < 0) {
- len = strlen(string);
- }
-
- /*
- * Unicode string length in Tcl_UniChars will be <= UTF-8 string length in
- * bytes.
- */
-
- oldLength = Tcl_DStringLength(dsPtr);
-
- Tcl_DStringSetLength(dsPtr,
- oldLength + (int) ((len + 1) * sizeof(wchar_t)));
- wString = (wchar_t *) (Tcl_DStringValue(dsPtr) + oldLength);
-
- w = wString;
- p = string;
- end = string + len - 4;
- while (p < end) {
- p += TclUtfToUniChar(p, &ch);
- if (ch > 0xFFFF) {
- *w++ = (wchar_t) (0xD800 + ((ch -= 0x10000) >> 10));
- *w++ = (wchar_t) (0xDC00 | (ch & 0x3FF));
- } else {
- *w++ = ch;
- }
- }
- end += 4;
- while (p < end) {
- if (Tcl_UtfCharComplete(p, end-p)) {
- p += TclUtfToUniChar(p, &ch);
- } else {
- ch = UCHAR(*p++);
- }
- if (ch > 0xFFFF) {
- *w++ = (wchar_t) (0xD800 + ((ch -= 0x10000) >> 10));
- *w++ = (wchar_t) (0xDC00 | (ch & 0x3FF));
- } else {
- *w++ = ch;
- }
- }
- *w = '\0';
- Tcl_DStringSetLength(dsPtr,
- oldLength + ((char *) w - (char *) wString));
-
- return (char *)wString;
-#else
- return (char *)Tcl_UtfToUniCharDString(string, len, dsPtr);
-#endif
+ return (char *)TclUtfToWCharDString(string, len, dsPtr);
}
char *
@@ -309,12 +257,6 @@ Tcl_WinTCharToUtf(
int len,
Tcl_DString *dsPtr)
{
-#if TCL_UTF_MAX > 4
- const wchar_t *w, *wEnd;
- char *p, *result;
- int oldLength, blen = 1;
-#endif
-
Tcl_DStringInit(dsPtr);
if (!string) {
return NULL;
@@ -324,32 +266,7 @@ Tcl_WinTCharToUtf(
} else {
len /= 2;
}
-#if TCL_UTF_MAX > 4
- oldLength = Tcl_DStringLength(dsPtr);
- Tcl_DStringSetLength(dsPtr, oldLength + (len + 1) * 4);
- result = Tcl_DStringValue(dsPtr) + oldLength;
-
- p = result;
- wEnd = (wchar_t *)string + len;
- for (w = (wchar_t *)string; w < wEnd; ) {
- if (!blen && ((*w & 0xFC00) != 0xDC00)) {
- /* Special case for handling upper surrogates. */
- p += Tcl_UniCharToUtf(-1, p);
- }
- blen = Tcl_UniCharToUtf(*w, p);
- p += blen;
- w++;
- }
- if (!blen) {
- /* Special case for handling upper surrogates. */
- p += Tcl_UniCharToUtf(-1, p);
- }
- Tcl_DStringSetLength(dsPtr, oldLength + (p - result));
-
- return result;
-#else
- return Tcl_UniCharToUtfDString((Tcl_UniChar *)string, len, dsPtr);
-#endif
+ return TclWCharToUtfDString((const WCHAR *)string, len, dsPtr);
}
#if defined(TCL_WIDE_INT_IS_LONG)
@@ -499,6 +416,19 @@ static int uniCharNcasecmp(const Tcl_UniChar *ucs, const Tcl_UniChar *uct, unsig
# define Tcl_FindExecutable 0
# define Tcl_GetUnicode 0
# define TclOldFreeObj 0
+# undef Tcl_StringMatch
+# define Tcl_StringMatch 0
+# define TclBN_reverse 0
+# define TclBN_fast_s_mp_mul_digs 0
+# define TclBN_fast_s_mp_sqr 0
+# define TclBN_mp_karatsuba_mul 0
+# define TclBN_mp_karatsuba_sqr 0
+# define TclBN_mp_toom_mul 0
+# define TclBN_mp_toom_sqr 0
+# define TclBN_s_mp_add 0
+# define TclBN_s_mp_mul_digs 0
+# define TclBN_s_mp_sqr 0
+# define TclBN_s_mp_sub 0
#else /* TCL_NO_DEPRECATED */
# define Tcl_SeekOld seekOld
# define Tcl_TellOld tellOld
@@ -1018,6 +948,7 @@ const TclTomMathStubs tclTomMathStubs = {
TclBN_mp_tc_or, /* 74 */
TclBN_mp_tc_xor, /* 75 */
TclBN_mp_tc_div_2d, /* 76 */
+ TclBN_mp_get_bit, /* 77 */
};
static const TclStubHooks tclStubHooks = {
diff --git a/generic/tclTest.c b/generic/tclTest.c
index c87bb54..349d935 100644
--- a/generic/tclTest.c
+++ b/generic/tclTest.c
@@ -52,6 +52,7 @@ DLLEXPORT int Tcltest_SafeInit(Tcl_Interp *interp);
static Tcl_DString delString;
static Tcl_Interp *delInterp;
+static const Tcl_ObjType *properByteArrayType;
/*
* One of the following structures exists for each asynchronous handler
@@ -552,8 +553,7 @@ int
Tcltest_Init(
Tcl_Interp *interp) /* Interpreter for application. */
{
- Tcl_Obj *listPtr;
- Tcl_Obj **objv;
+ Tcl_Obj **objv, *objPtr;
int objc, index;
static const char *const specialOptions[] = {
"-appinitprocerror", "-appinitprocdeleteinterp",
@@ -575,6 +575,11 @@ Tcltest_Init(
return TCL_ERROR;
}
+ objPtr = Tcl_NewStringObj("abc", 3);
+ (void)Tcl_GetByteArrayFromObj(objPtr, &index);
+ properByteArrayType = objPtr->typePtr;
+ Tcl_DecrRefCount(objPtr);
+
/*
* Create additional commands and math functions for testing Tcl.
*/
@@ -740,9 +745,9 @@ Tcltest_Init(
* Check for special options used in ../tests/main.test
*/
- listPtr = Tcl_GetVar2Ex(interp, "argv", NULL, TCL_GLOBAL_ONLY);
- if (listPtr != NULL) {
- if (Tcl_ListObjGetElements(interp, listPtr, &objc, &objv) != TCL_OK) {
+ objPtr = Tcl_GetVar2Ex(interp, "argv", NULL, TCL_GLOBAL_ONLY);
+ if (objPtr != NULL) {
+ if (Tcl_ListObjGetElements(interp, objPtr, &objc, &objv) != TCL_OK) {
return TCL_ERROR;
}
if (objc && (Tcl_GetIndexFromObj(NULL, objv[0], specialOptions, NULL,
@@ -1701,7 +1706,7 @@ TestdelassocdataCmd(
* Parameters:
* fpval - Floating-point value to format.
* ndigits - Digit count to request from Tcl_DoubleDigits
- * type - One of 'shortest', 'Steele', 'e', 'f'
+ * type - One of 'shortest', 'e', 'f'
* shorten - Indicates that the 'shorten' flag should be passed in.
*
*-----------------------------------------------------------------------------
@@ -1719,14 +1724,12 @@ TestdoubledigitsObjCmd(void *unused,
{
static const char* options[] = {
"shortest",
- "Steele",
"e",
"f",
NULL
};
static const int types[] = {
TCL_DD_SHORTEST,
- TCL_DD_STEELE,
TCL_DD_E_FORMAT,
TCL_DD_F_FORMAT
};
@@ -1750,8 +1753,8 @@ TestdoubledigitsObjCmd(void *unused,
status = Tcl_GetDoubleFromObj(interp, objv[1], &d);
if (status != TCL_OK) {
doubleType = Tcl_GetObjType("double");
- if (objv[1]->typePtr == doubleType
- || TclIsNaN(objv[1]->internalRep.doubleValue)) {
+ if (Tcl_FetchIntRep(objv[1], doubleType)
+ && TclIsNaN(objv[1]->internalRep.doubleValue)) {
status = TCL_OK;
memcpy(&d, &(objv[1]->internalRep.doubleValue), sizeof(double));
}
@@ -5013,7 +5016,7 @@ TestbytestringObjCmd(
int objc, /* Number of arguments. */
Tcl_Obj *const objv[]) /* The argument objects. */
{
- int n;
+ int n = 0;
const char *p;
if (objc != 2) {
@@ -5021,6 +5024,10 @@ TestbytestringObjCmd(
return TCL_ERROR;
}
p = (const char *)Tcl_GetByteArrayFromObj(objv[1], &n);
+ if ((p == NULL) || !Tcl_FetchIntRep(objv[1], properByteArrayType)) {
+ Tcl_AppendResult(interp, "testbytestring expects bytes", NULL);
+ return TCL_ERROR;
+ }
Tcl_SetObjResult(interp, Tcl_NewStringObj(p, n));
return TCL_OK;
}
diff --git a/generic/tclTestObj.c b/generic/tclTestObj.c
index 67b1997..a289e32 100644
--- a/generic/tclTestObj.c
+++ b/generic/tclTestObj.c
@@ -290,9 +290,9 @@ TestbignumobjCmd(
return TCL_ERROR;
}
if (!Tcl_IsShared(varPtr[varIndex])) {
- Tcl_SetIntObj(varPtr[varIndex], mp_iseven(&bignumValue));
+ Tcl_SetIntObj(varPtr[varIndex], !mp_get_bit(&bignumValue, 0));
} else {
- SetVarToObj(varPtr, varIndex, Tcl_NewIntObj(mp_iseven(&bignumValue)));
+ SetVarToObj(varPtr, varIndex, Tcl_NewIntObj(!mp_get_bit(&bignumValue, 0)));
}
mp_clear(&bignumValue);
break;
@@ -385,9 +385,9 @@ TestbooleanobjCmd(
*/
if ((varPtr[varIndex] != NULL) && !Tcl_IsShared(varPtr[varIndex])) {
- Tcl_SetBooleanObj(varPtr[varIndex], boolValue);
+ Tcl_SetWideIntObj(varPtr[varIndex], boolValue != 0);
} else {
- SetVarToObj(varPtr, varIndex, Tcl_NewBooleanObj(boolValue));
+ SetVarToObj(varPtr, varIndex, Tcl_NewWideIntObj(boolValue != 0));
}
Tcl_SetObjResult(interp, varPtr[varIndex]);
} else if (strcmp(subCmd, "get") == 0) {
@@ -410,9 +410,9 @@ TestbooleanobjCmd(
return TCL_ERROR;
}
if (!Tcl_IsShared(varPtr[varIndex])) {
- Tcl_SetBooleanObj(varPtr[varIndex], !boolValue);
+ Tcl_SetWideIntObj(varPtr[varIndex], boolValue == 0);
} else {
- SetVarToObj(varPtr, varIndex, Tcl_NewBooleanObj(!boolValue));
+ SetVarToObj(varPtr, varIndex, Tcl_NewWideIntObj(boolValue == 0));
}
Tcl_SetObjResult(interp, varPtr[varIndex]);
} else {
@@ -658,7 +658,7 @@ TestintobjCmd(
Tcl_Obj *const objv[]) /* Argument objects. */
{
int intValue, varIndex, i;
- long longValue;
+ Tcl_WideInt wideValue;
const char *index, *subCmd, *string;
Tcl_Obj **varPtr;
@@ -713,7 +713,7 @@ TestintobjCmd(
} else {
SetVarToObj(varPtr, varIndex, Tcl_NewIntObj(intValue));
}
- } else if (strcmp(subCmd, "setlong") == 0) {
+ } else if (strcmp(subCmd, "setint") == 0) {
if (objc != 4) {
goto wrongNumArgs;
}
@@ -728,28 +728,28 @@ TestintobjCmd(
SetVarToObj(varPtr, varIndex, Tcl_NewWideIntObj(intValue));
}
Tcl_SetObjResult(interp, varPtr[varIndex]);
- } else if (strcmp(subCmd, "setmaxlong") == 0) {
- long maxLong = LONG_MAX;
+ } else if (strcmp(subCmd, "setmax") == 0) {
+ Tcl_WideInt maxWide = WIDE_MAX;
if (objc != 3) {
goto wrongNumArgs;
}
if ((varPtr[varIndex] != NULL) && !Tcl_IsShared(varPtr[varIndex])) {
- Tcl_SetWideIntObj(varPtr[varIndex], maxLong);
+ Tcl_SetWideIntObj(varPtr[varIndex], maxWide);
} else {
- SetVarToObj(varPtr, varIndex, Tcl_NewWideIntObj(maxLong));
+ SetVarToObj(varPtr, varIndex, Tcl_NewWideIntObj(maxWide));
}
- } else if (strcmp(subCmd, "ismaxlong") == 0) {
+ } else if (strcmp(subCmd, "ismax") == 0) {
if (objc != 3) {
goto wrongNumArgs;
}
if (CheckIfVarUnset(interp, varPtr,varIndex)) {
return TCL_ERROR;
}
- if (Tcl_GetLongFromObj(interp, varPtr[varIndex], &longValue) != TCL_OK) {
+ if (Tcl_GetWideIntFromObj(interp, varPtr[varIndex], &wideValue) != TCL_OK) {
return TCL_ERROR;
}
Tcl_AppendToObj(Tcl_GetObjResult(interp),
- ((longValue == LONG_MAX)? "1" : "0"), -1);
+ ((wideValue == WIDE_MAX)? "1" : "0"), -1);
} else if (strcmp(subCmd, "get") == 0) {
if (objc != 3) {
goto wrongNumArgs;
@@ -1348,7 +1348,7 @@ TeststringobjCmd(
if (objc != 3) {
goto wrongNumArgs;
}
- Tcl_GetUnicodeFromObj(varPtr[varIndex], NULL);
+ Tcl_GetUnicode(varPtr[varIndex]);
break;
case 11: /* appendself */
if (objc != 4) {
diff --git a/generic/tclTestProcBodyObj.c b/generic/tclTestProcBodyObj.c
index 4d32c5a..913b253 100644
--- a/generic/tclTestProcBodyObj.c
+++ b/generic/tclTestProcBodyObj.c
@@ -21,13 +21,14 @@
*/
static const char packageName[] = "procbodytest";
-static const char packageVersion[] = "1.0";
+static const char packageVersion[] = "1.1";
/*
* Name of the commands exported by this package
*/
static const char procCommand[] = "proc";
+static const char checkCommand[] = "check";
/*
* this struct describes an entry in the table of command names and command
@@ -46,6 +47,8 @@ typedef struct CmdTable {
static int ProcBodyTestProcObjCmd(ClientData dummy,
Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]);
+static int ProcBodyTestCheckObjCmd(ClientData dummy,
+ Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]);
static int ProcBodyTestInitInternal(Tcl_Interp *interp, int isSafe);
static int RegisterCommand(Tcl_Interp* interp,
const char *namespace, const CmdTable *cmdTablePtr);
@@ -57,11 +60,13 @@ static int RegisterCommand(Tcl_Interp* interp,
static const CmdTable commands[] = {
{ procCommand, ProcBodyTestProcObjCmd, 1 },
+ { checkCommand, ProcBodyTestCheckObjCmd, 1 },
{ 0, 0, 0 }
};
static const CmdTable safeCommands[] = {
{ procCommand, ProcBodyTestProcObjCmd, 1 },
+ { checkCommand, ProcBodyTestCheckObjCmd, 1 },
{ 0, 0, 0 }
};
@@ -301,6 +306,46 @@ ProcBodyTestProcObjCmd(
}
/*
+ *----------------------------------------------------------------------
+ *
+ * ProcBodyTestCheckObjCmd --
+ *
+ * Implements the "procbodytest::check" command. Here is the command
+ * description:
+ * procbodytest::check
+ *
+ * Performs an internal check that the Tcl_PkgPresent() command returns
+ * the same version number as was registered when the procbodytest package
+ * was provided. Places a boolean in the interp result indicating the
+ * test outcome.
+ *
+ * Results:
+ * Returns a standard Tcl code.
+ *
+ *----------------------------------------------------------------------
+ */
+
+static int
+ProcBodyTestCheckObjCmd(
+ ClientData dummy, /* context; not used */
+ Tcl_Interp *interp, /* the current interpreter */
+ int objc, /* argument count */
+ Tcl_Obj *const objv[]) /* arguments */
+{
+ const char *version;
+
+ if (objc != 1) {
+ Tcl_WrongNumArgs(interp, 1, objv, "");
+ return TCL_ERROR;
+ }
+
+ version = Tcl_PkgPresent(interp, packageName, packageVersion, 1);
+ Tcl_SetObjResult(interp, Tcl_NewWideIntObj(
+ strcmp(version, packageVersion) == 0));
+ return TCL_OK;
+}
+
+/*
* Local Variables:
* mode: c
* c-basic-offset: 4
diff --git a/generic/tclThread.c b/generic/tclThread.c
index cafd824..661ac2f 100644
--- a/generic/tclThread.c
+++ b/generic/tclThread.c
@@ -73,13 +73,13 @@ Tcl_GetThreadData(
if (result == NULL) {
result = ckalloc(size);
- memset(result, 0, (size_t) size);
+ memset(result, 0, size);
TclThreadStorageKeySet(keyPtr, result);
}
#else /* TCL_THREADS */
if (*keyPtr == NULL) {
result = ckalloc(size);
- memset(result, 0, (size_t)size);
+ memset(result, 0, size);
*keyPtr = result;
RememberSyncObject(keyPtr, &keyRecord);
} else {
diff --git a/generic/tclTimer.c b/generic/tclTimer.c
index ccfd179..15c87b5 100644
--- a/generic/tclTimer.c
+++ b/generic/tclTimer.c
@@ -900,7 +900,7 @@ Tcl_AfterObjCmd(
tempCommand = TclGetStringFromObj(afterPtr->commandPtr,
&tempLength);
if ((length == tempLength)
- && !memcmp(command, tempCommand, (unsigned) length)) {
+ && !memcmp(command, tempCommand, length)) {
break;
}
}
diff --git a/generic/tclTomMath.decls b/generic/tclTomMath.decls
index a6c3d5b..7221dcf 100644
--- a/generic/tclTomMath.decls
+++ b/generic/tclTomMath.decls
@@ -178,37 +178,37 @@ declare 49 {
# internal routines to libtommath - should not be called but must be
# exported to accommodate the "tommath" extension
-declare 50 {
+declare 50 {deprecated {is private function in libtommath}} {
void TclBN_reverse(unsigned char *s, int len)
}
-declare 51 {
+declare 51 {deprecated {is private function in libtommath}} {
int TclBN_fast_s_mp_mul_digs(const mp_int *a, const mp_int *b, mp_int *c, int digs)
}
-declare 52 {
+declare 52 {deprecated {is private function in libtommath}} {
int TclBN_fast_s_mp_sqr(const mp_int *a, mp_int *b)
}
-declare 53 {
+declare 53 {deprecated {is private function in libtommath}} {
int TclBN_mp_karatsuba_mul(const mp_int *a, const mp_int *b, mp_int *c)
}
-declare 54 {
+declare 54 {deprecated {is private function in libtommath}} {
int TclBN_mp_karatsuba_sqr(const mp_int *a, mp_int *b)
}
-declare 55 {
+declare 55 {deprecated {is private function in libtommath}} {
int TclBN_mp_toom_mul(const mp_int *a, const mp_int *b, mp_int *c)
}
-declare 56 {
+declare 56 {deprecated {is private function in libtommath}} {
int TclBN_mp_toom_sqr(const mp_int *a, mp_int *b)
}
-declare 57 {
+declare 57 {deprecated {is private function in libtommath}} {
int TclBN_s_mp_add(const mp_int *a, const mp_int *b, mp_int *c)
}
-declare 58 {
+declare 58 {deprecated {is private function in libtommath}} {
int TclBN_s_mp_mul_digs(const mp_int *a, const mp_int *b, mp_int *c, int digs)
}
-declare 59 {
+declare 59 {deprecated {is private function in libtommath}} {
int TclBN_s_mp_sqr(const mp_int *a, mp_int *b)
}
-declare 60 {
+declare 60 {deprecated {is private function in libtommath}} {
int TclBN_s_mp_sub(const mp_int *a, const mp_int *b, mp_int *c)
}
declare 61 {
@@ -267,6 +267,9 @@ declare 75 {
declare 76 {
int TclBN_mp_tc_div_2d(const mp_int *a, int b, mp_int *c)
}
+declare 77 {
+ int TclBN_mp_get_bit(const mp_int *a, int b)
+}
# Local Variables:
diff --git a/generic/tclTomMath.h b/generic/tclTomMath.h
index fbf0d35..26eef26 100644
--- a/generic/tclTomMath.h
+++ b/generic/tclTomMath.h
@@ -7,8 +7,7 @@
* Michael Fromberger but has been written from scratch with
* additional optimizations in place.
*
- * The library is free for all purposes without any express
- * guarantee it works.
+ * SPDX-License-Identifier: Unlicense
*/
#ifndef BN_H_
#define BN_H_
@@ -25,7 +24,7 @@ extern "C" {
#endif
/* MS Visual C++ doesn't have a 128bit type for words, so fall back to 32bit MPI's (where words are 64bit) */
-#if defined(_MSC_VER) || defined(__LLP64__) || defined(__e2k__) || defined(__LCC__)
+#if defined(_WIN32) || defined(__LLP64__) || defined(__e2k__) || defined(__LCC__)
# define MP_32BIT
#endif
@@ -110,9 +109,6 @@ typedef unsigned long long mp_word;
/* otherwise the bits per digit is calculated automatically from the size of a mp_digit */
#ifndef DIGIT_BIT
# define DIGIT_BIT (((CHAR_BIT * MP_SIZEOF_MP_DIGIT) - 1)) /* bits per digit */
-typedef unsigned long mp_min_u32;
-#else
-typedef mp_digit mp_min_u32;
#endif
#define MP_DIGIT_BIT DIGIT_BIT
@@ -131,6 +127,7 @@ typedef mp_digit mp_min_u32;
#define MP_MEM -2 /* out of mem */
#define MP_VAL -3 /* invalid input */
#define MP_RANGE MP_VAL
+#define MP_ITER -4 /* Max. iterations reached */
#define MP_YES 1 /* yes response */
#define MP_NO 0 /* no response */
@@ -142,14 +139,6 @@ typedef mp_digit mp_min_u32;
typedef int mp_err;
-/* you'll have to tune these... */
-#if defined(BUILD_tcl) || !defined(_WIN32)
-MODULE_SCOPE int KARATSUBA_MUL_CUTOFF,
- KARATSUBA_SQR_CUTOFF,
- TOOM_MUL_CUTOFF,
- TOOM_SQR_CUTOFF;
-#endif
-
/* define this to use lower memory usage routines (exptmods mostly) */
/* #define MP_LOW_MEM */
@@ -229,8 +218,8 @@ int mp_init_size(mp_int *a, int size);
/* ---> Basic Manipulations <--- */
#define mp_iszero(a) (((a)->used == 0) ? MP_YES : MP_NO)
-#define mp_iseven(a) ((((a)->used == 0) || (((a)->dp[0] & 1u) == 0u)) ? MP_YES : MP_NO)
-#define mp_isodd(a) ((((a)->used > 0) && (((a)->dp[0] & 1u) == 1u)) ? MP_YES : MP_NO)
+#define mp_iseven(a) (!mp_get_bit((a),0))
+#define mp_isodd(a) mp_get_bit((a),0)
#define mp_isneg(a) (((a)->sign != MP_ZPOS) ? MP_YES : MP_NO)
/* set to zero */
@@ -357,15 +346,20 @@ int mp_cnt_lsb(const mp_int *a);
/* I Love Earth! */
-/* makes a pseudo-random int of a given size */
+/* makes a pseudo-random mp_int of a given size */
/*
int mp_rand(mp_int *a, int digits);
*/
+/* makes a pseudo-random small int of a given size */
+/*
+int mp_rand_digit(mp_digit *r);
+*/
#ifdef MP_PRNG_ENABLE_LTM_RNG
-/* as last resort we will fall back to libtomcrypt's rng_get_bytes()
- * in case you don't use libtomcrypt or use it w/o rng_get_bytes()
- * you have to implement it somewhere else, as it's required */
+/* A last resort to provide random data on systems without any of the other
+ * implemented ways to gather entropy.
+ * It is compatible with `rng_get_bytes()` from libtomcrypt so you could
+ * provide that one and then set `ltm_rng = rng_get_bytes;` */
extern unsigned long (*ltm_rng)(unsigned char *out, unsigned long outlen, void (*callback)(void));
extern void (*ltm_rng_callback)(void);
#endif
@@ -702,10 +696,17 @@ int mp_prime_miller_rabin(const mp_int *a, const mp_int *b, int *result);
int mp_prime_rabin_miller_trials(int size);
*/
-/* performs t rounds of Miller-Rabin on "a" using the first
- * t prime bases. Also performs an initial sieve of trial
+/* performs t random rounds of Miller-Rabin on "a" additional to
+ * bases 2 and 3. Also performs an initial sieve of trial
* division. Determines if "a" is prime with probability
* of error no more than (1/4)**t.
+ * Both a strong Lucas-Selfridge to complete the BPSW test
+ * and a separate Frobenius test are available at compile time.
+ * With t<0 a deterministic test is run for primes up to
+ * 318665857834031151167461. With t<13 (abs(t)-13) additional
+ * tests with sequential small primes are run starting at 43.
+ * Is Fips 186.4 compliant if called with t as computed by
+ * mp_prime_rabin_miller_trials();
*
* Sets result to 1 if probably prime, 0 otherwise
*/
diff --git a/generic/tclTomMathDecls.h b/generic/tclTomMathDecls.h
index 1e402fd..165e3b7 100644
--- a/generic/tclTomMathDecls.h
+++ b/generic/tclTomMathDecls.h
@@ -36,20 +36,13 @@
#define TclBNRealloc(x,s) ((void*)ckrealloc((char*)(x),(size_t)(s)))
/* MODULE_SCOPE void TclBNFree( void* ); */
#define TclBNFree(x) (ckfree((char*)(x)))
-/* MODULE_SCOPE void* TclBNCalloc( size_t, size_t ); */
-/* unused - no macro */
-#define XMALLOC(x) TclBNAlloc(x)
-#define XFREE(x) TclBNFree(x)
-#define XREALLOC(x,n) TclBNRealloc(x,n)
-#define XCALLOC(n,x) TclBNCalloc(n,x)
+#define XMALLOC(size) TclBNAlloc(size)
+#define XFREE(mem, size) TclBNFree(mem)
+#define XREALLOC(mem, oldsize, newsize) TclBNRealloc(mem, newsize)
-/* Rename the global symbols in libtommath to avoid linkage conflicts */
-#define KARATSUBA_MUL_CUTOFF TclBNKaratsubaMulCutoff
-#define KARATSUBA_SQR_CUTOFF TclBNKaratsubaSqrCutoff
-#define TOOM_MUL_CUTOFF TclBNToomMulCutoff
-#define TOOM_SQR_CUTOFF TclBNToomSqrCutoff
+/* Rename the global symbols in libtommath to avoid linkage conflicts */
#define bn_reverse TclBN_reverse
#define fast_s_mp_mul_digs TclBN_fast_s_mp_mul_digs
@@ -74,6 +67,7 @@
#define mp_exch TclBN_mp_exch
#define mp_expt_d TclBN_mp_expt_d
#define mp_expt_d_ex TclBN_mp_expt_d_ex
+#define mp_get_bit TclBN_mp_get_bit
#define mp_get_int TclBN_mp_get_int
#define mp_get_long TclBN_mp_get_long
#define mp_get_long_long TclBN_mp_get_long_long
@@ -272,32 +266,43 @@ EXTERN int TclBN_mp_xor(const mp_int *a, const mp_int *b,
/* 49 */
EXTERN void TclBN_mp_zero(mp_int *a);
/* 50 */
-EXTERN void TclBN_reverse(unsigned char *s, int len);
+TCL_DEPRECATED("is private function in libtommath")
+void TclBN_reverse(unsigned char *s, int len);
/* 51 */
-EXTERN int TclBN_fast_s_mp_mul_digs(const mp_int *a,
+TCL_DEPRECATED("is private function in libtommath")
+int TclBN_fast_s_mp_mul_digs(const mp_int *a,
const mp_int *b, mp_int *c, int digs);
/* 52 */
-EXTERN int TclBN_fast_s_mp_sqr(const mp_int *a, mp_int *b);
+TCL_DEPRECATED("is private function in libtommath")
+int TclBN_fast_s_mp_sqr(const mp_int *a, mp_int *b);
/* 53 */
-EXTERN int TclBN_mp_karatsuba_mul(const mp_int *a,
+TCL_DEPRECATED("is private function in libtommath")
+int TclBN_mp_karatsuba_mul(const mp_int *a,
const mp_int *b, mp_int *c);
/* 54 */
-EXTERN int TclBN_mp_karatsuba_sqr(const mp_int *a, mp_int *b);
+TCL_DEPRECATED("is private function in libtommath")
+int TclBN_mp_karatsuba_sqr(const mp_int *a, mp_int *b);
/* 55 */
-EXTERN int TclBN_mp_toom_mul(const mp_int *a, const mp_int *b,
+TCL_DEPRECATED("is private function in libtommath")
+int TclBN_mp_toom_mul(const mp_int *a, const mp_int *b,
mp_int *c);
/* 56 */
-EXTERN int TclBN_mp_toom_sqr(const mp_int *a, mp_int *b);
+TCL_DEPRECATED("is private function in libtommath")
+int TclBN_mp_toom_sqr(const mp_int *a, mp_int *b);
/* 57 */
-EXTERN int TclBN_s_mp_add(const mp_int *a, const mp_int *b,
+TCL_DEPRECATED("is private function in libtommath")
+int TclBN_s_mp_add(const mp_int *a, const mp_int *b,
mp_int *c);
/* 58 */
-EXTERN int TclBN_s_mp_mul_digs(const mp_int *a, const mp_int *b,
+TCL_DEPRECATED("is private function in libtommath")
+int TclBN_s_mp_mul_digs(const mp_int *a, const mp_int *b,
mp_int *c, int digs);
/* 59 */
-EXTERN int TclBN_s_mp_sqr(const mp_int *a, mp_int *b);
+TCL_DEPRECATED("is private function in libtommath")
+int TclBN_s_mp_sqr(const mp_int *a, mp_int *b);
/* 60 */
-EXTERN int TclBN_s_mp_sub(const mp_int *a, const mp_int *b,
+TCL_DEPRECATED("is private function in libtommath")
+int TclBN_s_mp_sub(const mp_int *a, const mp_int *b,
mp_int *c);
/* 61 */
EXTERN int TclBN_mp_init_set_int(mp_int *a, unsigned long i);
@@ -340,6 +345,8 @@ EXTERN int TclBN_mp_tc_xor(const mp_int *a, const mp_int *b,
mp_int *c);
/* 76 */
EXTERN int TclBN_mp_tc_div_2d(const mp_int *a, int b, mp_int *c);
+/* 77 */
+EXTERN int TclBN_mp_get_bit(const mp_int *a, int b);
typedef struct TclTomMathStubs {
int magic;
@@ -395,17 +402,17 @@ typedef struct TclTomMathStubs {
int (*tclBN_mp_unsigned_bin_size) (const mp_int *a); /* 47 */
int (*tclBN_mp_xor) (const mp_int *a, const mp_int *b, mp_int *c); /* 48 */
void (*tclBN_mp_zero) (mp_int *a); /* 49 */
- void (*tclBN_reverse) (unsigned char *s, int len); /* 50 */
- int (*tclBN_fast_s_mp_mul_digs) (const mp_int *a, const mp_int *b, mp_int *c, int digs); /* 51 */
- int (*tclBN_fast_s_mp_sqr) (const mp_int *a, mp_int *b); /* 52 */
- int (*tclBN_mp_karatsuba_mul) (const mp_int *a, const mp_int *b, mp_int *c); /* 53 */
- int (*tclBN_mp_karatsuba_sqr) (const mp_int *a, mp_int *b); /* 54 */
- int (*tclBN_mp_toom_mul) (const mp_int *a, const mp_int *b, mp_int *c); /* 55 */
- int (*tclBN_mp_toom_sqr) (const mp_int *a, mp_int *b); /* 56 */
- int (*tclBN_s_mp_add) (const mp_int *a, const mp_int *b, mp_int *c); /* 57 */
- int (*tclBN_s_mp_mul_digs) (const mp_int *a, const mp_int *b, mp_int *c, int digs); /* 58 */
- int (*tclBN_s_mp_sqr) (const mp_int *a, mp_int *b); /* 59 */
- int (*tclBN_s_mp_sub) (const mp_int *a, const mp_int *b, mp_int *c); /* 60 */
+ TCL_DEPRECATED_API("is private function in libtommath") void (*tclBN_reverse) (unsigned char *s, int len); /* 50 */
+ TCL_DEPRECATED_API("is private function in libtommath") int (*tclBN_fast_s_mp_mul_digs) (const mp_int *a, const mp_int *b, mp_int *c, int digs); /* 51 */
+ TCL_DEPRECATED_API("is private function in libtommath") int (*tclBN_fast_s_mp_sqr) (const mp_int *a, mp_int *b); /* 52 */
+ TCL_DEPRECATED_API("is private function in libtommath") int (*tclBN_mp_karatsuba_mul) (const mp_int *a, const mp_int *b, mp_int *c); /* 53 */
+ TCL_DEPRECATED_API("is private function in libtommath") int (*tclBN_mp_karatsuba_sqr) (const mp_int *a, mp_int *b); /* 54 */
+ TCL_DEPRECATED_API("is private function in libtommath") int (*tclBN_mp_toom_mul) (const mp_int *a, const mp_int *b, mp_int *c); /* 55 */
+ TCL_DEPRECATED_API("is private function in libtommath") int (*tclBN_mp_toom_sqr) (const mp_int *a, mp_int *b); /* 56 */
+ TCL_DEPRECATED_API("is private function in libtommath") int (*tclBN_s_mp_add) (const mp_int *a, const mp_int *b, mp_int *c); /* 57 */
+ TCL_DEPRECATED_API("is private function in libtommath") int (*tclBN_s_mp_mul_digs) (const mp_int *a, const mp_int *b, mp_int *c, int digs); /* 58 */
+ TCL_DEPRECATED_API("is private function in libtommath") int (*tclBN_s_mp_sqr) (const mp_int *a, mp_int *b); /* 59 */
+ TCL_DEPRECATED_API("is private function in libtommath") int (*tclBN_s_mp_sub) (const mp_int *a, const mp_int *b, mp_int *c); /* 60 */
int (*tclBN_mp_init_set_int) (mp_int *a, unsigned long i); /* 61 */
int (*tclBN_mp_set_int) (mp_int *a, unsigned long i); /* 62 */
int (*tclBN_mp_cnt_lsb) (const mp_int *a); /* 63 */
@@ -422,6 +429,7 @@ typedef struct TclTomMathStubs {
int (*tclBN_mp_tc_or) (const mp_int *a, const mp_int *b, mp_int *c); /* 74 */
int (*tclBN_mp_tc_xor) (const mp_int *a, const mp_int *b, mp_int *c); /* 75 */
int (*tclBN_mp_tc_div_2d) (const mp_int *a, int b, mp_int *c); /* 76 */
+ int (*tclBN_mp_get_bit) (const mp_int *a, int b); /* 77 */
} TclTomMathStubs;
extern const TclTomMathStubs *tclTomMathStubsPtr;
@@ -590,6 +598,8 @@ extern const TclTomMathStubs *tclTomMathStubsPtr;
(tclTomMathStubsPtr->tclBN_mp_tc_xor) /* 75 */
#define TclBN_mp_tc_div_2d \
(tclTomMathStubsPtr->tclBN_mp_tc_div_2d) /* 76 */
+#define TclBN_mp_get_bit \
+ (tclTomMathStubsPtr->tclBN_mp_get_bit) /* 77 */
#endif /* defined(USE_TCL_STUBS) */
diff --git a/generic/tclTomMathInterface.c b/generic/tclTomMathInterface.c
index 9e7bf4b..236a8cf 100644
--- a/generic/tclTomMathInterface.c
+++ b/generic/tclTomMathInterface.c
@@ -93,39 +93,7 @@ TclBN_revision(void)
/*
*----------------------------------------------------------------------
*
- * TclInitBignumFromLong --
- *
- * Allocate and initialize a 'bignum' from a native 'long'.
- *
- * Results:
- * None.
- *
- * Side effects:
- * The 'bignum' is constructed.
- *
- *----------------------------------------------------------------------
- */
-
-void
-TclInitBignumFromLong(
- mp_int *a,
- long v)
-{
- if (mp_init_size(a, (CHAR_BIT * sizeof(long) + DIGIT_BIT - 1) / DIGIT_BIT) != MP_OKAY) {
- Tcl_Panic("initialization failure in TclInitBignumFromLong");
- }
- if (v < (long)0) {
- mp_set_long_long(a, (Tcl_WideUInt)(-(Tcl_WideInt)v));
- mp_neg(a, a);
- } else {
- mp_set_long_long(a, (Tcl_WideUInt)v);
- }
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * TclBNInitBignumFromWideInt --
+ * TclInitBignumFromWideInt --
*
* Allocate and initialize a 'bignum' from a Tcl_WideInt
*
@@ -146,7 +114,7 @@ TclInitBignumFromWideInt(
if (mp_init_size(a, (CHAR_BIT * sizeof(Tcl_WideUInt) + DIGIT_BIT - 1) / DIGIT_BIT) != MP_OKAY) {
Tcl_Panic("initialization failure in TclInitBignumFromWideInt");
}
- if (v < (Tcl_WideInt)0) {
+ if (v < 0) {
mp_set_long_long(a, (Tcl_WideUInt)(-v));
mp_neg(a, a);
} else {
@@ -157,7 +125,7 @@ TclInitBignumFromWideInt(
/*
*----------------------------------------------------------------------
*
- * TclBNInitBignumFromWideUInt --
+ * TclInitBignumFromWideUInt --
*
* Allocate and initialize a 'bignum' from a Tcl_WideUInt
*
diff --git a/generic/tclTrace.c b/generic/tclTrace.c
index db48f7a..20fa7e7 100644
--- a/generic/tclTrace.c
+++ b/generic/tclTrace.c
@@ -1689,8 +1689,8 @@ CallTraceFunction(
* Copy the command characters into a new string.
*/
- commandCopy = TclStackAlloc(interp, (unsigned) numChars + 1);
- memcpy(commandCopy, command, (size_t) numChars);
+ commandCopy = TclStackAlloc(interp, numChars + 1);
+ memcpy(commandCopy, command, numChars);
commandCopy[numChars] = '\0';
/*
@@ -2275,7 +2275,7 @@ StringTraceProc(
*/
argv = (const char **) TclStackAlloc(interp,
- (unsigned) ((objc + 1) * sizeof(const char *)));
+ (objc + 1) * sizeof(const char *));
for (i = 0; i < objc; i++) {
argv[i] = Tcl_GetString(objv[i]);
}
diff --git a/generic/tclUniData.c b/generic/tclUniData.c
index faca93d..94f5718 100644
--- a/generic/tclUniData.c
+++ b/generic/tclUniData.c
@@ -52,12 +52,12 @@ static const unsigned short pageMap[] = {
7136, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 7168, 7200, 4928, 7232,
7264, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 6560, 6560, 6560,
6560, 7296, 6560, 7328, 7360, 6560, 6560, 6560, 6560, 6560, 6560, 6560,
- 6560, 4928, 7392, 7424, 7456, 7488, 4928, 7520, 7552, 7584, 7616, 7648,
- 7680, 224, 224, 224, 7712, 7744, 7776, 1344, 7808, 7840, 7872, 7872,
- 704, 7904, 7936, 7968, 1824, 8000, 4928, 4928, 8032, 4928, 4928, 4928,
- 4928, 4928, 4928, 8064, 8096, 8128, 8160, 3232, 1344, 8192, 4192, 1344,
- 8224, 8256, 8288, 1344, 1344, 8320, 8352, 4928, 8384, 7552, 8416, 8448,
- 4928, 8416, 8480, 4928, 7552, 4928, 4928, 4928, 4928, 4928, 4928, 4928,
+ 6560, 4928, 7392, 7424, 7456, 7488, 4928, 4928, 4928, 7520, 7552, 7584,
+ 7616, 224, 224, 224, 7648, 7680, 7712, 1344, 7744, 7776, 7808, 7808,
+ 704, 7840, 7872, 7904, 1824, 7936, 4928, 4928, 7968, 4928, 4928, 4928,
+ 4928, 4928, 4928, 8000, 8032, 8064, 8096, 3232, 1344, 8128, 4192, 1344,
+ 8160, 8192, 8224, 1344, 1344, 8256, 8288, 4928, 8320, 8352, 8384, 8416,
+ 4928, 8384, 8448, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928,
4928, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
@@ -130,12 +130,12 @@ static const unsigned short pageMap[] = {
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 8512, 8544, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
+ 8480, 8512, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 8576, 4928, 8608, 5408, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 8640, 8672, 224, 8704, 8736, 1344, 1344, 8768, 8800, 8832, 224,
- 8864, 8896, 8928, 1824, 8960, 8992, 9024, 1344, 9056, 9088, 9120, 9152,
+ 1344, 8544, 4928, 8576, 5408, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
+ 1344, 8608, 8640, 224, 8672, 8704, 1344, 1344, 8736, 8768, 8800, 224,
+ 8832, 8864, 8896, 8928, 8960, 8992, 9024, 1344, 9056, 9088, 9120, 9152,
9184, 1632, 9216, 9248, 9280, 1952, 9312, 9344, 9376, 1344, 9408, 9440,
9472, 1344, 9504, 9536, 9568, 9600, 9632, 9664, 9696, 9728, 9728, 1344,
9760, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
@@ -195,19 +195,19 @@ static const unsigned short pageMap[] = {
1344, 1344, 1344, 1344, 10176, 10208, 1344, 10240, 1344, 10272, 10304,
10336, 10368, 10400, 10432, 1344, 1344, 1344, 10464, 10496, 64, 10528,
10560, 10592, 4736, 10624, 10656
-#if TCL_UTF_MAX > 3
- ,10688, 10720, 10752, 1824, 1344, 1344, 1344, 8352, 10784, 10816, 10848,
+#if TCL_UTF_MAX > 3 || TCL_MAJOR_VERSION > 8 || TCL_MINOR_VERSION > 6
+ ,10688, 10720, 10752, 1824, 1344, 1344, 1344, 8288, 10784, 10816, 10848,
10880, 10912, 10944, 10976, 11008, 1824, 1824, 1824, 1824, 9280, 1344,
11040, 11072, 1344, 11104, 11136, 11168, 11200, 1344, 11232, 1824,
11264, 11296, 11328, 1344, 11360, 11392, 11424, 11456, 1344, 11488,
1344, 11520, 1824, 1824, 1824, 1824, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 1344, 7840, 4704, 10272, 1824, 1824, 1824, 1824,
+ 1344, 1344, 1344, 1344, 7776, 4704, 10272, 1824, 1824, 1824, 1824,
11552, 11584, 11616, 11648, 4736, 11680, 1824, 11712, 11744, 11776,
1824, 1824, 1344, 11808, 11840, 6880, 11872, 11904, 11936, 11968, 12000,
1824, 12032, 12064, 1344, 12096, 12128, 12160, 12192, 12224, 1824,
1824, 1344, 1344, 12256, 1824, 12288, 12320, 12352, 12384, 1344, 12416,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 12448, 1824,
- 1824, 1824, 1824, 12000, 12480, 12512, 1824, 1824, 1824, 1824, 1824,
+ 1824, 1824, 1824, 12000, 12480, 12512, 1824, 1824, 1824, 1824, 7776,
12544, 12576, 12608, 12640, 5248, 12672, 12704, 12736, 12768, 12800,
12832, 12864, 5248, 12896, 12928, 12960, 12992, 13024, 1824, 1824,
13056, 13088, 13120, 13152, 13184, 13216, 13248, 13280, 1824, 1824,
@@ -215,15 +215,15 @@ static const unsigned short pageMap[] = {
1824, 1824, 1824, 1344, 13440, 13472, 1824, 1344, 13504, 13536, 13568,
1344, 13600, 13632, 1824, 4032, 13664, 1824, 1824, 1824, 1824, 1824,
1824, 1344, 13696, 1824, 1824, 1824, 13728, 13760, 13792, 1824, 1824,
- 1824, 1824, 1824, 1824, 1824, 1824, 13824, 13856, 13888, 1344, 13920,
- 13952, 1344, 4608, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
- 13984, 14016, 14048, 14080, 14112, 14144, 1824, 1824, 14176, 14208,
- 14240, 14272, 14304, 13632, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
- 1824, 1824, 14336, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
+ 1824, 1824, 1824, 13824, 13856, 13888, 13920, 13952, 13984, 1344, 14016,
+ 14048, 1344, 4608, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
+ 14080, 14112, 14144, 14176, 14208, 14240, 1824, 1824, 14272, 14304,
+ 14336, 14368, 14400, 13632, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
+ 1824, 1824, 14432, 1824, 1824, 1824, 1824, 1824, 1824, 14464, 14496,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 9984, 1824, 1824, 1824, 10848, 10848, 10848,
- 14368, 1344, 1344, 1344, 1344, 1344, 1344, 14400, 1824, 1824, 1824,
+ 14528, 1344, 1344, 1344, 1344, 1344, 1344, 14560, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
@@ -233,7 +233,7 @@ static const unsigned short pageMap[] = {
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 1344, 1344, 1344, 1344, 14432, 1824, 1824, 1824,
+ 1344, 1344, 1344, 1344, 1344, 1344, 1344, 14592, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
@@ -245,7 +245,7 @@ static const unsigned short pageMap[] = {
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 14464, 1824,
+ 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 14624, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
@@ -269,11 +269,11 @@ static const unsigned short pageMap[] = {
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 4608, 4736, 14496,
- 1824, 1824, 10208, 14528, 1344, 14560, 14592, 14624, 8512, 1824, 1824,
+ 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 4608, 4736, 14656,
+ 1824, 1824, 10208, 14688, 1344, 14720, 14752, 14784, 8480, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
- 1824, 1824, 1824, 1824, 1824, 1824, 1824, 13728, 13760, 14656, 1824,
- 1824, 1824, 1344, 1344, 14688, 14720, 14752, 1824, 1824, 14784, 1344,
+ 1824, 1824, 1824, 1824, 1824, 1824, 1824, 13728, 13760, 14816, 1824,
+ 1824, 1824, 1344, 1344, 14848, 14880, 14912, 1824, 1824, 14944, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
@@ -289,9 +289,9 @@ static const unsigned short pageMap[] = {
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 14816,
+ 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 14976,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 14848,
+ 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 15008,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
@@ -317,7 +317,7 @@ static const unsigned short pageMap[] = {
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 1344, 4736, 1824, 1824, 10208, 1344, 1344, 1344,
+ 1344, 1344, 1344, 1344, 4736, 1824, 15040, 15072, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 9856, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
@@ -325,7 +325,7 @@ static const unsigned short pageMap[] = {
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1344, 1344, 1344,
- 14880, 14912, 14944, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
+ 15104, 15136, 15168, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
@@ -338,42 +338,41 @@ static const unsigned short pageMap[] = {
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
- 1824, 1824, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 8064, 4928, 14976,
- 4928, 15008, 15040, 15072, 4928, 15104, 4928, 4928, 15136, 1824, 1824,
- 1824, 1824, 15168, 4928, 4928, 15200, 15232, 1824, 1824, 1824, 1824,
- 15264, 15296, 15328, 15360, 15392, 15424, 15456, 15488, 15520, 15552,
- 15584, 15616, 15648, 15264, 15296, 15680, 15360, 15712, 15744, 15776,
- 15488, 15808, 15840, 15872, 15904, 15936, 15968, 16000, 16032, 16064,
- 16096, 16128, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928,
- 4928, 4928, 4928, 4928, 4928, 4928, 4928, 704, 16160, 704, 16192, 16224,
- 16256, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
+ 1824, 1824, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 8000, 4928, 15200,
+ 4928, 15232, 15264, 15296, 4928, 15328, 4928, 4928, 15360, 1824, 1824,
+ 1824, 1824, 15392, 4928, 4928, 15424, 15456, 1824, 1824, 1824, 1824,
+ 15488, 15520, 15552, 15584, 15616, 15648, 15680, 15712, 15744, 15776,
+ 15808, 15840, 15872, 15488, 15520, 15904, 15584, 15936, 15968, 16000,
+ 15712, 16032, 16064, 16096, 16128, 16160, 16192, 16224, 16256, 16288,
+ 16320, 16352, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928,
+ 4928, 4928, 4928, 4928, 4928, 4928, 4928, 704, 16384, 704, 16416, 16448,
+ 16480, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
- 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 16288, 16320, 1824,
+ 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 16512, 16544, 1824,
+ 1824, 1824, 1824, 1824, 1824, 1344, 16576, 16608, 1824, 1824, 1824,
+ 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1344, 16640, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
+ 1824, 1824, 1824, 1344, 1344, 1344, 1344, 1344, 1344, 16672, 1824,
+ 16704, 16736, 16768, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
- 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
- 1824, 1344, 1344, 1344, 1344, 1344, 1344, 16352, 1824, 16384, 16416,
- 16448, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
- 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
- 1824, 1824, 16480, 6880, 16512, 1824, 1824, 1824, 1824, 1824, 1824,
- 1824, 1824, 1824, 1824, 16544, 16576, 16608, 16640, 16672, 16704, 1824,
- 16736, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 4928, 16768,
- 4928, 4928, 8032, 16800, 16832, 8064, 16864, 4928, 4928, 16768, 4928,
- 16896, 1824, 16928, 16960, 16992, 17024, 17056, 1824, 1824, 1824, 1824,
- 4928, 4928, 4928, 4928, 4928, 4928, 4928, 17088, 4928, 4928, 4928,
+ 1824, 1824, 1824, 1824, 16800, 6880, 16832, 1824, 1824, 16864, 16896,
+ 1824, 1824, 1824, 1824, 1824, 1824, 16928, 16960, 16992, 17024, 17056,
+ 17088, 1824, 17120, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
+ 4928, 17152, 4928, 4928, 7968, 17184, 17216, 8000, 17248, 4928, 4928,
+ 17280, 4928, 17312, 1824, 17344, 17376, 17408, 17440, 17472, 1824,
+ 1824, 1824, 1824, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 17504,
4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928,
- 4928, 4928, 4928, 4928, 4928, 4928, 4928, 17120, 17152, 4928, 4928,
- 4928, 8032, 4928, 4928, 17184, 1824, 16768, 4928, 17216, 4928, 17248,
- 17280, 1824, 1824, 16768, 7552, 4928, 17312, 4928, 17344, 16960, 4928,
- 1824, 1824, 1824, 17280, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
+ 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 4928, 8000, 17536,
+ 4928, 4928, 4928, 7968, 4928, 4928, 17568, 17600, 17152, 4928, 17632,
+ 4928, 17664, 17696, 1824, 1824, 17728, 4928, 4928, 17760, 4928, 17792,
+ 17824, 4928, 4928, 4928, 7968, 17856, 17888, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
- 1824, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
+ 1824, 1824, 1824, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
@@ -483,8 +482,8 @@ static const unsigned short pageMap[] = {
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 7840, 1824, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
+ 1344, 1344, 1344, 1344, 1344, 7776, 1824, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
@@ -494,8 +493,9 @@ static const unsigned short pageMap[] = {
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 17376, 1344, 1344, 1344, 1344, 1344, 1344, 11360, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
+ 1344, 1344, 1344, 1344, 17920, 1344, 1344, 1344, 1344, 1344, 1344,
+ 11360, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
@@ -509,8 +509,8 @@ static const unsigned short pageMap[] = {
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 17408,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
+ 1344, 1344, 17952, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
@@ -529,7 +529,7 @@ static const unsigned short pageMap[] = {
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 1344, 1344, 17440, 1824, 1824, 1824, 1824, 1824,
+ 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 17984, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
@@ -537,8 +537,9 @@ static const unsigned short pageMap[] = {
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824,
- 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1344, 1344, 1344, 1344, 1344,
- 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 11360
+ 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1824, 1344,
+ 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344, 1344,
+ 1344, 1344, 1344, 11360
#endif /* TCL_UTF_MAX > 3 */
};
@@ -581,578 +582,578 @@ static const unsigned char groupMap[] = {
59, 60, 61, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 62, 63, 64, 65,
66, 21, 67, 67, 21, 68, 21, 69, 70, 21, 21, 21, 67, 71, 21, 72, 21,
73, 74, 21, 75, 76, 74, 77, 78, 21, 21, 76, 21, 79, 80, 21, 21, 81,
- 21, 21, 21, 21, 21, 21, 21, 82, 21, 21, 83, 21, 21, 83, 21, 21, 21,
- 84, 83, 85, 86, 86, 87, 21, 21, 21, 21, 21, 88, 21, 15, 21, 21, 21,
- 21, 21, 21, 21, 21, 89, 90, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 11, 11, 11, 11, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- 11, 11, 11, 11, 91, 91, 91, 91, 91, 11, 11, 11, 11, 11, 11, 11, 91,
- 11, 91, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- 11, 11, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 93, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 23, 24, 23,
- 24, 91, 11, 23, 24, 0, 0, 91, 42, 42, 42, 3, 94, 0, 0, 0, 0, 11, 11,
- 95, 3, 96, 96, 96, 0, 97, 0, 98, 98, 21, 10, 10, 10, 10, 10, 10, 10,
+ 21, 21, 21, 21, 21, 21, 21, 82, 21, 21, 83, 21, 84, 83, 21, 21, 21,
+ 85, 83, 86, 87, 87, 88, 21, 21, 21, 21, 21, 89, 21, 15, 21, 21, 21,
+ 21, 21, 21, 21, 21, 90, 91, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 21, 21, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
+ 92, 92, 92, 92, 92, 92, 92, 92, 11, 11, 11, 11, 92, 92, 92, 92, 92,
+ 92, 92, 92, 92, 92, 92, 92, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
+ 11, 11, 11, 11, 92, 92, 92, 92, 92, 11, 11, 11, 11, 11, 11, 11, 92,
+ 11, 92, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
+ 11, 11, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 94, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 23, 24, 23,
+ 24, 92, 11, 23, 24, 0, 0, 92, 42, 42, 42, 3, 95, 0, 0, 0, 0, 11, 11,
+ 96, 3, 97, 97, 97, 0, 98, 0, 99, 99, 21, 10, 10, 10, 10, 10, 10, 10,
10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 10, 10, 10, 10, 10, 10,
- 10, 10, 10, 99, 100, 100, 100, 21, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 101, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 102, 103, 103, 104, 105, 106, 107, 107, 107, 108, 109, 110,
+ 10, 10, 10, 100, 101, 101, 101, 21, 13, 13, 13, 13, 13, 13, 13, 13,
+ 13, 13, 13, 13, 13, 13, 13, 13, 13, 102, 13, 13, 13, 13, 13, 13, 13,
+ 13, 13, 103, 104, 104, 105, 106, 107, 108, 108, 108, 109, 110, 111,
23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23,
- 24, 23, 24, 23, 24, 23, 24, 111, 112, 113, 114, 115, 116, 7, 23, 24,
- 117, 23, 24, 21, 54, 54, 54, 118, 118, 118, 118, 118, 118, 118, 118,
- 118, 118, 118, 118, 118, 118, 118, 118, 10, 10, 10, 10, 10, 10, 10,
+ 24, 23, 24, 23, 24, 23, 24, 112, 113, 114, 115, 116, 117, 7, 23, 24,
+ 118, 23, 24, 21, 54, 54, 54, 119, 119, 119, 119, 119, 119, 119, 119,
+ 119, 119, 119, 119, 119, 119, 119, 119, 10, 10, 10, 10, 10, 10, 10,
10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
10, 10, 10, 10, 10, 10, 10, 10, 13, 13, 13, 13, 13, 13, 13, 13, 13,
13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 112, 112, 112, 112, 112, 112, 112, 112, 112,
- 112, 112, 112, 112, 112, 112, 112, 23, 24, 14, 92, 92, 92, 92, 92,
- 119, 119, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23,
- 24, 23, 24, 23, 24, 23, 24, 120, 23, 24, 23, 24, 23, 24, 23, 24, 23,
- 24, 23, 24, 23, 24, 121, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23,
+ 13, 13, 13, 13, 13, 13, 113, 113, 113, 113, 113, 113, 113, 113, 113,
+ 113, 113, 113, 113, 113, 113, 113, 23, 24, 14, 93, 93, 93, 93, 93,
+ 120, 120, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23,
+ 24, 23, 24, 23, 24, 23, 24, 121, 23, 24, 23, 24, 23, 24, 23, 24, 23,
+ 24, 23, 24, 23, 24, 122, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23,
24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24,
- 23, 24, 23, 24, 0, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122,
- 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122,
- 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122,
- 0, 0, 91, 3, 3, 3, 3, 3, 3, 21, 123, 123, 123, 123, 123, 123, 123,
+ 23, 24, 23, 24, 0, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123,
123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123,
123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123,
- 123, 123, 123, 21, 21, 3, 8, 0, 0, 14, 14, 4, 0, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 8, 92, 3, 92, 92, 3, 92, 92, 3, 92, 0, 0, 0,
+ 0, 0, 92, 3, 3, 3, 3, 3, 3, 21, 124, 124, 124, 124, 124, 124, 124,
+ 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124,
+ 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124,
+ 124, 124, 124, 21, 21, 3, 8, 0, 0, 14, 14, 4, 0, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 8, 93, 3, 93, 93, 3, 93, 93, 3, 93, 0, 0, 0,
0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0,
15, 15, 15, 15, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 17, 17, 17,
- 17, 17, 17, 7, 7, 7, 3, 3, 4, 3, 3, 14, 14, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 3, 17, 0, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15,
+ 17, 17, 17, 7, 7, 7, 3, 3, 4, 3, 3, 14, 14, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 3, 17, 0, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 91, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 3, 3, 3, 15, 15,
- 92, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 92, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 3, 3, 3, 15, 15,
+ 93, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 3, 15, 92, 92, 92, 92, 92, 92, 92, 17, 14, 92, 92, 92, 92,
- 92, 92, 91, 91, 92, 92, 14, 92, 92, 92, 92, 15, 15, 9, 9, 9, 9, 9,
+ 15, 15, 3, 15, 93, 93, 93, 93, 93, 93, 93, 17, 14, 93, 93, 93, 93,
+ 93, 93, 92, 92, 93, 93, 14, 93, 93, 93, 93, 15, 15, 9, 9, 9, 9, 9,
9, 9, 9, 9, 9, 15, 15, 15, 14, 14, 15, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 0, 17, 15, 92, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 3, 3, 3, 3, 0, 17, 15, 93, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 0, 0, 15, 15, 15,
+ 15, 15, 15, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 0, 0, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 15,
+ 15, 15, 15, 15, 15, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 15,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9,
9, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 91, 91, 14, 3, 3, 3, 91, 0, 0,
- 92, 4, 4, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 92, 92, 92, 92, 91, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 91, 92, 92, 92, 91, 92, 92, 92, 92, 92, 0, 0, 3, 3,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 92, 92, 14, 3, 3, 3, 92, 0, 0,
+ 93, 4, 4, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 93, 93, 93, 93, 92, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 92, 93, 93, 93, 92, 93, 93, 93, 93, 93, 0, 0, 3, 3,
3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 92, 92, 92, 0, 0, 3, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 93, 93, 93, 0, 0, 3, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15,
15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 17,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 124, 15,
+ 0, 0, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 17,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 125, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 92, 124, 92, 15, 124, 124, 124, 92, 92, 92, 92, 92, 92, 92,
- 92, 124, 124, 124, 124, 92, 124, 124, 15, 92, 92, 92, 92, 92, 92, 92,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 3, 3, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 3, 91, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 92, 124, 124, 0, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0,
+ 15, 15, 93, 125, 93, 15, 125, 125, 125, 93, 93, 93, 93, 93, 93, 93,
+ 93, 125, 125, 125, 125, 93, 125, 125, 15, 93, 93, 93, 93, 93, 93, 93,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 3, 3, 9, 9, 9, 9, 9,
+ 9, 9, 9, 9, 9, 3, 92, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 93, 125, 125, 0, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0,
15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15,
- 0, 0, 0, 15, 15, 15, 15, 0, 0, 92, 15, 124, 124, 124, 92, 92, 92, 92,
- 0, 0, 124, 124, 0, 0, 124, 124, 92, 15, 0, 0, 0, 0, 0, 0, 0, 0, 124,
- 0, 0, 0, 0, 15, 15, 0, 15, 15, 15, 92, 92, 0, 0, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 15, 15, 4, 4, 18, 18, 18, 18, 18, 18, 14, 4, 15, 3, 92,
- 0, 0, 92, 92, 124, 0, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 15, 15, 0,
+ 0, 0, 0, 15, 15, 15, 15, 0, 0, 93, 15, 125, 125, 125, 93, 93, 93, 93,
+ 0, 0, 125, 125, 0, 0, 125, 125, 93, 15, 0, 0, 0, 0, 0, 0, 0, 0, 125,
+ 0, 0, 0, 0, 15, 15, 0, 15, 15, 15, 93, 93, 0, 0, 9, 9, 9, 9, 9, 9,
+ 9, 9, 9, 9, 15, 15, 4, 4, 18, 18, 18, 18, 18, 18, 14, 4, 15, 3, 93,
+ 0, 0, 93, 93, 125, 0, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 15, 15, 0,
0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 0,
- 15, 15, 0, 15, 15, 0, 0, 92, 0, 124, 124, 124, 92, 92, 0, 0, 0, 0,
- 92, 92, 0, 0, 92, 92, 92, 0, 0, 0, 92, 0, 0, 0, 0, 0, 0, 0, 15, 15,
- 15, 15, 0, 15, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 92,
- 92, 15, 15, 15, 92, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 92, 92, 124, 0,
+ 15, 15, 0, 15, 15, 0, 0, 93, 0, 125, 125, 125, 93, 93, 0, 0, 0, 0,
+ 93, 93, 0, 0, 93, 93, 93, 0, 0, 0, 93, 0, 0, 0, 0, 0, 0, 0, 15, 15,
+ 15, 15, 0, 15, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 93,
+ 93, 15, 15, 15, 93, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 93, 93, 125, 0,
15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 0, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 0, 15, 15, 15, 15, 15,
- 0, 0, 92, 15, 124, 124, 124, 92, 92, 92, 92, 92, 0, 92, 92, 124, 0,
- 124, 124, 92, 0, 0, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 15, 15, 92, 92, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 4, 0, 0, 0,
- 0, 0, 0, 0, 15, 92, 92, 92, 92, 92, 92, 0, 92, 124, 124, 0, 15, 15,
+ 0, 0, 93, 15, 125, 125, 125, 93, 93, 93, 93, 93, 0, 93, 93, 125, 0,
+ 125, 125, 93, 0, 0, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 15, 15, 93, 93, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 4, 0, 0, 0,
+ 0, 0, 0, 0, 15, 93, 93, 93, 93, 93, 93, 0, 93, 125, 125, 0, 15, 15,
15, 15, 15, 15, 15, 15, 0, 0, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0,
15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 0, 15, 15, 15, 15, 15, 0, 0,
- 92, 15, 124, 92, 124, 92, 92, 92, 92, 0, 0, 124, 124, 0, 0, 124, 124,
- 92, 0, 0, 0, 0, 0, 0, 0, 0, 92, 124, 0, 0, 0, 0, 15, 15, 0, 15, 15,
- 15, 92, 92, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 14, 15, 18, 18, 18,
- 18, 18, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 92, 15, 0, 15, 15, 15, 15,
+ 93, 15, 125, 93, 125, 93, 93, 93, 93, 0, 0, 125, 125, 0, 0, 125, 125,
+ 93, 0, 0, 0, 0, 0, 0, 0, 0, 93, 125, 0, 0, 0, 0, 15, 15, 0, 15, 15,
+ 15, 93, 93, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 14, 15, 18, 18, 18,
+ 18, 18, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 93, 15, 0, 15, 15, 15, 15,
15, 15, 0, 0, 0, 15, 15, 15, 0, 15, 15, 15, 15, 0, 0, 0, 15, 15, 0,
15, 0, 15, 15, 0, 0, 0, 15, 15, 0, 0, 0, 15, 15, 15, 0, 0, 0, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 124, 124, 92, 124,
- 124, 0, 0, 0, 124, 124, 124, 0, 124, 124, 124, 92, 0, 0, 15, 0, 0,
- 0, 0, 0, 0, 124, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 125, 125, 93, 125,
+ 125, 0, 0, 0, 125, 125, 125, 0, 125, 125, 125, 93, 0, 0, 15, 0, 0,
+ 0, 0, 0, 0, 125, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9,
9, 9, 9, 9, 9, 9, 9, 18, 18, 18, 14, 14, 14, 14, 14, 14, 4, 14, 0,
- 0, 0, 0, 0, 92, 124, 124, 124, 92, 15, 15, 15, 15, 15, 15, 15, 15,
+ 0, 0, 0, 0, 93, 125, 125, 125, 93, 15, 15, 15, 15, 15, 15, 15, 15,
0, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 15, 92, 92, 92, 124,
- 124, 124, 124, 0, 92, 92, 92, 0, 92, 92, 92, 92, 0, 0, 0, 0, 0, 0,
- 0, 92, 92, 0, 15, 15, 15, 0, 0, 0, 0, 0, 15, 15, 92, 92, 0, 0, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 0, 0, 18, 18, 18, 18, 18,
- 18, 18, 14, 15, 92, 124, 124, 3, 15, 15, 15, 15, 15, 15, 15, 15, 0,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 15, 93, 93, 93, 125,
+ 125, 125, 125, 0, 93, 93, 93, 0, 93, 93, 93, 93, 0, 0, 0, 0, 0, 0,
+ 0, 93, 93, 0, 15, 15, 15, 0, 0, 0, 0, 0, 15, 15, 93, 93, 0, 0, 9, 9,
+ 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 0, 3, 18, 18, 18, 18, 18,
+ 18, 18, 14, 15, 93, 125, 125, 3, 15, 15, 15, 15, 15, 15, 15, 15, 0,
15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 0, 0, 92, 15, 124, 92, 124,
- 124, 124, 124, 124, 0, 92, 124, 124, 0, 124, 124, 92, 92, 0, 0, 0,
- 0, 0, 0, 0, 124, 124, 0, 0, 0, 0, 0, 0, 0, 15, 0, 15, 15, 92, 92, 0,
+ 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 0, 0, 93, 15, 125, 93, 125,
+ 125, 125, 125, 125, 0, 93, 125, 125, 0, 125, 125, 93, 93, 0, 0, 0,
+ 0, 0, 0, 0, 125, 125, 0, 0, 0, 0, 0, 0, 0, 15, 0, 15, 15, 93, 93, 0,
0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 92, 92, 124, 124, 0, 15, 15, 15, 15, 15, 15, 15, 15,
+ 0, 0, 0, 0, 0, 93, 93, 125, 125, 0, 15, 15, 15, 15, 15, 15, 15, 15,
0, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 15, 124, 124, 124,
- 92, 92, 92, 92, 0, 124, 124, 124, 0, 124, 124, 124, 92, 15, 14, 0,
- 0, 0, 0, 15, 15, 15, 124, 18, 18, 18, 18, 18, 18, 18, 15, 15, 15, 92,
- 92, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 18, 18, 18, 18, 18, 18, 18,
- 18, 18, 14, 15, 15, 15, 15, 15, 15, 0, 0, 124, 124, 0, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 15, 125, 125, 125,
+ 93, 93, 93, 93, 0, 125, 125, 125, 0, 125, 125, 125, 93, 15, 14, 0,
+ 0, 0, 0, 15, 15, 15, 125, 18, 18, 18, 18, 18, 18, 18, 15, 15, 15, 93,
+ 93, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 14, 15, 15, 15, 15, 15, 15, 0, 0, 125, 125, 0, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 0, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 92, 0, 0, 0, 0, 124,
- 124, 124, 92, 92, 92, 0, 92, 0, 124, 124, 124, 124, 124, 124, 124,
- 124, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 124, 124,
+ 0, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 93, 0, 0, 0, 0, 125,
+ 125, 125, 93, 93, 93, 0, 93, 0, 125, 125, 125, 125, 125, 125, 125,
+ 125, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 125, 125,
3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 92, 15, 15, 92, 92, 92, 92, 92, 92, 92,
- 0, 0, 0, 0, 4, 15, 15, 15, 15, 15, 15, 91, 92, 92, 92, 92, 92, 92,
- 92, 92, 3, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 3, 0, 0, 0, 0, 0, 15, 15,
- 0, 15, 0, 0, 15, 15, 0, 15, 0, 0, 15, 0, 0, 0, 0, 0, 0, 15, 15, 15,
- 15, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 0, 15, 0, 15, 0,
- 0, 15, 15, 0, 15, 15, 15, 15, 92, 15, 15, 92, 92, 92, 92, 92, 92, 0,
- 92, 92, 15, 0, 0, 15, 15, 15, 15, 15, 0, 91, 0, 92, 92, 92, 92, 92,
- 92, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 15, 15, 15, 15, 15, 14,
- 14, 14, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 14, 3, 14, 14,
- 14, 92, 92, 14, 14, 14, 14, 14, 14, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 18,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 14, 92, 14, 92, 14, 92, 5, 6, 5,
- 6, 124, 124, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 124, 92, 92,
- 92, 92, 92, 3, 92, 92, 15, 15, 15, 15, 15, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 0, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 0, 14, 14, 14, 14, 14, 14, 14, 14,
- 92, 14, 14, 14, 14, 14, 14, 0, 14, 14, 3, 3, 3, 3, 3, 14, 14, 14, 14,
- 3, 3, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 124,
- 124, 92, 92, 92, 92, 124, 92, 92, 92, 92, 92, 92, 124, 92, 92, 124,
- 124, 92, 92, 15, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 3, 3, 3, 3, 3, 15,
- 15, 15, 15, 15, 15, 124, 124, 92, 92, 15, 15, 15, 15, 92, 92, 92, 15,
- 124, 124, 124, 15, 15, 124, 124, 124, 124, 124, 124, 124, 15, 15, 15,
- 92, 92, 92, 92, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 92, 124, 124, 92, 92, 124, 124, 124, 124, 124, 124, 92, 15, 124, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 124, 124, 124, 92, 14, 14, 125, 125, 125,
- 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125,
- 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125,
- 125, 125, 125, 125, 125, 125, 125, 0, 125, 0, 0, 0, 0, 0, 125, 0, 0,
- 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126,
- 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126,
+ 15, 15, 15, 15, 15, 15, 15, 93, 15, 15, 93, 93, 93, 93, 93, 93, 93,
+ 0, 0, 0, 0, 4, 15, 15, 15, 15, 15, 15, 92, 93, 93, 93, 93, 93, 93,
+ 93, 93, 3, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 3, 0, 0, 0, 0, 0, 15, 15,
+ 0, 15, 0, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15,
+ 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 15, 15, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 15, 0, 0, 15, 15, 15, 15, 15, 0, 92, 0, 93,
+ 93, 93, 93, 93, 93, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 15, 15,
+ 15, 15, 15, 14, 14, 14, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
+ 14, 3, 14, 14, 14, 93, 93, 14, 14, 14, 14, 14, 14, 9, 9, 9, 9, 9, 9,
+ 9, 9, 9, 9, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 14, 93, 14, 93,
+ 14, 93, 5, 6, 5, 6, 125, 125, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 0, 0, 0, 0, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 125, 93, 93, 93, 93, 93, 3, 93, 93, 15, 15, 15, 15, 15, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 0, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 0, 14, 14, 14, 14,
+ 14, 14, 14, 14, 93, 14, 14, 14, 14, 14, 14, 0, 14, 14, 3, 3, 3, 3,
+ 3, 14, 14, 14, 14, 3, 3, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 125, 125, 93, 93, 93, 93, 125, 93, 93, 93, 93, 93,
+ 93, 125, 93, 93, 125, 125, 93, 93, 15, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
+ 3, 3, 3, 3, 3, 3, 15, 15, 15, 15, 15, 15, 125, 125, 93, 93, 15, 15,
+ 15, 15, 93, 93, 93, 15, 125, 125, 125, 15, 15, 125, 125, 125, 125,
+ 125, 125, 125, 15, 15, 15, 93, 93, 93, 93, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 93, 125, 125, 93, 93, 125, 125, 125, 125,
+ 125, 125, 93, 15, 125, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 125, 125, 125,
+ 93, 14, 14, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126,
126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126,
- 126, 3, 91, 126, 126, 126, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15,
- 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15, 0, 15, 15, 15,
- 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 0,
- 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 0, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15, 0, 15,
- 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 0, 0,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 0, 0, 92, 92, 92, 3, 3, 3, 3, 3, 3, 3, 3, 3, 18, 18, 18, 18, 18,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 127, 127, 127,
- 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127,
+ 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 0,
+ 126, 0, 0, 0, 0, 0, 126, 0, 0, 127, 127, 127, 127, 127, 127, 127, 127,
127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127,
127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127,
- 127, 127, 127, 104, 104, 104, 104, 104, 104, 0, 0, 110, 110, 110, 110,
- 110, 110, 0, 0, 8, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 127, 127, 127, 127, 127, 127, 127, 3, 92, 127, 127, 127, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15, 15,
+ 15, 15, 0, 15, 0, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 0, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 3, 3, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 2,
+ 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15,
+ 15, 15, 15, 0, 15, 0, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 5, 6, 0, 0, 0, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 3, 3, 3, 128, 128, 128, 15, 15, 15, 15,
- 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 92, 92, 92, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 92, 92, 92, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15,
+ 15, 0, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 93, 93, 93, 3, 3, 3, 3, 3, 3,
+ 3, 3, 3, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0,
+ 0, 0, 0, 0, 0, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128,
+ 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128,
+ 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128,
+ 128, 128, 128, 128, 128, 128, 128, 128, 128, 105, 105, 105, 105, 105,
+ 105, 0, 0, 111, 111, 111, 111, 111, 111, 0, 0, 8, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 92, 92, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 0, 92, 92, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 124, 92, 92, 92, 92, 92, 92,
- 92, 124, 124, 124, 124, 124, 124, 124, 124, 92, 124, 124, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 3, 3, 3, 91, 3, 3, 3, 4, 15, 92, 0,
- 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 18, 18, 18, 18,
- 18, 18, 18, 18, 18, 18, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 3, 8, 3, 3,
- 3, 3, 92, 92, 92, 17, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0,
- 0, 0, 15, 15, 15, 91, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 14, 3, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 2, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 5, 6, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 3, 3, 3,
+ 129, 129, 129, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15,
+ 15, 93, 93, 93, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 93, 3,
+ 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15,
+ 15, 15, 0, 93, 93, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15,
- 92, 92, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 93, 93, 125, 93, 93, 93, 93, 93, 93, 93, 125, 125, 125, 125, 125, 125,
+ 125, 125, 93, 125, 125, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 3, 3, 3, 92, 3, 3, 3, 4, 15, 93, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
+ 0, 0, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0,
+ 0, 0, 0, 3, 3, 3, 3, 3, 3, 8, 3, 3, 3, 3, 93, 93, 93, 17, 0, 9, 9,
+ 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 15, 15, 15, 92, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 92, 15, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0,
- 92, 92, 92, 124, 124, 124, 124, 92, 92, 124, 124, 124, 0, 0, 0, 0,
- 124, 124, 92, 124, 124, 124, 124, 124, 124, 92, 92, 92, 0, 0, 0, 0,
- 14, 0, 0, 0, 3, 3, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 15, 15, 15, 15, 15,
+ 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 93, 93, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0,
- 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 18, 0, 0, 0, 14, 14, 14, 14, 14, 14,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 15, 0, 0, 0, 0, 0,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 0, 93, 93, 93, 125, 125, 125, 125,
+ 93, 93, 125, 125, 125, 0, 0, 0, 0, 125, 125, 93, 125, 125, 125, 125,
+ 125, 125, 93, 93, 93, 0, 0, 0, 0, 14, 0, 0, 0, 3, 3, 9, 9, 9, 9, 9,
+ 9, 9, 9, 9, 9, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 0, 0, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
+ 18, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 92, 92, 124, 124, 92, 0, 0, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 124, 92, 124, 92, 92,
- 92, 92, 92, 92, 92, 0, 92, 124, 92, 124, 124, 92, 92, 92, 92, 92, 92,
- 92, 92, 124, 124, 124, 124, 124, 124, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 0, 0, 92, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 3, 3, 91,
- 3, 3, 3, 3, 3, 3, 0, 0, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 119, 0, 92, 92, 92, 92, 124, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 92, 124, 92, 92, 92, 92, 92, 124, 92, 124,
- 124, 124, 124, 124, 92, 124, 124, 15, 15, 15, 15, 15, 15, 15, 0, 0,
- 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 3, 3, 3, 3, 3, 3, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 92, 92, 92, 92, 92, 92, 92, 92, 92, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 92, 92, 124, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 124, 92, 92, 92, 92, 124, 124,
- 92, 92, 124, 92, 92, 92, 15, 15, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 124, 92, 92, 124, 124,
- 124, 92, 124, 92, 92, 92, 124, 124, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3,
- 3, 15, 15, 15, 15, 124, 124, 124, 124, 124, 124, 124, 124, 92, 92,
- 92, 92, 92, 92, 92, 92, 124, 124, 92, 92, 0, 0, 0, 3, 3, 3, 3, 3, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 15, 15, 15, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 91, 91,
- 91, 91, 91, 91, 3, 3, 129, 130, 131, 132, 132, 133, 134, 135, 136,
- 0, 0, 0, 0, 0, 0, 0, 137, 137, 137, 137, 137, 137, 137, 137, 137, 137,
- 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, 137,
- 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, 137,
- 137, 137, 137, 137, 137, 0, 0, 137, 137, 137, 3, 3, 3, 3, 3, 3, 3,
- 3, 0, 0, 0, 0, 0, 0, 0, 0, 92, 92, 92, 3, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 124, 92, 92, 92, 92, 92, 92, 92, 15, 15, 15,
- 15, 92, 15, 15, 15, 15, 124, 124, 92, 15, 15, 124, 92, 92, 0, 0, 0,
- 0, 0, 0, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
+ 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 125, 125, 93, 0, 0, 3,
+ 3, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 125, 93, 125, 93, 93, 93, 93, 93, 93, 93, 0, 93,
+ 125, 93, 125, 125, 93, 93, 93, 93, 93, 93, 93, 93, 125, 125, 125, 125,
+ 125, 125, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 0, 0, 93, 9, 9, 9,
+ 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
+ 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 3, 3, 92, 3, 3, 3, 3, 3, 3, 0, 0,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 120, 0, 93,
+ 93, 93, 93, 125, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 93, 125, 93, 93, 93, 93, 93, 125, 93, 125, 125, 125, 125, 125, 93,
+ 125, 125, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9,
+ 9, 9, 9, 9, 3, 3, 3, 3, 3, 3, 3, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 93, 93, 93, 93, 93, 93, 93, 93, 93, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 0, 0, 0, 93, 93, 125, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 125, 93, 93, 93, 93, 125, 125, 93, 93, 125, 93, 93, 93,
+ 15, 15, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 93, 125, 93, 93, 125, 125, 125, 93, 125, 93, 93, 93,
+ 125, 125, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 15, 15, 15, 15, 125,
+ 125, 125, 125, 125, 125, 125, 125, 93, 93, 93, 93, 93, 93, 93, 93,
+ 125, 125, 93, 93, 0, 0, 0, 3, 3, 3, 3, 3, 9, 9, 9, 9, 9, 9, 9, 9, 9,
+ 9, 0, 0, 0, 15, 15, 15, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 92, 92, 92, 92, 3, 3, 130,
+ 131, 132, 133, 133, 134, 135, 136, 137, 0, 0, 0, 0, 0, 0, 0, 138, 138,
+ 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138,
+ 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138,
+ 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 0,
+ 0, 138, 138, 138, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 93,
+ 93, 93, 3, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 125,
+ 93, 93, 93, 93, 93, 93, 93, 15, 15, 15, 15, 93, 15, 15, 15, 15, 15,
+ 15, 93, 15, 15, 125, 93, 93, 15, 0, 0, 0, 0, 0, 21, 21, 21, 21, 21,
21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 91, 138, 21, 21, 21, 139, 21, 21, 21, 21, 21, 21, 21, 21,
21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 91, 91, 91, 91, 91, 92, 92, 92, 92, 92, 92, 92, 92,
+ 21, 21, 21, 21, 21, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
+ 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 0, 92, 92, 92, 92, 92, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24,
- 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 21, 21, 21, 21, 21,
- 140, 21, 21, 141, 21, 142, 142, 142, 142, 142, 142, 142, 142, 143,
- 143, 143, 143, 143, 143, 143, 143, 142, 142, 142, 142, 142, 142, 0,
- 0, 143, 143, 143, 143, 143, 143, 0, 0, 142, 142, 142, 142, 142, 142,
- 142, 142, 143, 143, 143, 143, 143, 143, 143, 143, 142, 142, 142, 142,
- 142, 142, 142, 142, 143, 143, 143, 143, 143, 143, 143, 143, 142, 142,
- 142, 142, 142, 142, 0, 0, 143, 143, 143, 143, 143, 143, 0, 0, 21, 142,
- 21, 142, 21, 142, 21, 142, 0, 143, 0, 143, 0, 143, 0, 143, 142, 142,
- 142, 142, 142, 142, 142, 142, 143, 143, 143, 143, 143, 143, 143, 143,
- 144, 144, 145, 145, 145, 145, 146, 146, 147, 147, 148, 148, 149, 149,
- 0, 0, 142, 142, 142, 142, 142, 142, 142, 142, 150, 150, 150, 150, 150,
- 150, 150, 150, 142, 142, 142, 142, 142, 142, 142, 142, 150, 150, 150,
- 150, 150, 150, 150, 150, 142, 142, 142, 142, 142, 142, 142, 142, 150,
- 150, 150, 150, 150, 150, 150, 150, 142, 142, 21, 151, 21, 0, 21, 21,
- 143, 143, 152, 152, 153, 11, 154, 11, 11, 11, 21, 151, 21, 0, 21, 21,
- 155, 155, 155, 155, 153, 11, 11, 11, 142, 142, 21, 21, 0, 0, 21, 21,
- 143, 143, 156, 156, 0, 11, 11, 11, 142, 142, 21, 21, 21, 113, 21, 21,
- 143, 143, 157, 157, 117, 11, 11, 11, 0, 0, 21, 151, 21, 0, 21, 21,
- 158, 158, 159, 159, 153, 11, 11, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 17, 17, 17, 17, 17, 8, 8, 8, 8, 8, 8, 3, 3, 16, 20, 5, 16, 16, 20,
- 5, 16, 3, 3, 3, 3, 3, 3, 3, 3, 160, 161, 17, 17, 17, 17, 17, 2, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 16, 20, 3, 3, 3, 3, 12, 12, 3, 3, 3, 7, 5,
- 6, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 7, 3, 12, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 2, 17, 17, 17, 17, 17, 0, 17, 17, 17, 17, 17, 17, 17, 17,
- 17, 17, 18, 91, 0, 0, 18, 18, 18, 18, 18, 18, 7, 7, 7, 5, 6, 91, 18,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 7, 7, 7, 5, 6, 0, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 0, 0, 0, 4, 4, 4, 4, 4, 4, 4, 4,
- 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
- 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 119, 119, 119, 119, 92, 119, 119,
- 119, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 107, 14, 14, 14, 14, 107, 14,
- 14, 21, 107, 107, 107, 21, 21, 107, 107, 107, 21, 14, 107, 14, 14,
- 7, 107, 107, 107, 107, 107, 14, 14, 14, 14, 14, 14, 107, 14, 162, 14,
- 107, 14, 163, 164, 107, 107, 14, 21, 107, 107, 165, 107, 21, 15, 15,
- 15, 15, 21, 14, 14, 21, 21, 107, 107, 7, 7, 7, 7, 7, 107, 21, 21, 21,
- 21, 14, 7, 14, 14, 166, 14, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
- 18, 18, 18, 18, 18, 18, 167, 167, 167, 167, 167, 167, 167, 167, 167,
- 167, 167, 167, 167, 167, 167, 167, 168, 168, 168, 168, 168, 168, 168,
- 168, 168, 168, 168, 168, 168, 168, 168, 168, 128, 128, 128, 23, 24,
- 128, 128, 128, 128, 18, 14, 14, 0, 0, 0, 0, 7, 7, 7, 7, 7, 14, 14,
- 14, 14, 14, 7, 7, 14, 14, 14, 14, 7, 14, 14, 7, 14, 14, 7, 14, 14,
- 14, 14, 14, 14, 14, 7, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
+ 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 92, 139, 21, 21,
+ 21, 140, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
+ 21, 141, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 92, 92, 92,
+ 92, 92, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 0, 93, 93, 93, 93, 93,
+ 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23,
+ 24, 23, 24, 23, 24, 21, 21, 21, 21, 21, 142, 21, 21, 143, 21, 144,
+ 144, 144, 144, 144, 144, 144, 144, 145, 145, 145, 145, 145, 145, 145,
+ 145, 144, 144, 144, 144, 144, 144, 0, 0, 145, 145, 145, 145, 145, 145,
+ 0, 0, 144, 144, 144, 144, 144, 144, 144, 144, 145, 145, 145, 145, 145,
+ 145, 145, 145, 144, 144, 144, 144, 144, 144, 144, 144, 145, 145, 145,
+ 145, 145, 145, 145, 145, 144, 144, 144, 144, 144, 144, 0, 0, 145, 145,
+ 145, 145, 145, 145, 0, 0, 21, 144, 21, 144, 21, 144, 21, 144, 0, 145,
+ 0, 145, 0, 145, 0, 145, 144, 144, 144, 144, 144, 144, 144, 144, 145,
+ 145, 145, 145, 145, 145, 145, 145, 146, 146, 147, 147, 147, 147, 148,
+ 148, 149, 149, 150, 150, 151, 151, 0, 0, 144, 144, 144, 144, 144, 144,
+ 144, 144, 152, 152, 152, 152, 152, 152, 152, 152, 144, 144, 144, 144,
+ 144, 144, 144, 144, 152, 152, 152, 152, 152, 152, 152, 152, 144, 144,
+ 144, 144, 144, 144, 144, 144, 152, 152, 152, 152, 152, 152, 152, 152,
+ 144, 144, 21, 153, 21, 0, 21, 21, 145, 145, 154, 154, 155, 11, 156,
+ 11, 11, 11, 21, 153, 21, 0, 21, 21, 157, 157, 157, 157, 155, 11, 11,
+ 11, 144, 144, 21, 21, 0, 0, 21, 21, 145, 145, 158, 158, 0, 11, 11,
+ 11, 144, 144, 21, 21, 21, 114, 21, 21, 145, 145, 159, 159, 118, 11,
+ 11, 11, 0, 0, 21, 153, 21, 0, 21, 21, 160, 160, 161, 161, 155, 11,
+ 11, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 17, 17, 17, 17, 17, 8, 8, 8,
+ 8, 8, 8, 3, 3, 16, 20, 5, 16, 16, 20, 5, 16, 3, 3, 3, 3, 3, 3, 3, 3,
+ 162, 163, 17, 17, 17, 17, 17, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 16, 20,
+ 3, 3, 3, 3, 12, 12, 3, 3, 3, 7, 5, 6, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
+ 3, 7, 3, 12, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, 17, 17, 17, 17, 17, 0,
+ 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 18, 92, 0, 0, 18, 18, 18, 18,
+ 18, 18, 7, 7, 7, 5, 6, 92, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 7, 7, 7, 5, 6, 0, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
+ 0, 0, 0, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
+ 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 120, 120, 120, 120, 93, 120, 120, 120, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14,
+ 14, 108, 14, 14, 14, 14, 108, 14, 14, 21, 108, 108, 108, 21, 21, 108,
+ 108, 108, 21, 14, 108, 14, 14, 7, 108, 108, 108, 108, 108, 14, 14,
+ 14, 14, 14, 14, 108, 14, 164, 14, 108, 14, 165, 166, 108, 108, 14,
+ 21, 108, 108, 167, 108, 21, 15, 15, 15, 15, 21, 14, 14, 21, 21, 108,
+ 108, 7, 7, 7, 7, 7, 108, 21, 21, 21, 21, 14, 7, 14, 14, 168, 14, 18,
+ 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 169, 169,
+ 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169,
+ 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170,
+ 170, 170, 129, 129, 129, 23, 24, 129, 129, 129, 129, 18, 14, 14, 0,
+ 0, 0, 0, 7, 7, 7, 7, 7, 14, 14, 14, 14, 14, 7, 7, 14, 14, 14, 14, 7,
+ 14, 14, 7, 14, 14, 7, 14, 14, 14, 14, 14, 14, 14, 7, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 7, 7, 14, 14, 7, 14, 7, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 7, 14, 14, 7, 14, 7, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 7, 7, 7, 7,
7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 14, 14, 14, 14, 14, 14, 14, 14, 5, 6, 5, 6, 14, 14,
+ 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 14, 14, 14, 14, 14,
+ 14, 14, 14, 5, 6, 5, 6, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 7, 14, 14, 14, 14, 14, 14, 14,
+ 5, 6, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 7, 7, 14, 14, 14, 14, 14, 14, 14, 5, 6, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 7,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 7, 7, 7, 7,
+ 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 7, 7, 7, 7,
- 7, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 7, 7, 7, 7, 7, 7, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 18,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
- 18, 18, 18, 18, 18, 18, 18, 18, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169,
- 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 169, 170, 170,
- 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170,
- 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 18, 18, 18, 18, 18,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 7, 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 14,
+ 14, 14, 14, 14, 14, 14, 14, 171, 171, 171, 171, 171, 171, 171, 171,
+ 171, 171, 171, 171, 171, 171, 171, 171, 171, 171, 171, 171, 171, 171,
+ 171, 171, 171, 171, 172, 172, 172, 172, 172, 172, 172, 172, 172, 172,
+ 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, 172, 172,
+ 172, 172, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 18, 18, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 7, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 7, 7, 7, 7, 7, 7, 7, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 7, 7, 7, 7, 7, 7, 7, 7, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 7, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 5, 6, 5, 6,
- 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 14, 14, 14, 14, 14, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 18, 18,
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
- 18, 18, 18, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 7, 7,
- 7, 7, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 5, 6, 5, 6, 5,
- 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 7, 7, 7, 7, 7, 7,
+ 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 7, 7, 7, 7, 7, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7,
7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 7, 7, 5, 6, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 5, 6, 7, 7, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 7, 7, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 14, 14, 7, 7, 7, 7,
- 7, 7, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
+ 7, 7, 7, 7, 7, 7, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5,
+ 6, 5, 6, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
+ 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 5, 6, 5, 6, 7, 7, 7, 7, 7, 7,
+ 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
+ 7, 7, 7, 5, 6, 7, 7, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
+ 7, 7, 7, 7, 14, 14, 7, 7, 7, 7, 7, 7, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 122, 122, 122, 122, 122, 122,
- 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122,
- 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122,
- 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 0,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 14, 14, 14,
+ 14, 14, 14, 14, 14, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123,
123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123,
123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123,
- 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123, 123,
- 123, 123, 123, 123, 123, 0, 23, 24, 171, 172, 173, 174, 175, 23, 24,
- 23, 24, 23, 24, 176, 177, 178, 179, 21, 23, 24, 21, 23, 24, 21, 21,
- 21, 21, 21, 91, 91, 180, 180, 23, 24, 23, 24, 21, 14, 14, 14, 14, 14,
- 14, 23, 24, 23, 24, 92, 92, 92, 23, 24, 0, 0, 0, 0, 0, 3, 3, 3, 3,
- 18, 3, 3, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181,
- 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181,
- 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 181, 0, 181,
- 0, 0, 0, 0, 0, 181, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0,
- 0, 0, 91, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 92, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15,
- 15, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 0,
- 15, 15, 15, 15, 15, 15, 15, 0, 3, 3, 16, 20, 16, 20, 3, 3, 3, 16, 20,
- 3, 16, 20, 3, 3, 3, 3, 3, 3, 3, 3, 3, 8, 3, 3, 8, 3, 16, 20, 3, 3,
- 16, 20, 5, 6, 5, 6, 5, 6, 5, 6, 3, 3, 3, 3, 3, 91, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 8, 8, 3, 3, 3, 3, 8, 3, 5, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14,
+ 123, 123, 123, 123, 123, 123, 123, 123, 123, 0, 124, 124, 124, 124,
+ 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124,
+ 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124,
+ 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124,
+ 124, 0, 23, 24, 173, 174, 175, 176, 177, 23, 24, 23, 24, 23, 24, 178,
+ 179, 180, 181, 21, 23, 24, 21, 23, 24, 21, 21, 21, 21, 21, 92, 92,
+ 182, 182, 23, 24, 23, 24, 21, 14, 14, 14, 14, 14, 14, 23, 24, 23, 24,
+ 93, 93, 93, 23, 24, 0, 0, 0, 0, 0, 3, 3, 3, 3, 18, 3, 3, 183, 183,
+ 183, 183, 183, 183, 183, 183, 183, 183, 183, 183, 183, 183, 183, 183,
+ 183, 183, 183, 183, 183, 183, 183, 183, 183, 183, 183, 183, 183, 183,
+ 183, 183, 183, 183, 183, 183, 183, 183, 0, 183, 0, 0, 0, 0, 0, 183,
+ 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 92, 3, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 93, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15,
+ 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15,
+ 0, 3, 3, 16, 20, 16, 20, 3, 3, 3, 16, 20, 3, 16, 20, 3, 3, 3, 3, 3,
+ 3, 3, 3, 3, 8, 3, 3, 8, 3, 16, 20, 3, 3, 16, 20, 5, 6, 5, 6, 5, 6,
+ 5, 6, 3, 3, 3, 3, 3, 92, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 8, 8, 3, 3,
+ 3, 3, 8, 3, 5, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 2, 3, 3, 3, 14, 91,
- 15, 128, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 14, 14, 5, 6, 5, 6, 5, 6, 5,
- 6, 8, 5, 6, 6, 14, 128, 128, 128, 128, 128, 128, 128, 128, 128, 92,
- 92, 92, 92, 124, 124, 8, 91, 91, 91, 91, 91, 14, 14, 128, 128, 128,
- 91, 15, 3, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 92, 92, 11, 11, 91,
- 91, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 3, 91, 91, 91, 15,
- 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 0, 0, 0, 0, 2, 3, 3, 3, 14, 92, 15, 129, 5, 6, 5, 6, 5,
+ 6, 5, 6, 5, 6, 14, 14, 5, 6, 5, 6, 5, 6, 5, 6, 8, 5, 6, 6, 14, 129,
+ 129, 129, 129, 129, 129, 129, 129, 129, 93, 93, 93, 93, 125, 125, 8,
+ 92, 92, 92, 92, 92, 14, 14, 129, 129, 129, 92, 15, 3, 14, 14, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15,
+ 15, 15, 15, 15, 0, 0, 93, 93, 11, 11, 92, 92, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 14, 14, 18, 18, 18, 18,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 3, 92, 92, 92, 15, 0, 0, 0, 0, 0, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 0, 0, 0, 0, 0, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 14, 14, 14, 14, 14,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 0, 14, 14, 18, 18, 18, 18, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 14,
+ 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 18, 18, 18, 18, 18, 18, 18, 18, 14,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 0, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 18, 18,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 91, 15, 15, 15, 15, 15,
+ 18, 18, 18, 18, 18, 18, 14, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15,
+ 15, 92, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 91, 3, 3, 3, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 15,
- 92, 119, 119, 119, 3, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 3, 91,
- 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23,
- 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 91, 91, 92, 92, 15, 15,
- 15, 15, 15, 15, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 92,
- 92, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 11, 11, 11, 11,
- 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 11, 11, 23, 24, 23, 24, 23, 24,
- 23, 24, 23, 24, 23, 24, 23, 24, 21, 21, 23, 24, 23, 24, 23, 24, 23,
+ 92, 3, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 15, 15, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 24, 23, 24, 23, 24, 23,
+ 24, 23, 24, 23, 24, 23, 24, 15, 93, 120, 120, 120, 3, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 3, 92, 23, 24, 23, 24, 23, 24, 23, 24, 23,
24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24,
- 23, 24, 23, 24, 23, 24, 91, 21, 21, 21, 21, 21, 21, 21, 21, 23, 24,
- 23, 24, 182, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 91, 11, 11, 23,
- 24, 183, 21, 15, 23, 24, 23, 24, 21, 21, 23, 24, 23, 24, 23, 24, 23,
- 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 184, 185, 186,
- 187, 184, 21, 188, 189, 190, 191, 23, 24, 23, 24, 23, 24, 0, 0, 0,
+ 23, 24, 92, 92, 93, 93, 15, 15, 15, 15, 15, 15, 129, 129, 129, 129,
+ 129, 129, 129, 129, 129, 129, 93, 93, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0,
+ 0, 0, 0, 0, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
+ 11, 11, 11, 11, 11, 11, 11, 11, 11, 92, 92, 92, 92, 92, 92, 92, 92,
+ 92, 11, 11, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24,
+ 21, 21, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23,
+ 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 92, 21,
+ 21, 21, 21, 21, 21, 21, 21, 23, 24, 23, 24, 184, 23, 24, 23, 24, 23,
+ 24, 23, 24, 23, 24, 92, 11, 11, 23, 24, 185, 21, 15, 23, 24, 23, 24,
+ 186, 21, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23,
+ 24, 23, 24, 23, 24, 187, 188, 189, 190, 187, 21, 191, 192, 193, 194,
+ 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 0, 0, 23, 24, 195,
+ 196, 197, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 15, 91, 91, 21, 15, 15, 15, 15, 15, 15, 15, 92, 15, 15, 15,
- 92, 15, 15, 15, 15, 92, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 124, 124, 92, 92, 124,
- 14, 14, 14, 14, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18, 14, 14, 4, 14,
- 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 124,
- 124, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124,
- 124, 124, 92, 92, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 0, 0, 0, 0, 0, 0, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 15, 15, 15, 15, 15, 15, 3, 3, 3, 15,
- 3, 15, 15, 92, 15, 15, 15, 15, 15, 15, 92, 92, 92, 92, 92, 92, 92,
- 92, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 124, 124, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 124, 124, 92, 92,
- 92, 92, 124, 124, 92, 124, 124, 124, 124, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 0, 91, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 3, 3,
- 15, 15, 15, 15, 15, 92, 91, 15, 15, 15, 15, 15, 15, 15, 15, 15, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 92, 92, 92, 92, 92, 92, 124, 124, 92, 92, 124, 124,
- 92, 92, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 92, 15, 15, 15, 15,
- 15, 15, 15, 15, 92, 124, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0,
- 3, 3, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 91, 15, 15, 15, 15, 15, 15, 14, 14, 14, 15, 124, 92, 124, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 92, 15, 92, 92, 92, 15, 15, 92, 92, 15, 15, 15, 15, 15, 92, 92, 15,
- 92, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 15, 15, 91, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 124, 92, 92, 124, 124, 3, 3, 15, 91, 91, 124, 92, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15,
- 0, 0, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15,
- 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 0, 21, 21, 21, 21, 21,
+ 0, 0, 0, 0, 0, 0, 15, 92, 92, 21, 15, 15, 15, 15, 15, 15, 15, 93, 15,
+ 15, 15, 93, 15, 15, 15, 15, 93, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 125, 125, 93,
+ 93, 125, 14, 14, 14, 14, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18, 14, 14,
+ 4, 14, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0,
+ 0, 125, 125, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125,
+ 125, 125, 125, 125, 93, 93, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 9, 9, 9,
+ 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 15, 15, 15, 15, 15, 15,
+ 3, 3, 3, 15, 3, 15, 15, 93, 15, 15, 15, 15, 15, 15, 93, 93, 93, 93,
+ 93, 93, 93, 93, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 125, 125, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 125,
+ 125, 93, 93, 93, 93, 125, 125, 93, 93, 125, 125, 125, 3, 3, 3, 3, 3,
+ 3, 3, 3, 3, 3, 3, 3, 3, 0, 92, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0,
+ 0, 0, 3, 3, 15, 15, 15, 15, 15, 93, 92, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 15, 15, 15, 15, 15, 0, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 93, 93, 93, 93, 93, 93, 125, 125, 93, 93,
+ 125, 125, 93, 93, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 93, 15, 15,
+ 15, 15, 15, 15, 15, 15, 93, 125, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
+ 0, 0, 3, 3, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 92, 15, 15, 15, 15, 15, 15, 14, 14, 14, 15, 125, 93, 125,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 93, 15, 93, 93, 93, 15, 15, 93, 93, 15, 15, 15, 15, 15, 93, 93,
+ 15, 93, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 15, 15, 92, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 125, 93, 93, 125, 125, 3, 3, 15, 92, 92, 125, 93, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15,
+ 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15,
+ 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 0, 21, 21, 21,
21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 192, 21, 21, 21,
- 21, 21, 21, 21, 11, 91, 91, 91, 91, 21, 21, 21, 21, 21, 21, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 193, 193, 193, 193, 193, 193, 193, 193, 193, 193,
- 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, 193,
- 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, 193,
- 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, 15, 15, 15, 124,
- 124, 92, 124, 124, 92, 124, 124, 3, 124, 92, 0, 0, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 194, 194, 194,
- 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194,
- 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194,
- 194, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195,
- 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195,
- 195, 195, 195, 195, 195, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 198, 21,
+ 21, 21, 21, 21, 21, 21, 11, 92, 92, 92, 92, 21, 21, 21, 21, 21, 21,
+ 21, 21, 0, 0, 0, 0, 0, 0, 0, 0, 199, 199, 199, 199, 199, 199, 199,
+ 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199,
+ 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199,
+ 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 15,
+ 15, 15, 125, 125, 93, 125, 125, 93, 125, 125, 3, 125, 93, 0, 0, 9,
+ 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 21,
- 21, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 21,
- 21, 21, 21, 0, 0, 0, 0, 0, 15, 92, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 7, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15,
- 15, 15, 15, 15, 0, 15, 0, 15, 15, 0, 15, 15, 0, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0,
+ 200, 200, 200, 200, 200, 200, 200, 200, 200, 200, 200, 200, 200, 200,
+ 200, 200, 200, 200, 200, 200, 200, 200, 200, 200, 200, 200, 200, 200,
+ 200, 200, 200, 200, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201,
+ 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201,
+ 201, 201, 201, 201, 201, 201, 201, 201, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- 11, 11, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0,
+ 0, 0, 0, 0, 0, 21, 21, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 15, 93, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 7, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 0, 15, 0, 15, 15, 0, 15, 15,
+ 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 11, 11, 11, 11, 11, 11,
+ 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 6, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 6, 5, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 4,
- 14, 0, 0, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 3, 3, 3, 3, 3, 3, 3, 5, 6, 3, 0, 0, 0, 0, 0, 0, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 3, 8, 8, 12, 12, 5,
- 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 3, 3, 5, 6, 3, 3, 3, 3,
- 12, 12, 12, 3, 3, 3, 0, 3, 3, 3, 3, 8, 5, 6, 5, 6, 5, 6, 3, 3, 3, 7,
- 8, 7, 7, 7, 0, 3, 4, 3, 3, 0, 0, 0, 0, 15, 15, 15, 15, 15, 0, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 4, 14, 0, 0, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 3, 3, 3, 3, 3, 3, 3, 5, 6, 3, 0, 0, 0,
+ 0, 0, 0, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 3, 8, 8, 12, 12, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6,
+ 3, 3, 5, 6, 3, 3, 3, 3, 12, 12, 12, 3, 3, 3, 0, 3, 3, 3, 3, 8, 5, 6,
+ 5, 6, 5, 6, 3, 3, 3, 7, 8, 7, 7, 7, 0, 3, 4, 3, 3, 0, 0, 0, 0, 15,
+ 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 0, 0, 17, 0, 3, 3, 3, 4, 3, 3, 3, 5, 6, 3, 7, 3, 8, 3,
- 3, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 3, 7, 7, 7, 3, 11, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 5, 7, 6, 7, 5, 6, 3, 5, 6, 3, 3, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 91, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 17, 0, 3, 3, 3, 4, 3,
+ 3, 3, 5, 6, 3, 7, 3, 8, 3, 3, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 3, 7,
+ 7, 7, 3, 11, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+ 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 5, 7, 6, 7, 5, 6, 3,
+ 5, 6, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 91, 91, 0, 0, 15, 15, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15,
- 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 0, 0, 15, 15, 15, 0, 0, 0, 4,
- 4, 7, 11, 14, 4, 4, 0, 14, 7, 7, 7, 7, 14, 14, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 17, 17, 17, 14, 14, 0, 0
-#if TCL_UTF_MAX > 3
+ 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 0, 0, 15, 15, 15, 15, 15, 15,
+ 0, 0, 15, 15, 15, 15, 15, 15, 0, 0, 15, 15, 15, 15, 15, 15, 0, 0, 15,
+ 15, 15, 0, 0, 0, 4, 4, 7, 11, 14, 4, 4, 0, 14, 7, 7, 7, 7, 14, 14,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 17, 17, 17, 14, 14, 0, 0
+#if TCL_UTF_MAX > 3 || TCL_MAJOR_VERSION > 8 || TCL_MINOR_VERSION > 6
,15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
@@ -1162,10 +1163,10 @@ static const unsigned char groupMap[] = {
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128,
- 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128,
- 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128,
- 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 18,
+ 14, 14, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129,
+ 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129,
+ 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129,
+ 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129, 18,
18, 18, 18, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 18, 18, 14, 14, 14, 0, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 0, 0, 0, 0, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
@@ -1173,34 +1174,34 @@ static const unsigned char groupMap[] = {
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 92, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 92,
+ 14, 14, 14, 93, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 93,
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0, 0, 18, 18, 18, 18,
0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 128, 15, 15, 15, 15, 15, 15,
- 15, 15, 128, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 129, 15, 15, 15, 15, 15, 15,
+ 15, 15, 129, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 92, 92, 92, 0,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 93, 93, 93, 0,
0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0,
- 3, 15, 15, 15, 15, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 3, 128,
- 128, 128, 128, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 196, 196, 196, 196,
- 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196,
- 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196,
- 196, 196, 196, 196, 196, 196, 196, 196, 197, 197, 197, 197, 197, 197,
- 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197,
- 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197,
- 197, 197, 197, 197, 197, 197, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 196,
- 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196,
- 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196, 196,
- 196, 196, 196, 196, 196, 196, 196, 0, 0, 0, 0, 197, 197, 197, 197,
- 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197,
- 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197,
- 197, 197, 197, 197, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 0,
+ 3, 15, 15, 15, 15, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 3, 129,
+ 129, 129, 129, 129, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 202, 202, 202, 202,
+ 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202,
+ 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202,
+ 202, 202, 202, 202, 202, 202, 202, 202, 203, 203, 203, 203, 203, 203,
+ 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203,
+ 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203,
+ 203, 203, 203, 203, 203, 203, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 202,
+ 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202,
+ 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, 202,
+ 202, 202, 202, 202, 202, 202, 202, 0, 0, 0, 0, 203, 203, 203, 203,
+ 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203,
+ 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203,
+ 203, 203, 203, 203, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 0,
0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15,
@@ -1221,18 +1222,18 @@ static const unsigned char groupMap[] = {
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 18, 18, 15, 15, 18, 18, 18, 18,
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 18, 18, 18, 18,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 15, 92, 92, 92, 0, 92, 92,
- 0, 0, 0, 0, 0, 92, 92, 92, 92, 15, 15, 15, 15, 0, 15, 15, 15, 0, 15,
+ 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 15, 93, 93, 93, 0, 93, 93,
+ 0, 0, 0, 0, 0, 93, 93, 93, 93, 15, 15, 15, 15, 0, 15, 15, 15, 0, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 92, 92, 92, 0, 0,
- 0, 0, 92, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0, 0, 0, 0, 0,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 93, 93, 93, 0, 0,
+ 0, 0, 93, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0, 0, 0, 0, 0,
3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 18, 18, 3, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 18, 18, 18, 15, 15, 15, 15, 15, 15, 15, 15, 14,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 0, 0, 0, 0, 18,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 0, 0, 0, 0, 18,
18, 18, 18, 18, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 0, 0, 0, 3, 3, 3, 3, 3, 3, 3, 15, 15, 15, 15, 15, 15,
@@ -1244,296 +1245,326 @@ static const unsigned char groupMap[] = {
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15,
15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97,
- 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97,
- 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97,
- 97, 97, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 102, 102, 102, 102,
- 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102,
- 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102,
- 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, 102,
- 102, 102, 102, 102, 102, 0, 0, 0, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18,
- 15, 15, 15, 15, 92, 92, 92, 92, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9,
+ 0, 0, 0, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98,
+ 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98,
+ 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, 98,
+ 98, 98, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 103, 103, 103, 103,
+ 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
+ 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
+ 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
+ 103, 103, 103, 103, 103, 0, 0, 0, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18,
+ 15, 15, 15, 15, 93, 93, 93, 93, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9,
9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18, 18, 18,
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
18, 18, 18, 18, 18, 18, 0, 18, 18, 18, 18, 18, 18, 18, 15, 0, 0, 0,
0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 18, 18, 18, 18, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 124, 92,
- 124, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 18, 18, 18, 18, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 125, 93,
+ 125, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18, 18, 18,
+ 15, 15, 15, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18, 18, 18,
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 92, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 124, 124, 124,
- 92, 92, 92, 92, 124, 124, 92, 92, 3, 3, 17, 3, 3, 3, 3, 0, 0, 0, 0,
+ 9, 9, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 93, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 125, 125, 125,
+ 93, 93, 93, 93, 125, 125, 93, 93, 3, 3, 17, 3, 3, 3, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 17, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0,
- 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 92,
- 92, 92, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 93,
+ 93, 93, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 92, 92, 92, 92, 92, 124, 92, 92, 92, 92, 92, 92, 92,
- 92, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 3, 3, 3, 15, 124, 124, 0, 0,
+ 15, 15, 15, 15, 93, 93, 93, 93, 93, 125, 93, 93, 93, 93, 93, 93, 93,
+ 93, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 3, 3, 3, 3, 15, 125, 125, 0, 0,
0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 92, 3, 3, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15,
+ 15, 15, 15, 15, 15, 15, 93, 3, 3, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 124, 124, 124, 92, 92, 92, 92, 92, 92, 92, 92, 92, 124, 124, 15,
- 15, 15, 15, 3, 3, 3, 3, 92, 92, 92, 92, 3, 0, 0, 9, 9, 9, 9, 9, 9,
+ 15, 125, 125, 125, 93, 93, 93, 93, 93, 93, 93, 93, 93, 125, 125, 15,
+ 15, 15, 15, 3, 3, 3, 3, 93, 93, 93, 93, 3, 0, 0, 9, 9, 9, 9, 9, 9,
9, 9, 9, 9, 15, 3, 15, 3, 3, 3, 0, 18, 18, 18, 18, 18, 18, 18, 18,
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 124, 124, 124,
- 92, 92, 92, 124, 124, 92, 124, 92, 92, 3, 3, 3, 3, 3, 3, 92, 0, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 125, 125, 125,
+ 93, 93, 93, 125, 125, 93, 125, 93, 93, 3, 3, 3, 3, 3, 3, 93, 0, 15,
15, 15, 15, 15, 15, 15, 0, 15, 0, 15, 15, 15, 15, 0, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 3, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 92, 124, 124, 124, 92, 92, 92, 92, 92, 92,
- 92, 92, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0,
- 0, 92, 92, 124, 124, 0, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 15, 15,
+ 15, 15, 15, 15, 15, 15, 93, 125, 125, 125, 93, 93, 93, 93, 93, 93,
+ 93, 93, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0,
+ 0, 93, 93, 125, 125, 0, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 15, 15,
0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 0,
- 15, 15, 15, 15, 15, 0, 92, 92, 15, 124, 124, 92, 124, 124, 124, 124,
- 0, 0, 124, 124, 0, 0, 124, 124, 124, 0, 0, 15, 0, 0, 0, 0, 0, 0, 124,
- 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 124, 124, 0, 0, 92, 92, 92, 92,
- 92, 92, 92, 0, 0, 0, 92, 92, 92, 92, 92, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 15, 15, 15, 15, 15, 0, 93, 93, 15, 125, 125, 93, 125, 125, 125, 125,
+ 0, 0, 125, 125, 0, 0, 125, 125, 125, 0, 0, 15, 0, 0, 0, 0, 0, 0, 125,
+ 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 125, 125, 0, 0, 93, 93, 93, 93,
+ 93, 93, 93, 0, 0, 0, 93, 93, 93, 93, 93, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 124, 124, 124, 92, 92, 92, 92, 92, 92, 92, 92,
- 124, 124, 92, 92, 92, 124, 92, 15, 15, 15, 15, 3, 3, 3, 3, 3, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 0, 3, 0, 3, 92, 0, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 124, 124, 124, 92, 92, 92,
- 92, 92, 92, 124, 92, 124, 124, 124, 124, 92, 92, 124, 92, 92, 15, 15,
+ 15, 15, 15, 15, 15, 125, 125, 125, 93, 93, 93, 93, 93, 93, 93, 93,
+ 125, 125, 93, 93, 93, 125, 93, 15, 15, 15, 15, 3, 3, 3, 3, 3, 9, 9,
+ 9, 9, 9, 9, 9, 9, 9, 9, 0, 3, 0, 3, 93, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 125, 125, 125, 93, 93, 93,
+ 93, 93, 93, 125, 93, 125, 125, 125, 125, 93, 93, 125, 93, 93, 15, 15,
3, 15, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0,
0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 124, 124, 124, 92, 92, 92, 92, 0, 0, 124, 124, 124, 124, 92, 92,
- 124, 92, 92, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 15, 15, 15, 15, 92, 92, 0, 0, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 124, 124, 124, 92, 92, 92,
- 92, 92, 92, 92, 92, 124, 124, 92, 124, 92, 92, 3, 3, 3, 15, 0, 0, 0,
+ 15, 125, 125, 125, 93, 93, 93, 93, 0, 0, 125, 125, 125, 125, 93, 93,
+ 125, 93, 93, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
+ 3, 3, 3, 3, 3, 15, 15, 15, 15, 93, 93, 0, 0, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 125, 125, 125, 93, 93, 93,
+ 93, 93, 93, 93, 93, 125, 125, 93, 125, 93, 93, 3, 3, 3, 15, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0,
0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 92, 124, 92, 124, 124, 92, 92, 92, 92, 92, 92, 124, 92, 0, 0, 0,
- 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 124, 124, 92, 92, 92, 92,
- 124, 92, 92, 92, 92, 92, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 18, 18, 3, 3, 3, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 124, 124, 124, 92, 92, 92, 92, 92, 92, 92, 92, 92, 124, 92, 92, 3,
- 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
+ 15, 93, 125, 93, 125, 125, 93, 93, 93, 93, 93, 93, 125, 93, 15, 0,
+ 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 125, 125, 93, 93, 93,
+ 93, 125, 93, 93, 93, 93, 93, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9,
+ 9, 18, 18, 3, 3, 3, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 125, 125, 125, 93, 93, 93, 93, 93, 93, 93, 93, 93, 125, 93, 93,
+ 3, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 10, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 92, 92, 92, 92, 124, 15, 92,
- 92, 92, 92, 3, 3, 3, 3, 3, 3, 3, 3, 92, 0, 0, 0, 0, 0, 0, 0, 0, 15,
- 92, 92, 92, 92, 92, 92, 124, 124, 92, 92, 92, 15, 15, 15, 15, 15, 15,
- 15, 15, 0, 0, 15, 15, 15, 15, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 124, 92, 92, 3, 3, 3, 15, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15,
+ 10, 10, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+ 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+ 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 125, 125, 125, 93, 93, 93, 93, 0, 0, 93, 93,
+ 125, 125, 125, 125, 93, 15, 3, 15, 125, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 93, 93,
+ 93, 93, 125, 15, 93, 93, 93, 93, 3, 3, 3, 3, 3, 3, 3, 3, 93, 0, 0,
+ 0, 0, 0, 0, 0, 0, 15, 93, 93, 93, 93, 93, 93, 125, 125, 93, 93, 93,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 125, 93, 93, 3, 3, 3, 15, 3,
+ 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 125, 93, 93, 93, 93, 93, 93, 93, 0, 93, 93, 93, 93, 93,
+ 93, 125, 93, 15, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9,
+ 9, 9, 9, 9, 9, 9, 9, 9, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0, 3, 3, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 0, 125, 93,
+ 93, 93, 93, 93, 93, 93, 125, 93, 93, 125, 93, 93, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 0, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 124, 92, 92, 92,
- 92, 92, 92, 92, 0, 92, 92, 92, 92, 92, 92, 124, 92, 15, 3, 3, 3, 3,
- 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 18,
+ 93, 93, 93, 93, 93, 93, 0, 0, 0, 93, 0, 93, 93, 0, 93, 93, 93, 93,
+ 93, 93, 93, 15, 93, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9,
+ 9, 9, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 0, 15, 15, 0, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 125, 125, 125,
+ 125, 125, 0, 93, 93, 0, 125, 125, 93, 125, 93, 15, 0, 0, 0, 0, 0, 0,
+ 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 93, 93, 125, 125, 3, 3, 0, 0, 0, 0, 0, 0, 0, 18, 18, 18,
18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
- 18, 0, 0, 0, 3, 3, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 0, 0, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 0, 124, 92, 92, 92, 92, 92, 92, 92, 124,
- 92, 92, 124, 92, 92, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15,
- 15, 15, 0, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 92, 92, 92, 92, 0, 0, 0,
- 92, 0, 92, 92, 0, 92, 92, 92, 92, 92, 92, 92, 15, 92, 0, 0, 0, 0, 0,
- 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 0, 0, 15, 15, 15,
- 15, 15, 15, 0, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 124, 124, 124, 124, 124, 0, 92, 92, 0, 124, 124, 92,
- 124, 92, 15, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 124, 124, 3, 3, 0,
- 0, 0, 0, 0, 0, 0, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128,
- 128, 128, 128, 128, 128, 0, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0,
+ 18, 14, 14, 14, 14, 14, 14, 14, 14, 4, 4, 4, 4, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 3, 129, 129, 129, 129, 129, 129, 129, 129, 129, 129,
+ 129, 129, 129, 129, 129, 0, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0,
- 0, 92, 92, 92, 92, 92, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 92, 92, 92, 92,
- 92, 92, 92, 3, 3, 3, 3, 3, 14, 14, 14, 14, 91, 91, 91, 91, 3, 14, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 18, 18,
- 18, 18, 18, 18, 18, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 15, 15, 15,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
- 18, 18, 18, 18, 18, 18, 3, 3, 3, 3, 0, 0, 0, 0, 0, 15, 15, 15, 15,
- 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 124, 124, 124, 124, 124, 124,
- 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124,
- 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124,
- 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 92, 92, 92, 92, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 0, 17, 17, 17, 17, 17, 17, 17, 17,
+ 17, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9,
+ 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 0, 0, 93, 93, 93, 93, 93, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 93, 93,
+ 93, 93, 93, 93, 93, 3, 3, 3, 3, 3, 14, 14, 14, 14, 92, 92, 92, 92,
+ 3, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
+ 0, 18, 18, 18, 18, 18, 18, 18, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 15,
+ 15, 15, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 18, 18, 18, 3, 3, 3, 3, 0, 0, 0, 0, 0, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 93, 15, 125, 125, 125,
+ 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125,
+ 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125,
+ 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 125,
+ 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, 0, 0, 0, 0, 0, 0,
+ 0, 93, 93, 93, 93, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
+ 92, 92, 92, 3, 92, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0,
+ 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 0, 0, 0,
0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 14, 92, 92, 3, 17, 17, 17,
- 17, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 0, 0, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 124, 124, 92, 92, 92, 14, 14, 14, 124,
- 124, 124, 124, 124, 124, 17, 17, 17, 17, 17, 17, 17, 17, 92, 92, 92,
- 92, 92, 92, 92, 92, 14, 14, 92, 92, 92, 92, 92, 92, 92, 14, 14, 14,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0,
+ 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 0, 0, 14, 93, 93, 3, 17, 17, 17, 17, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 0, 0, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 92, 92, 92, 92, 14, 14, 14,
+ 14, 14, 14, 14, 14, 125, 125, 93, 93, 93, 14, 14, 14, 125, 125, 125,
+ 125, 125, 125, 17, 17, 17, 17, 17, 17, 17, 17, 93, 93, 93, 93, 93,
+ 93, 93, 93, 14, 14, 93, 93, 93, 93, 93, 93, 93, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 92, 92, 92, 14, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 18,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
- 18, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 93, 93, 93, 93, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0,
- 0, 0, 0, 0, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 21, 21, 21, 21, 21, 21, 21, 0, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 21, 21, 21,
+ 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 14, 14, 93, 93, 93, 14, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0, 0, 0, 0, 0,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 21, 21,
21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 107, 0, 107, 107, 0, 0, 107, 0, 0, 107, 107,
- 0, 0, 107, 107, 107, 107, 0, 107, 107, 107, 107, 107, 107, 107, 107,
- 21, 21, 21, 21, 0, 21, 0, 21, 21, 21, 21, 21, 21, 21, 0, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 107, 107,
- 0, 107, 107, 107, 107, 0, 0, 107, 107, 107, 107, 107, 107, 107, 107,
- 0, 107, 107, 107, 107, 107, 107, 107, 0, 21, 21, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 21, 21, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 21, 21, 21, 21, 21, 21, 21, 0, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 21, 21, 21, 21, 21, 21,
21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 107, 107, 0, 107, 107, 107, 107, 0, 107, 107, 107, 107, 107,
- 0, 107, 0, 0, 0, 107, 107, 107, 107, 107, 107, 107, 0, 21, 21, 21,
+ 21, 21, 21, 108, 0, 108, 108, 0, 0, 108, 0, 0, 108, 108, 0, 0, 108,
+ 108, 108, 108, 0, 108, 108, 108, 108, 108, 108, 108, 108, 21, 21, 21,
+ 21, 0, 21, 0, 21, 21, 21, 21, 21, 21, 21, 0, 21, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 108, 108, 0, 108, 108,
+ 108, 108, 0, 0, 108, 108, 108, 108, 108, 108, 108, 108, 0, 108, 108,
+ 108, 108, 108, 108, 108, 0, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 108,
+ 108, 0, 108, 108, 108, 108, 0, 108, 108, 108, 108, 108, 0, 108, 0,
+ 0, 0, 108, 108, 108, 108, 108, 108, 108, 0, 21, 21, 21, 21, 21, 21,
21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 107, 107,
+ 21, 21, 21, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 21, 21, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 108, 108, 21, 21, 21, 21,
21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 21, 21, 21, 21, 21, 21, 0, 0, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 7, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 7, 21, 21, 21, 21,
- 21, 21, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 7,
+ 21, 21, 21, 21, 21, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 21, 21, 21,
+ 21, 21, 21, 0, 0, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 7, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 7, 21, 21, 21, 21, 21, 21,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 7, 21, 21, 21,
21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 7, 21, 21, 21, 21, 21, 21, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 7, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 7, 21, 21, 21, 21, 21, 21, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 7, 21, 21, 21, 21, 21, 21, 21, 21,
21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 7, 21, 21, 21, 21, 21, 21, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 7, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 7, 21,
- 21, 21, 21, 21, 21, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 7, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
- 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 7, 21, 21, 21, 21, 21, 21,
- 107, 21, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
+ 7, 21, 21, 21, 21, 21, 21, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 7, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 7, 21, 21, 21, 21,
+ 21, 21, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108,
+ 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, 7,
+ 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21,
+ 21, 21, 21, 21, 21, 21, 21, 21, 7, 21, 21, 21, 21, 21, 21, 108, 21,
+ 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 14, 14, 14, 14,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92,
- 92, 14, 14, 14, 14, 14, 14, 14, 14, 92, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 92, 14, 14, 3, 3, 3, 3, 3, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 92, 92, 92, 92, 92, 0, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 92, 92, 92, 92, 92, 92, 92, 0, 92, 92, 92,
- 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 0, 0, 92, 92,
- 92, 92, 92, 92, 92, 0, 92, 92, 0, 92, 92, 92, 92, 92, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15,
- 0, 0, 18, 18, 18, 18, 18, 18, 18, 18, 18, 92, 92, 92, 92, 92, 92, 92,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 198, 198, 198, 198, 198, 198, 198, 198,
- 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198,
- 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 199, 199,
- 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199,
- 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199, 199,
- 199, 199, 199, 199, 92, 92, 92, 92, 92, 92, 92, 0, 0, 0, 0, 0, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
- 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 14,
- 18, 18, 18, 4, 18, 18, 18, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15,
- 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15,
- 0, 15, 0, 0, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15,
- 15, 15, 15, 0, 15, 0, 15, 0, 0, 0, 0, 0, 0, 15, 0, 0, 0, 0, 15, 0,
- 15, 0, 15, 0, 15, 15, 15, 0, 15, 15, 0, 15, 0, 0, 15, 0, 15, 0, 15,
- 0, 15, 0, 15, 0, 15, 15, 0, 15, 0, 0, 15, 15, 15, 15, 0, 15, 15, 15,
- 15, 15, 15, 15, 0, 15, 15, 15, 15, 0, 15, 15, 15, 15, 0, 15, 0, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 15, 15, 15,
- 0, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 7, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 18, 18, 18, 18, 18, 18, 18, 18, 18,
- 18, 18, 18, 18, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 9, 9, 9, 9, 9, 9, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 14, 14, 14, 14, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 14, 14,
+ 14, 14, 14, 14, 14, 14, 93, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 93, 14, 14, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 93, 93, 93, 93, 93, 0, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 93, 93, 93, 93, 93, 93, 93, 0, 93, 93, 93, 93, 93, 93,
+ 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 0, 0, 93, 93, 93, 93, 93,
+ 93, 93, 0, 93, 93, 0, 93, 93, 93, 93, 93, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 0, 0, 0, 93, 93, 93, 93, 93, 93, 93, 92, 92, 92,
+ 92, 92, 92, 92, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 0, 0, 0, 15,
+ 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 93, 93, 93, 93, 9, 9, 9, 9, 9, 9, 9,
+ 9, 9, 9, 0, 0, 0, 0, 0, 4, 15, 15, 15, 15, 15, 0, 0, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 93, 93, 93, 93, 93, 93, 93, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 204, 204, 204, 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
+ 204, 204, 204, 204, 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
+ 204, 204, 204, 204, 204, 204, 204, 205, 205, 205, 205, 205, 205, 205,
+ 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205,
+ 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 93,
+ 93, 93, 93, 93, 93, 93, 92, 0, 0, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9,
+ 9, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 14, 18, 18, 18, 4, 18,
+ 18, 18, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 18, 14, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 0, 0, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 0, 15, 15, 0, 15, 0, 0, 15, 0, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 0, 15, 0, 15, 0, 0, 0, 0, 0,
+ 0, 15, 0, 0, 0, 0, 15, 0, 15, 0, 15, 0, 15, 15, 15, 0, 15, 15, 0, 15,
+ 0, 0, 15, 0, 15, 0, 15, 0, 15, 0, 15, 0, 15, 15, 0, 15, 0, 0, 15, 15,
+ 15, 15, 0, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 0, 15, 15,
+ 15, 15, 0, 15, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0,
+ 0, 0, 15, 15, 15, 0, 15, 15, 15, 15, 15, 0, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0,
+ 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 18, 18, 18, 18, 18,
+ 18, 18, 18, 18, 18, 18, 18, 18, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0,
- 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14,
- 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 11, 11, 11,
- 11, 11, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0,
- 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0,
- 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0,
+ 0, 0, 0, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14,
+ 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 0, 0, 14, 14, 14, 14, 0, 0, 0, 14, 0, 14,
- 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 11, 11, 11, 11, 11, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0,
+ 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0,
+ 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0,
+ 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 0, 14, 14, 14, 14, 0, 0, 0, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 0, 0, 14, 14, 14, 14, 14, 14, 0, 0, 0, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 14, 14, 14, 14, 0, 0,
+ 0, 0, 14, 14, 14, 0, 0, 0, 0, 0, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
- 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
+ 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,
+ 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
#endif /* TCL_UTF_MAX > 3 */
};
@@ -1564,24 +1595,25 @@ static const int groups[] = {
2763585, -41663, 2762817, -2768510, -49855, 17729, 18241, -2760318,
-2759550, -2760062, 53890, 52866, 52610, 51842, 52098, -10833534,
-10832510, 53122, -10823550, -10830718, 53634, 54146, -2750078,
- -10829950, -2751614, 54658, 54914, -2745982, 55938, -10824062,
- 17794, 55682, 18306, 56194, -10818686, -10817918, 4, 6, -21370,
- 29761, 9793, 9537, 16449, 16193, 9858, 9602, 8066, 16514, 16258,
- 2113, 16002, 14722, 1, 12162, 13954, 2178, 22146, 20610, -1662,
- 29826, -15295, 24706, -1727, 20545, 7, 3905, 3970, 12353, 12418,
- 8, 1859649, -769822, 9949249, 10, 1601154, 1600898, 1598594, 1598082,
- 1598338, 1596546, 1582466, -9027966, -769983, -9044862, -976254,
- 15234, -1949375, -1918, -1983, -18814, -21886, -25470, -32638,
- -28542, -32126, -1981, -2174, -18879, -2237, 1844610, -21951,
- -25535, -28607, -32703, -32191, 13, 14, -1924287, -2145983, -2115007,
- 7233, 7298, 4170, 4234, 6749, 6813, -2750143, -976319, -2746047,
- 2763650, 2762882, -2759615, -2751679, -2760383, -2760127, -2768575,
- 1859714, -9044927, -10823615, -10830783, -10833599, -10832575,
- -10830015, -10817983, -10824127, -10818751, 237633, 237698, 9949314,
+ -10829950, -2751614, 54658, 54914, -2745982, 55938, -10830462,
+ -10824062, 17794, 55682, 18306, 56194, -10818686, -10817918, 4,
+ 6, -21370, 29761, 9793, 9537, 16449, 16193, 9858, 9602, 8066,
+ 16514, 16258, 2113, 16002, 14722, 1, 12162, 13954, 2178, 22146,
+ 20610, -1662, 29826, -15295, 24706, -1727, 20545, 7, 3905, 3970,
+ 12353, 12418, 8, 1859649, -769822, 9949249, 10, 1601154, 1600898,
+ 1598594, 1598082, 1598338, 1596546, 1582466, -9027966, -769983,
+ -9044862, -976254, -9058174, 15234, -1949375, -1918, -1983, -18814,
+ -21886, -25470, -32638, -28542, -32126, -1981, -2174, -18879,
+ -2237, 1844610, -21951, -25535, -28607, -32703, -32191, 13, 14,
+ -1924287, -2145983, -2115007, 7233, 7298, 4170, 4234, 6749, 6813,
+ -2750143, -976319, -2746047, 2763650, 2762882, -2759615, -2751679,
+ -2760383, -2760127, -2768575, 1859714, -9044927, -10823615, -12158,
+ -10830783, -10833599, -10832575, -10830015, -10817983, -10824127,
+ -10818751, 237633, -12223, -10830527, -9058239, 237698, 9949314,
18, 17, 10305, 10370, 8769, 8834
};
-#if TCL_UTF_MAX > 3
+#if TCL_UTF_MAX > 3 || TCL_MAJOR_VERSION > 8 || TCL_MINOR_VERSION > 6
# define UNICODE_OUT_OF_RANGE(ch) (((ch) & 0x1fffff) >= 0x2fa20)
#else
# define UNICODE_OUT_OF_RANGE(ch) (((ch) & 0x1f0000) != 0)
@@ -1640,7 +1672,7 @@ enum {
* Unicode character tables.
*/
-#if TCL_UTF_MAX > 3
+#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))]])
#else
# define GetUniCharInfo(ch) (groups[groupMap[pageMap[((ch) & 0xffff) >> OFFSET_BITS] | ((ch) & ((1 << OFFSET_BITS)-1))]])
diff --git a/generic/tclUtf.c b/generic/tclUtf.c
index ce67db7..53a0fec 100644
--- a/generic/tclUtf.c
+++ b/generic/tclUtf.c
@@ -67,9 +67,7 @@ static const unsigned char totalBytes[256] = {
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
- 3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,
- 4,4,4,4,4,4,4,4,
- 1,1,1,1,1,1,1,1
+ 3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,4,4,1,1,1,1,1,1,1,1,1,1,1
};
/*
@@ -112,6 +110,19 @@ TclUtfCount(
* Store the given Tcl_UniChar as a sequence of UTF-8 bytes in the
* provided buffer. Equivalent to Plan 9 runetochar().
*
+ * Special handling of Surrogate pairs is handled as follows:
+ * When this function is called for ch being a high surrogate,
+ * the first byte of the 4-byte UTF-8 sequence is produced and
+ * the function returns 1. Calling the function again with a
+ * low surrogate, the remaining 3 bytes of the 4-byte UTF-8
+ * sequence is produced, and the function returns 3. The buffer
+ * is used to remember the high surrogate between the two calls.
+ *
+ * If no low surrogate follows the high surrogate (which is actually
+ * illegal), this can be handled reasonably by calling Tcl_UniCharToUtf
+ * again with ch = -1. This will produce a 3-byte UTF-8 sequence
+ * representing the high surrogate.
+ *
* Results:
* The return values is the number of bytes in the buffer that were
* consumed.
@@ -145,23 +156,22 @@ Tcl_UniCharToUtf(
if ((ch & 0xF800) == 0xD800) {
if (ch & 0x0400) {
/* Low surrogate */
- if (((buf[0] & 0xF8) == 0xF0) && ((buf[1] & 0xC0) == 0x80)
- && ((buf[2] & 0xCF) == 0)) {
- /* Previous Tcl_UniChar was a High surrogate, so combine */
- buf[3] = (char) ((ch & 0x3F) | 0x80);
- buf[2] |= (char) (((ch >> 6) & 0x0F) | 0x80);
- return 4;
+ if (((buf[0] & 0xC0) == 0x80) && ((buf[1] & 0xCF) == 0)) {
+ /* Previous Tcl_UniChar was a high surrogate, so combine */
+ buf[2] = (char) ((ch & 0x3F) | 0x80);
+ buf[1] |= (char) (((ch >> 6) & 0x0F) | 0x80);
+ return 3;
}
- /* Previous Tcl_UniChar was not a High surrogate, so just output */
+ /* Previous Tcl_UniChar was not a high surrogate, so just output */
} else {
/* High surrogate */
ch += 0x40;
/* Fill buffer with specific 3-byte (invalid) byte combination,
- so following Low surrogate can recognize it and combine */
+ so following low surrogate can recognize it and combine */
buf[2] = (char) ((ch << 4) & 0x30);
buf[1] = (char) (((ch >> 2) & 0x3F) | 0x80);
buf[0] = (char) (((ch >> 8) & 0x07) | 0xF0);
- return 0;
+ return 1;
}
}
goto three;
@@ -174,11 +184,14 @@ Tcl_UniCharToUtf(
return 4;
}
} else if (ch == -1) {
- if (((buf[0] & 0xF8) == 0xF0) && ((buf[1] & 0xC0) == 0x80)
- && ((buf[2] & 0xCF) == 0)) {
- ch = 0xD7C0 + ((buf[0] & 0x07) << 8) + ((buf[1] & 0x3F) << 2)
- + ((buf[2] & 0x30) >> 4);
- goto three;
+ if (((buf[0] & 0xC0) == 0x80) && ((buf[1] & 0xCF) == 0)
+ && ((buf[-1] & 0xF8) == 0xF0)) {
+ ch = 0xD7C0 + ((buf[-1] & 0x07) << 8) + ((buf[0] & 0x3F) << 2)
+ + ((buf[1] & 0x30) >> 4);
+ buf[1] = (char) ((ch | 0x80) & 0xBF);
+ buf[0] = (char) (((ch >> 6) | 0x80) & 0xBF);
+ buf[-1] = (char) ((ch >> 12) | 0xE0);
+ return 2;
}
}
@@ -232,15 +245,18 @@ Tcl_UniCharToUtfDString(
wEnd = uniStr + uniLength;
for (w = uniStr; w < wEnd; ) {
if (!len && ((*w & 0xFC00) != 0xDC00)) {
- /* Special case for handling upper surrogates. */
+ /* Special case for handling high surrogates. */
p += Tcl_UniCharToUtf(-1, p);
}
len = Tcl_UniCharToUtf(*w, p);
p += len;
+ if ((*w >= 0xD800) && (len < 3)) {
+ len = 0; /* Indication that high surrogate was found */
+ }
w++;
}
if (!len) {
- /* Special case for handling upper surrogates. */
+ /* Special case for handling high surrogates. */
p += Tcl_UniCharToUtf(-1, p);
}
Tcl_DStringSetLength(dsPtr, oldLength + (p - string));
@@ -248,6 +264,50 @@ Tcl_UniCharToUtfDString(
return string;
}
+#if (TCL_UTF_MAX > 4) && (defined(__CYGWIN__) || defined(_WIN32))
+char *
+TclWCharToUtfDString(
+ const WCHAR *uniStr, /* WCHAR string to convert to UTF-8. */
+ int uniLength, /* Length of WCHAR string in Tcl_UniChars
+ * (must be >= 0). */
+ Tcl_DString *dsPtr) /* UTF-8 representation of string is appended
+ * to this previously initialized DString. */
+{
+ const WCHAR *w, *wEnd;
+ char *p, *string;
+ int oldLength, len = 1;
+
+ /*
+ * UTF-8 string length in bytes will be <= Unicode string length * 4.
+ */
+
+ oldLength = Tcl_DStringLength(dsPtr);
+ Tcl_DStringSetLength(dsPtr, oldLength + (uniLength + 1) * 4);
+ string = Tcl_DStringValue(dsPtr) + oldLength;
+
+ p = string;
+ wEnd = uniStr + uniLength;
+ for (w = uniStr; w < wEnd; ) {
+ if (!len && ((*w & 0xFC00) != 0xDC00)) {
+ /* Special case for handling high surrogates. */
+ p += Tcl_UniCharToUtf(-1, p);
+ }
+ len = Tcl_UniCharToUtf(*w, p);
+ p += len;
+ if ((*w >= 0xD800) && (len < 3)) {
+ len = 0; /* Indication that high surrogate was found */
+ }
+ w++;
+ }
+ if (!len) {
+ /* Special case for handling high surrogates. */
+ p += Tcl_UniCharToUtf(-1, p);
+ }
+ Tcl_DStringSetLength(dsPtr, oldLength + (p - string));
+
+ return string;
+}
+#endif
/*
*---------------------------------------------------------------------------
*
@@ -264,11 +324,11 @@ Tcl_UniCharToUtfDString(
* Tcl_UtfCharComplete() before calling this routine to ensure that
* enough bytes remain in the string.
*
- * If TCL_UTF_MAX == 4, special handling of Surrogate pairs is done:
+ * Special handling of Surrogate pairs is handled as follows:
* For any UTF-8 string containing a character outside of the BMP, the
* first call to this function will fill *chPtr with the high surrogate
- * and generate a return value of 0. Calling Tcl_UtfToUniChar again
- * will produce the low surrogate and a return value of 4. Because *chPtr
+ * and generate a return value of 1. Calling Tcl_UtfToUniChar again
+ * will produce the low surrogate and a return value of 3. Because *chPtr
* is used to remember whether the high surrogate is already produced, it
* is recommended to initialize the variable it points to as 0 before
* the first call to Tcl_UtfToUniChar is done.
@@ -296,10 +356,10 @@ Tcl_UtfToUniChar(
register Tcl_UniChar *chPtr)/* Filled with the Tcl_UniChar represented by
* the UTF-8 string. */
{
- register int byte;
+ Tcl_UniChar byte;
/*
- * Unroll 1 to 3 (or 4) byte UTF-8 sequences.
+ * Unroll 1 to 4 byte UTF-8 sequences.
*/
byte = *((unsigned char *) src);
@@ -312,10 +372,24 @@ Tcl_UtfToUniChar(
* characters representing themselves.
*/
- if ((unsigned)(byte-0x80) < (unsigned) 0x20) {
- *chPtr = (Tcl_UniChar) cp1252[byte-0x80];
+#if TCL_UTF_MAX <= 4
+ /* If *chPtr contains a high surrogate (produced by a previous
+ * Tcl_UtfToUniChar() call) and the next 3 bytes are UTF-8 continuation
+ * bytes, then we must produce a follow-up low surrogate. We only
+ * do that if the high surrogate matches the bits we encounter.
+ */
+ if ((byte >= 0x80)
+ && (((((byte - 0x10) << 2) & 0xFC) | 0xD800) == (*chPtr & 0xFCFC))
+ && ((src[1] & 0xF0) == (((*chPtr << 4) & 0x30) | 0x80))
+ && ((src[2] & 0xC0) == 0x80)) {
+ *chPtr = ((src[1] & 0x0F) << 6) + (src[2] & 0x3F) + 0xDC00;
+ return 3;
+ }
+#endif
+ if ((unsigned)(byte-0x80) < (unsigned)0x20) {
+ *chPtr = cp1252[byte-0x80];
} else {
- *chPtr = (Tcl_UniChar) byte;
+ *chPtr = byte;
}
return 1;
} else if (byte < 0xE0) {
@@ -324,7 +398,7 @@ Tcl_UtfToUniChar(
* Two-byte-character lead-byte followed by a trail-byte.
*/
- *chPtr = (Tcl_UniChar) (((byte & 0x1F) << 6) | (src[1] & 0x3F));
+ *chPtr = (((byte & 0x1F) << 6) | (src[1] & 0x3F));
if ((unsigned)(*chPtr - 1) >= (UNICODE_SELF - 1)) {
return 2;
}
@@ -340,7 +414,7 @@ Tcl_UtfToUniChar(
* Three-byte-character lead byte followed by two trail bytes.
*/
- *chPtr = (Tcl_UniChar) (((byte & 0x0F) << 12)
+ *chPtr = (((byte & 0x0F) << 12)
| ((src[1] & 0x3F) << 6) | (src[2] & 0x3F));
if (*chPtr > 0x7FF) {
return 3;
@@ -358,24 +432,17 @@ Tcl_UtfToUniChar(
* Four-byte-character lead byte followed by three trail bytes.
*/
#if TCL_UTF_MAX <= 4
- Tcl_UniChar surrogate;
-
- byte = (((byte & 0x07) << 18) | ((src[1] & 0x3F) << 12)
- | ((src[2] & 0x3F) << 6) | (src[3] & 0x3F)) - 0x10000;
- surrogate = (Tcl_UniChar) (0xD800 + (byte >> 10));
- if (byte & 0x100000) {
+ Tcl_UniChar high = (((byte & 0x07) << 8) | ((src[1] & 0x3F) << 2)
+ | ((src[2] & 0x3F) >> 4)) - 0x40;
+ if (high >= 0x400) {
/* out of range, < 0x10000 or > 0x10ffff */
- } else if (*chPtr != surrogate) {
- /* produce high surrogate, but don't advance source pointer */
- *chPtr = surrogate;
- return 0;
} else {
- /* produce low surrogate, and advance source pointer */
- *chPtr = (Tcl_UniChar) (0xDC00 | (byte & 0x3FF));
- return 4;
+ /* produce high surrogate, advance source pointer */
+ *chPtr = 0xD800 + high;
+ return 1;
}
#else
- *chPtr = (Tcl_UniChar) (((byte & 0x07) << 18) | ((src[1] & 0x3F) << 12)
+ *chPtr = (((byte & 0x07) << 18) | ((src[1] & 0x3F) << 12)
| ((src[2] & 0x3F) << 6) | (src[3] & 0x3F));
if ((unsigned)(*chPtr - 0x10000) <= 0xFFFFF) {
return 4;
@@ -384,15 +451,117 @@ Tcl_UtfToUniChar(
}
/*
- * A four-byte-character lead-byte not followed by two trail-bytes
+ * A four-byte-character lead-byte not followed by three trail-bytes
* represents itself.
*/
}
- *chPtr = (Tcl_UniChar) byte;
+ *chPtr = byte;
return 1;
}
-
+
+#if (TCL_UTF_MAX > 4) && (defined(__CYGWIN__) || defined(_WIN32))
+int
+TclUtfToWChar(
+ const char *src, /* The UTF-8 string. */
+ WCHAR *chPtr)/* Filled with the WCHAR represented by
+ * the UTF-8 string. */
+{
+ WCHAR byte;
+
+ /*
+ * Unroll 1 to 4 byte UTF-8 sequences.
+ */
+
+ byte = *((unsigned char *) src);
+ if (byte < 0xC0) {
+ /*
+ * Handles properly formed UTF-8 characters between 0x01 and 0x7F.
+ * Treats naked trail bytes 0x80 to 0x9F as valid characters from
+ * the cp1252 table. See: <https://en.wikipedia.org/wiki/UTF-8>
+ * Also treats \0 and other naked trail bytes 0xA0 to 0xBF as valid
+ * characters representing themselves.
+ */
+
+ /* If *chPtr contains a high surrogate (produced by a previous
+ * Tcl_UtfToUniChar() call) and the next 3 bytes are UTF-8 continuation
+ * bytes, then we must produce a follow-up low surrogate. We only
+ * do that if the high surrogate matches the bits we encounter.
+ */
+ if ((byte >= 0x80)
+ && (((((byte - 0x10) << 2) & 0xFC) | 0xD800) == (*chPtr & 0xFCFC))
+ && ((src[1] & 0xF0) == (((*chPtr << 4) & 0x30) | 0x80))
+ && ((src[2] & 0xC0) == 0x80)) {
+ *chPtr = ((src[1] & 0x0F) << 6) + (src[2] & 0x3F) + 0xDC00;
+ return 3;
+ }
+ if ((unsigned)(byte-0x80) < (unsigned)0x20) {
+ *chPtr = cp1252[byte-0x80];
+ } else {
+ *chPtr = byte;
+ }
+ return 1;
+ } else if (byte < 0xE0) {
+ if ((src[1] & 0xC0) == 0x80) {
+ /*
+ * Two-byte-character lead-byte followed by a trail-byte.
+ */
+
+ *chPtr = (((byte & 0x1F) << 6) | (src[1] & 0x3F));
+ if ((unsigned)(*chPtr - 1) >= (UNICODE_SELF - 1)) {
+ return 2;
+ }
+ }
+
+ /*
+ * A two-byte-character lead-byte not followed by trail-byte
+ * represents itself.
+ */
+ } else if (byte < 0xF0) {
+ if (((src[1] & 0xC0) == 0x80) && ((src[2] & 0xC0) == 0x80)) {
+ /*
+ * Three-byte-character lead byte followed by two trail bytes.
+ */
+
+ *chPtr = (((byte & 0x0F) << 12)
+ | ((src[1] & 0x3F) << 6) | (src[2] & 0x3F));
+ if (*chPtr > 0x7FF) {
+ return 3;
+ }
+ }
+
+ /*
+ * A three-byte-character lead-byte not followed by two trail-bytes
+ * represents itself.
+ */
+ }
+ else if (byte < 0xF8) {
+ if (((src[1] & 0xC0) == 0x80) && ((src[2] & 0xC0) == 0x80) && ((src[3] & 0xC0) == 0x80)) {
+ /*
+ * Four-byte-character lead byte followed by three trail bytes.
+ */
+ WCHAR high = (((byte & 0x07) << 8) | ((src[1] & 0x3F) << 2)
+ | ((src[2] & 0x3F) >> 4)) - 0x40;
+ if (high >= 0x400) {
+ /* out of range, < 0x10000 or > 0x10ffff */
+ } else {
+ /* produce high surrogate, advance source pointer */
+ *chPtr = 0xD800 + high;
+ return 1;
+ }
+ }
+
+ /*
+ * A four-byte-character lead-byte not followed by three trail-bytes
+ * represents itself.
+ */
+ }
+
+ *chPtr = byte;
+ return 1;
+}
+#endif
+
/*
*---------------------------------------------------------------------------
*
@@ -450,8 +619,6 @@ Tcl_UtfToUniCharDString(
while (p < end) {
if (Tcl_UtfCharComplete(p, end-p)) {
p += TclUtfToUniChar(p, &ch);
- } else if ((unsigned)((UCHAR(*p)-0x80)) < (unsigned) 0x20) {
- ch = (Tcl_UniChar) cp1252[UCHAR(*p++)-0x80];
} else {
ch = UCHAR(*p++);
}
@@ -463,7 +630,59 @@ Tcl_UtfToUniCharDString(
return wString;
}
-
+
+#if (TCL_UTF_MAX > 4) && (defined(__CYGWIN__) || defined(_WIN32))
+WCHAR *
+TclUtfToWCharDString(
+ const char *src, /* UTF-8 string to convert to Unicode. */
+ int length, /* Length of UTF-8 string in bytes, or -1 for
+ * strlen(). */
+ Tcl_DString *dsPtr) /* Unicode representation of string is
+ * appended to this previously initialized
+ * DString. */
+{
+ WCHAR ch = 0, *w, *wString;
+ const char *p, *end;
+ int oldLength;
+
+ if (length < 0) {
+ length = strlen(src);
+ }
+
+ /*
+ * Unicode string length in Tcl_UniChars will be <= UTF-8 string length in
+ * bytes.
+ */
+
+ oldLength = Tcl_DStringLength(dsPtr);
+
+ Tcl_DStringSetLength(dsPtr,
+ oldLength + (int) ((length + 1) * sizeof(WCHAR)));
+ wString = (WCHAR *) (Tcl_DStringValue(dsPtr) + oldLength);
+
+ w = wString;
+ p = src;
+ end = src + length - 4;
+ while (p < end) {
+ p += TclUtfToWChar(p, &ch);
+ *w++ = ch;
+ }
+ end += 4;
+ while (p < end) {
+ if (Tcl_UtfCharComplete(p, end-p)) {
+ p += TclUtfToWChar(p, &ch);
+ } else {
+ ch = UCHAR(*p++);
+ }
+ *w++ = ch;
+ }
+ *w = '\0';
+ Tcl_DStringSetLength(dsPtr,
+ oldLength + ((char *) w - (char *) wString));
+
+ return wString;
+}
+#endif
/*
*---------------------------------------------------------------------------
*
@@ -582,8 +801,8 @@ Tcl_UtfFindFirst(
len = TclUtfToUniChar(src, &find);
fullchar = find;
#if TCL_UTF_MAX <= 4
- if (!len) {
- len += TclUtfToUniChar(src, &find);
+ if ((ch >= 0xD800) && (len < 3)) {
+ len += TclUtfToUniChar(src + len, &find);
fullchar = (((fullchar & 0x3ff) << 10) | (find & 0x3ff)) + 0x10000;
}
#endif
@@ -630,8 +849,8 @@ Tcl_UtfFindLast(
len = TclUtfToUniChar(src, &find);
fullchar = find;
#if TCL_UTF_MAX <= 4
- if (!len) {
- len += TclUtfToUniChar(src, &find);
+ if ((ch >= 0xD800) && (len < 3)) {
+ len += TclUtfToUniChar(src + len, &find);
fullchar = (((fullchar & 0x3ff) << 10) | (find & 0x3ff)) + 0x10000;
}
#endif
@@ -673,8 +892,8 @@ Tcl_UtfNext(
int len = TclUtfToUniChar(src, &ch);
#if TCL_UTF_MAX <= 4
- if (len == 0) {
- len = TclUtfToUniChar(src, &ch);
+ if ((ch >= 0xD800) && (len < 3)) {
+ len += TclUtfToUniChar(src + len, &ch);
}
#endif
return src + len;
@@ -755,7 +974,7 @@ Tcl_UniCharAtIndex(
Tcl_UniChar ch = 0;
int fullchar = 0;
#if TCL_UTF_MAX <= 4
- int len = 1;
+ int len = 0;
#endif
while (index-- >= 0) {
@@ -767,8 +986,8 @@ Tcl_UniCharAtIndex(
}
fullchar = ch;
#if TCL_UTF_MAX <= 4
- if (!len) {
- /* If last Tcl_UniChar was an upper surrogate, combine with lower surrogate */
+ if ((ch >= 0xD800) && (len < 3)) {
+ /* If last Tcl_UniChar was a high surrogate, combine with low surrogate */
(void)TclUtfToUniChar(src, &ch);
fullchar = (((fullchar & 0x3ff) << 10) | (ch & 0x3ff)) + 0x10000;
}
@@ -801,15 +1020,15 @@ Tcl_UtfAtIndex(
register int index) /* The position of the desired character. */
{
Tcl_UniChar ch = 0;
- int len = 1;
+ int len = 0;
while (index-- > 0) {
len = TclUtfToUniChar(src, &ch);
src += len;
}
#if TCL_UTF_MAX <= 4
- if (!len) {
- /* Index points at character following High Surrogate */
+ if ((ch >= 0xD800) && (len < 3)) {
+ /* Index points at character following high Surrogate */
src += TclUtfToUniChar(src, &ch);
}
#endif
@@ -894,7 +1113,7 @@ Tcl_UtfToUpper(
Tcl_UniChar ch = 0;
int upChar;
char *src, *dst;
- int bytes;
+ int len;
/*
* Iterate over the string until we hit the terminating null.
@@ -902,12 +1121,11 @@ Tcl_UtfToUpper(
src = dst = str;
while (*src) {
- bytes = TclUtfToUniChar(src, &ch);
+ len = TclUtfToUniChar(src, &ch);
upChar = ch;
#if TCL_UTF_MAX <= 4
- if (!bytes) {
- /* TclUtfToUniChar only returns 0 for chars > 0xffff ! */
- bytes = TclUtfToUniChar(src, &ch);
+ if ((ch >= 0xD800) && (len < 3)) {
+ len += TclUtfToUniChar(src + len, &ch);
/* Combine surrogates */
upChar = (((upChar & 0x3ff) << 10) | (ch & 0x3ff)) + 0x10000;
}
@@ -920,13 +1138,13 @@ Tcl_UtfToUpper(
* char to dst if its size is <= the original char.
*/
- if ((bytes < TclUtfCount(upChar)) || ((upChar & 0xF800) == 0xD800)) {
- memcpy(dst, src, (size_t) bytes);
- dst += bytes;
+ if ((len < TclUtfCount(upChar)) || ((upChar & 0xF800) == 0xD800)) {
+ memcpy(dst, src, len);
+ dst += len;
} else {
dst += Tcl_UniCharToUtf(upChar, dst);
}
- src += bytes;
+ src += len;
}
*dst = '\0';
return (dst - str);
@@ -957,7 +1175,7 @@ Tcl_UtfToLower(
Tcl_UniChar ch = 0;
int lowChar;
char *src, *dst;
- int bytes;
+ int len;
/*
* Iterate over the string until we hit the terminating null.
@@ -965,12 +1183,11 @@ Tcl_UtfToLower(
src = dst = str;
while (*src) {
- bytes = TclUtfToUniChar(src, &ch);
+ len = TclUtfToUniChar(src, &ch);
lowChar = ch;
#if TCL_UTF_MAX <= 4
- if (!bytes) {
- /* TclUtfToUniChar only returns 0 for chars > 0xffff ! */
- bytes = TclUtfToUniChar(src, &ch);
+ if ((ch >= 0xD800) && (len < 3)) {
+ len += TclUtfToUniChar(src + len, &ch);
/* Combine surrogates */
lowChar = (((lowChar & 0x3ff) << 10) | (ch & 0x3ff)) + 0x10000;
}
@@ -983,13 +1200,13 @@ Tcl_UtfToLower(
* char to dst if its size is <= the original char.
*/
- if ((bytes < TclUtfCount(lowChar)) || ((lowChar & 0xF800) == 0xD800)) {
- memcpy(dst, src, (size_t) bytes);
- dst += bytes;
+ if ((len < TclUtfCount(lowChar)) || ((lowChar & 0xF800) == 0xD800)) {
+ memcpy(dst, src, len);
+ dst += len;
} else {
dst += Tcl_UniCharToUtf(lowChar, dst);
}
- src += bytes;
+ src += len;
}
*dst = '\0';
return (dst - str);
@@ -1021,7 +1238,7 @@ Tcl_UtfToTitle(
Tcl_UniChar ch = 0;
int titleChar, lowChar;
char *src, *dst;
- int bytes;
+ int len;
/*
* Capitalize the first character and then lowercase the rest of the
@@ -1031,33 +1248,31 @@ Tcl_UtfToTitle(
src = dst = str;
if (*src) {
- bytes = TclUtfToUniChar(src, &ch);
+ len = TclUtfToUniChar(src, &ch);
titleChar = ch;
#if TCL_UTF_MAX <= 4
- if (!bytes) {
- /* TclUtfToUniChar only returns 0 for chars > 0xffff ! */
- bytes = TclUtfToUniChar(src, &ch);
+ if ((ch >= 0xD800) && (len < 3)) {
+ len += TclUtfToUniChar(src + len, &ch);
/* Combine surrogates */
titleChar = (((titleChar & 0x3ff) << 10) | (ch & 0x3ff)) + 0x10000;
}
#endif
titleChar = Tcl_UniCharToTitle(titleChar);
- if ((bytes < TclUtfCount(titleChar)) || ((titleChar & 0xF800) == 0xD800)) {
- memcpy(dst, src, (size_t) bytes);
- dst += bytes;
+ if ((len < TclUtfCount(titleChar)) || ((titleChar & 0xF800) == 0xD800)) {
+ memcpy(dst, src, len);
+ dst += len;
} else {
dst += Tcl_UniCharToUtf(titleChar, dst);
}
- src += bytes;
+ src += len;
}
while (*src) {
- bytes = TclUtfToUniChar(src, &ch);
+ len = TclUtfToUniChar(src, &ch);
lowChar = ch;
#if TCL_UTF_MAX <= 4
- if (!bytes) {
- /* TclUtfToUniChar only returns 0 for chars > 0xffff ! */
- bytes = TclUtfToUniChar(src, &ch);
+ if ((ch >= 0xD800) && (len < 3)) {
+ len += TclUtfToUniChar(src + len, &ch);
/* Combine surrogates */
lowChar = (((lowChar & 0x3ff) << 10) | (ch & 0x3ff)) + 0x10000;
}
@@ -1067,13 +1282,13 @@ Tcl_UtfToTitle(
lowChar = Tcl_UniCharToLower(lowChar);
}
- if ((bytes < TclUtfCount(lowChar)) || ((lowChar & 0xF800) == 0xD800)) {
- memcpy(dst, src, (size_t) bytes);
- dst += bytes;
+ if ((len < TclUtfCount(lowChar)) || ((lowChar & 0xF800) == 0xD800)) {
+ memcpy(dst, src, len);
+ dst += len;
} else {
dst += Tcl_UniCharToUtf(lowChar, dst);
}
- src += bytes;
+ src += len;
}
*dst = '\0';
return (dst - str);
@@ -1936,7 +2151,7 @@ Tcl_UniCharCaseMatch(
if ((p != '[') && (p != '?') && (p != '\\')) {
if (nocase) {
while (*uniStr && (p != *uniStr)
- && (p != Tcl_UniCharToLower(*uniStr))) {
+ && (p != (Tcl_UniChar)Tcl_UniCharToLower(*uniStr))) {
uniStr++;
}
} else {
@@ -1976,13 +2191,13 @@ Tcl_UniCharCaseMatch(
Tcl_UniChar startChar, endChar;
uniPattern++;
- ch1 = (nocase ? Tcl_UniCharToLower(*uniStr) : *uniStr);
+ ch1 = (nocase ? (Tcl_UniChar)Tcl_UniCharToLower(*uniStr) : *uniStr);
uniStr++;
while (1) {
if ((*uniPattern == ']') || (*uniPattern == 0)) {
return 0;
}
- startChar = (nocase ? Tcl_UniCharToLower(*uniPattern)
+ startChar = (nocase ? (Tcl_UniChar)Tcl_UniCharToLower(*uniPattern)
: *uniPattern);
uniPattern++;
if (*uniPattern == '-') {
@@ -1990,7 +2205,7 @@ Tcl_UniCharCaseMatch(
if (*uniPattern == 0) {
return 0;
}
- endChar = (nocase ? Tcl_UniCharToLower(*uniPattern)
+ endChar = (nocase ? (Tcl_UniChar)Tcl_UniCharToLower(*uniPattern)
: *uniPattern);
uniPattern++;
if (((startChar <= ch1) && (ch1 <= endChar))
@@ -2128,7 +2343,7 @@ TclUniCharMatch(
if ((p != '[') && (p != '?') && (p != '\\')) {
if (nocase) {
while ((string < stringEnd) && (p != *string)
- && (p != Tcl_UniCharToLower(*string))) {
+ && (p != (Tcl_UniChar)Tcl_UniCharToLower(*string))) {
string++;
}
} else {
@@ -2169,20 +2384,20 @@ TclUniCharMatch(
Tcl_UniChar ch1, startChar, endChar;
pattern++;
- ch1 = (nocase ? Tcl_UniCharToLower(*string) : *string);
+ ch1 = (nocase ? (Tcl_UniChar)Tcl_UniCharToLower(*string) : *string);
string++;
while (1) {
if ((*pattern == ']') || (pattern == patternEnd)) {
return 0;
}
- startChar = (nocase ? Tcl_UniCharToLower(*pattern) : *pattern);
+ startChar = (nocase ? (Tcl_UniChar)Tcl_UniCharToLower(*pattern) : *pattern);
pattern++;
if (*pattern == '-') {
pattern++;
if (pattern == patternEnd) {
return 0;
}
- endChar = (nocase ? Tcl_UniCharToLower(*pattern)
+ endChar = (nocase ? (Tcl_UniChar)Tcl_UniCharToLower(*pattern)
: *pattern);
pattern++;
if (((startChar <= ch1) && (ch1 <= endChar))
diff --git a/generic/tclUtil.c b/generic/tclUtil.c
index 3d4298e..2889852 100644
--- a/generic/tclUtil.c
+++ b/generic/tclUtil.c
@@ -905,7 +905,7 @@ Tcl_SplitList(
}
argv[i] = p;
if (literal) {
- memcpy(p, element, (size_t) elSize);
+ memcpy(p, element, elSize);
p += elSize;
*p = 0;
p++;
@@ -1654,7 +1654,7 @@ Tcl_Backslash(
int *readPtr) /* Fill in with number of characters read from
* src, unless NULL. */
{
- char buf[TCL_UTF_MAX];
+ char buf[4] = "";
Tcl_UniChar ch = 0;
Tcl_UtfBackslash(src, readPtr, buf);
@@ -2049,7 +2049,7 @@ Tcl_Concat(
if (needSpace) {
*p++ = ' ';
}
- memcpy(p, element, (size_t) elemLength);
+ memcpy(p, element, elemLength);
p += elemLength;
needSpace = 1;
}
@@ -2186,6 +2186,7 @@ Tcl_ConcatObj(
return resPtr;
}
+#if !defined(TCL_NO_DEPRECATED) && TCL_MAJOR_VERSION < 9
/*
*----------------------------------------------------------------------
*
@@ -2204,6 +2205,7 @@ Tcl_ConcatObj(
*----------------------------------------------------------------------
*/
+#undef Tcl_StringMatch
int
Tcl_StringMatch(
const char *str, /* String. */
@@ -2212,7 +2214,7 @@ Tcl_StringMatch(
{
return Tcl_StringCaseMatch(str, pattern, 0);
}
-
+#endif /* TCL_NO_DEPRECATED */
/*
*----------------------------------------------------------------------
*
@@ -2302,7 +2304,7 @@ Tcl_StringCaseMatch(
if (nocase) {
while (*str) {
charLen = TclUtfToUniChar(str, &ch1);
- if (ch2==ch1 || ch2==Tcl_UniCharToLower(ch1)) {
+ if (ch2==ch1 || ch2==(Tcl_UniChar)Tcl_UniCharToLower(ch1)) {
break;
}
str += charLen;
@@ -2658,7 +2660,7 @@ TclStringMatchObj(
trivial = nocase ? 0 : TclMatchIsTrivial(TclGetString(ptnObj));
*/
- if ((strObj->typePtr == &tclStringType) || (strObj->typePtr == NULL)) {
+ if (TclHasIntRep(strObj, &tclStringType) || (strObj->typePtr == NULL)) {
Tcl_UniChar *udata, *uptn;
udata = Tcl_GetUnicodeFromObj(strObj, &length);
@@ -2751,7 +2753,7 @@ Tcl_DStringAppend(
if (dsPtr->string == dsPtr->staticSpace) {
char *newString = ckalloc(dsPtr->spaceAvl);
- memcpy(newString, dsPtr->string, (size_t) dsPtr->length);
+ memcpy(newString, dsPtr->string, dsPtr->length);
dsPtr->string = newString;
} else {
int offset = -1;
@@ -2854,7 +2856,7 @@ Tcl_DStringAppendElement(
if (dsPtr->string == dsPtr->staticSpace) {
char *newString = ckalloc(dsPtr->spaceAvl);
- memcpy(newString, dsPtr->string, (size_t) dsPtr->length);
+ memcpy(newString, dsPtr->string, dsPtr->length);
dsPtr->string = newString;
} else {
int offset = -1;
@@ -2948,7 +2950,7 @@ Tcl_DStringSetLength(
if (dsPtr->string == dsPtr->staticSpace) {
char *newString = ckalloc(dsPtr->spaceAvl);
- memcpy(newString, dsPtr->string, (size_t) dsPtr->length);
+ memcpy(newString, dsPtr->string, dsPtr->length);
dsPtr->string = newString;
} else {
dsPtr->string = ckrealloc(dsPtr->string, dsPtr->spaceAvl);
@@ -3446,7 +3448,7 @@ TclPrecTraceProc(
int flags) /* Information about what happened. */
{
Tcl_Obj *value;
- int prec;
+ Tcl_WideInt prec;
int *precisionPtr = Tcl_GetThreadData(&precisionKey, sizeof(int));
/*
@@ -3486,11 +3488,11 @@ TclPrecTraceProc(
}
value = Tcl_GetVar2Ex(interp, name1, name2, flags & TCL_GLOBAL_ONLY);
if (value == NULL
- || Tcl_GetIntFromObj(NULL, value, &prec) != TCL_OK
+ || Tcl_GetWideIntFromObj(NULL, value, &prec) != TCL_OK
|| prec < 0 || prec > TCL_MAX_PREC) {
return (char *) "improper value for precision";
}
- *precisionPtr = prec;
+ *precisionPtr = (int)prec;
return NULL;
}
#endif /* !TCL_NO_DEPRECATED)*/
@@ -3726,7 +3728,7 @@ GetWideForIndex(
/* objPtr holds an integer outside the signed wide range */
/* Truncate to the signed wide range. */
- *widePtr = mp_isneg((mp_int *)cd) ? WIDE_MIN : WIDE_MAX;
+ *widePtr = (((mp_int *)cd)->sign != MP_ZPOS) ? WIDE_MIN : WIDE_MAX;
return TCL_OK;
}
@@ -3839,7 +3841,7 @@ GetWideForIndex(
} else {
/* sum holds an integer outside the signed wide range */
/* Truncate to the signed wide range. */
- if (mp_isneg((mp_int *)cd)) {
+ if (((mp_int *)cd)->sign != MP_ZPOS) {
*widePtr = WIDE_MIN;
} else {
*widePtr = WIDE_MAX;
@@ -3986,7 +3988,7 @@ GetEndOffsetFromObj(
if (t == TCL_NUMBER_BIG) {
/* Truncate to the signed wide range. */
- if (mp_isneg((mp_int *)cd)) {
+ if (((mp_int *)cd)->sign != MP_ZPOS) {
offset = (bytes[3] == '-') ? WIDE_MAX : WIDE_MIN;
} else {
offset = (bytes[3] == '-') ? WIDE_MIN : WIDE_MAX;
diff --git a/generic/tclVar.c b/generic/tclVar.c
index 6b88344..3271935 100644
--- a/generic/tclVar.c
+++ b/generic/tclVar.c
@@ -4122,7 +4122,7 @@ ArraySetCmd(
*/
arrayElemObj = objv[2];
- if (arrayElemObj->typePtr == &tclDictType && arrayElemObj->bytes == NULL) {
+ if (TclHasIntRep(arrayElemObj, &tclDictType) && arrayElemObj->bytes == NULL) {
Tcl_Obj *keyPtr, *valuePtr;
Tcl_DictSearch search;
int done;
diff --git a/generic/tclZipfs.c b/generic/tclZipfs.c
index d02a2da..a80968c 100644
--- a/generic/tclZipfs.c
+++ b/generic/tclZipfs.c
@@ -3155,21 +3155,6 @@ ZipFSListObjCmd(
#ifdef _WIN32
#define LIBRARY_SIZE 64
-
-static inline int
-WCharToUtf(
- const WCHAR *wSrc,
- char *dst)
-{
- char *start = dst;
-
- while (*wSrc != '\0') {
- dst += Tcl_UniCharToUtf(*wSrc, dst);
- wSrc++;
- }
- *dst = '\0';
- return (int) (dst - start);
-}
#endif /* _WIN32 */
Tcl_Obj *
@@ -3213,11 +3198,8 @@ TclZipfs_TclLibrary(void)
#if defined(_WIN32)
hModule = TclWinGetTclInstance();
- if (GetModuleFileNameW(hModule, wName, MAX_PATH) == 0) {
- GetModuleFileNameA(hModule, dllName, MAX_PATH);
- } else {
- WCharToUtf(wName, dllName);
- }
+ GetModuleFileNameW(hModule, wName, MAX_PATH);
+ WideCharToMultiByte(CP_UTF8, 0, wName, -1, dllName, sizeof(dllName), NULL, NULL);
if (ZipfsAppHookFindTclInit(dllName) == TCL_OK) {
return Tcl_NewStringObj(zipfs_literal_tcl_library, -1);
@@ -4865,7 +4847,7 @@ int
TclZipfs_AppHook(
int *argcPtr, /* Pointer to argc */
#ifdef _WIN32
- TCHAR
+ WCHAR
#else /* !_WIN32 */
char
#endif /* _WIN32 */
diff --git a/generic/tclZlib.c b/generic/tclZlib.c
index 32268af..5a7abec 100644
--- a/generic/tclZlib.c
+++ b/generic/tclZlib.c
@@ -422,6 +422,7 @@ GenerateHeader(
{
Tcl_Obj *value;
int len, result = TCL_ERROR;
+ Tcl_WideInt wideValue;
const char *valueStr;
Tcl_Encoding latin1enc;
static const char *const types[] = {
@@ -485,10 +486,11 @@ GenerateHeader(
if (GetValue(interp, dictObj, "time", &value) != TCL_OK) {
goto error;
- } else if (value != NULL && Tcl_GetLongFromObj(interp, value,
- (long *) &headerPtr->header.time) != TCL_OK) {
+ } else if (value != NULL && Tcl_GetWideIntFromObj(interp, value,
+ &wideValue) != TCL_OK) {
goto error;
}
+ headerPtr->header.time = wideValue;
if (GetValue(interp, dictObj, "type", &value) != TCL_OK) {
goto error;
diff --git a/library/init.tcl b/library/init.tcl
index 1ccce27..d5b9c03 100644
--- a/library/init.tcl
+++ b/library/init.tcl
@@ -80,42 +80,6 @@ namespace eval tcl {
namespace eval tcl::Pkg {}
-# Windows specific end of initialization
-
-if {(![interp issafe]) && ($tcl_platform(platform) eq "windows")} {
- namespace eval tcl {
- proc EnvTraceProc {lo n1 n2 op} {
- global env
- set x $env($n2)
- set env($lo) $x
- set env([string toupper $lo]) $x
- }
- proc InitWinEnv {} {
- global env tcl_platform
- foreach p [array names env] {
- set u [string toupper $p]
- if {$u ne $p} {
- switch -- $u {
- COMSPEC -
- PATH {
- set temp $env($p)
- unset env($p)
- set env($u) $temp
- trace add variable env($p) write \
- [namespace code [list EnvTraceProc $p]]
- trace add variable env($u) write \
- [namespace code [list EnvTraceProc $p]]
- }
- }
- }
- }
- if {![info exists env(COMSPEC)]} {
- set env(COMSPEC) cmd.exe
- }
- }
- InitWinEnv
- }
-}
# Setup the unknown package handler
diff --git a/library/tzdata/America/Metlakatla b/library/tzdata/America/Metlakatla
index 3636725..a0385d0 100644
--- a/library/tzdata/America/Metlakatla
+++ b/library/tzdata/America/Metlakatla
@@ -47,7 +47,8 @@ set TZData(:America/Metlakatla) {
{1509876000 -32400 0 AKST}
{1520766000 -28800 1 AKDT}
{1541329200 -28800 0 PST}
- {1552215600 -28800 0 AKDT}
+ {1547978400 -32400 0 AKST}
+ {1552215600 -28800 1 AKDT}
{1572775200 -32400 0 AKST}
{1583665200 -28800 1 AKDT}
{1604224800 -32400 0 AKST}
diff --git a/library/tzdata/Asia/Gaza b/library/tzdata/Asia/Gaza
index 85b9f67..6d0f144 100644
--- a/library/tzdata/Asia/Gaza
+++ b/library/tzdata/Asia/Gaza
@@ -40,6 +40,10 @@ set TZData(:Asia/Gaza) {
{150843600 7200 0 IST}
{167176800 10800 1 IDT}
{178664400 7200 0 IST}
+ {334015200 10800 1 IDT}
+ {337644000 7200 0 IST}
+ {452556000 10800 1 IDT}
+ {462232800 7200 0 IST}
{482277600 10800 1 IDT}
{495579600 7200 0 IST}
{516751200 10800 1 IDT}
@@ -113,7 +117,7 @@ set TZData(:Asia/Gaza) {
{1509141600 7200 0 EET}
{1521846000 10800 1 EEST}
{1540591200 7200 0 EET}
- {1553295600 10800 1 EEST}
+ {1553900400 10800 1 EEST}
{1572040800 7200 0 EET}
{1585350000 10800 1 EEST}
{1604095200 7200 0 EET}
@@ -123,9 +127,9 @@ set TZData(:Asia/Gaza) {
{1666994400 7200 0 EET}
{1679698800 10800 1 EEST}
{1698444000 7200 0 EET}
- {1711148400 10800 1 EEST}
+ {1711753200 10800 1 EEST}
{1729893600 7200 0 EET}
- {1742598000 10800 1 EEST}
+ {1743202800 10800 1 EEST}
{1761343200 7200 0 EET}
{1774652400 10800 1 EEST}
{1793397600 7200 0 EET}
@@ -135,9 +139,9 @@ set TZData(:Asia/Gaza) {
{1856296800 7200 0 EET}
{1869001200 10800 1 EEST}
{1887746400 7200 0 EET}
- {1900450800 10800 1 EEST}
+ {1901055600 10800 1 EEST}
{1919196000 7200 0 EET}
- {1931900400 10800 1 EEST}
+ {1932505200 10800 1 EEST}
{1950645600 7200 0 EET}
{1963954800 10800 1 EEST}
{1982700000 7200 0 EET}
@@ -147,7 +151,7 @@ set TZData(:Asia/Gaza) {
{2045599200 7200 0 EET}
{2058303600 10800 1 EEST}
{2077048800 7200 0 EET}
- {2089753200 10800 1 EEST}
+ {2090358000 10800 1 EEST}
{2108498400 7200 0 EET}
{2121807600 10800 1 EEST}
{2140552800 7200 0 EET}
@@ -157,9 +161,9 @@ set TZData(:Asia/Gaza) {
{2203452000 7200 0 EET}
{2216156400 10800 1 EEST}
{2234901600 7200 0 EET}
- {2247606000 10800 1 EEST}
+ {2248210800 10800 1 EEST}
{2266351200 7200 0 EET}
- {2279055600 10800 1 EEST}
+ {2279660400 10800 1 EEST}
{2297800800 7200 0 EET}
{2311110000 10800 1 EEST}
{2329855200 7200 0 EET}
@@ -169,7 +173,7 @@ set TZData(:Asia/Gaza) {
{2392754400 7200 0 EET}
{2405458800 10800 1 EEST}
{2424204000 7200 0 EET}
- {2436908400 10800 1 EEST}
+ {2437513200 10800 1 EEST}
{2455653600 7200 0 EET}
{2468962800 10800 1 EEST}
{2487708000 7200 0 EET}
@@ -179,9 +183,9 @@ set TZData(:Asia/Gaza) {
{2550607200 7200 0 EET}
{2563311600 10800 1 EEST}
{2582056800 7200 0 EET}
- {2594761200 10800 1 EEST}
+ {2595366000 10800 1 EEST}
{2613506400 7200 0 EET}
- {2626210800 10800 1 EEST}
+ {2626815600 10800 1 EEST}
{2644956000 7200 0 EET}
{2658265200 10800 1 EEST}
{2677010400 7200 0 EET}
@@ -191,9 +195,9 @@ set TZData(:Asia/Gaza) {
{2739909600 7200 0 EET}
{2752614000 10800 1 EEST}
{2771359200 7200 0 EET}
- {2784063600 10800 1 EEST}
+ {2784668400 10800 1 EEST}
{2802808800 7200 0 EET}
- {2815513200 10800 1 EEST}
+ {2816118000 10800 1 EEST}
{2834258400 7200 0 EET}
{2847567600 10800 1 EEST}
{2866312800 7200 0 EET}
@@ -203,7 +207,7 @@ set TZData(:Asia/Gaza) {
{2929212000 7200 0 EET}
{2941916400 10800 1 EEST}
{2960661600 7200 0 EET}
- {2973366000 10800 1 EEST}
+ {2973970800 10800 1 EEST}
{2992111200 7200 0 EET}
{3005420400 10800 1 EEST}
{3024165600 7200 0 EET}
@@ -213,9 +217,9 @@ set TZData(:Asia/Gaza) {
{3087064800 7200 0 EET}
{3099769200 10800 1 EEST}
{3118514400 7200 0 EET}
- {3131218800 10800 1 EEST}
+ {3131823600 10800 1 EEST}
{3149964000 7200 0 EET}
- {3162668400 10800 1 EEST}
+ {3163273200 10800 1 EEST}
{3181413600 7200 0 EET}
{3194722800 10800 1 EEST}
{3213468000 7200 0 EET}
@@ -225,7 +229,7 @@ set TZData(:Asia/Gaza) {
{3276367200 7200 0 EET}
{3289071600 10800 1 EEST}
{3307816800 7200 0 EET}
- {3320521200 10800 1 EEST}
+ {3321126000 10800 1 EEST}
{3339266400 7200 0 EET}
{3352575600 10800 1 EEST}
{3371320800 7200 0 EET}
@@ -235,9 +239,9 @@ set TZData(:Asia/Gaza) {
{3434220000 7200 0 EET}
{3446924400 10800 1 EEST}
{3465669600 7200 0 EET}
- {3478374000 10800 1 EEST}
+ {3478978800 10800 1 EEST}
{3497119200 7200 0 EET}
- {3509823600 10800 1 EEST}
+ {3510428400 10800 1 EEST}
{3528568800 7200 0 EET}
{3541878000 10800 1 EEST}
{3560623200 7200 0 EET}
@@ -247,9 +251,9 @@ set TZData(:Asia/Gaza) {
{3623522400 7200 0 EET}
{3636226800 10800 1 EEST}
{3654972000 7200 0 EET}
- {3667676400 10800 1 EEST}
+ {3668281200 10800 1 EEST}
{3686421600 7200 0 EET}
- {3699126000 10800 1 EEST}
+ {3699730800 10800 1 EEST}
{3717871200 7200 0 EET}
{3731180400 10800 1 EEST}
{3749925600 7200 0 EET}
@@ -259,7 +263,7 @@ set TZData(:Asia/Gaza) {
{3812824800 7200 0 EET}
{3825529200 10800 1 EEST}
{3844274400 7200 0 EET}
- {3856978800 10800 1 EEST}
+ {3857583600 10800 1 EEST}
{3875724000 7200 0 EET}
{3889033200 10800 1 EEST}
{3907778400 7200 0 EET}
@@ -269,9 +273,9 @@ set TZData(:Asia/Gaza) {
{3970677600 7200 0 EET}
{3983382000 10800 1 EEST}
{4002127200 7200 0 EET}
- {4014831600 10800 1 EEST}
+ {4015436400 10800 1 EEST}
{4033576800 7200 0 EET}
- {4046281200 10800 1 EEST}
+ {4046886000 10800 1 EEST}
{4065026400 7200 0 EET}
{4078335600 10800 1 EEST}
{4097080800 7200 0 EET}
diff --git a/library/tzdata/Asia/Hebron b/library/tzdata/Asia/Hebron
index c0f5447..9249910 100644
--- a/library/tzdata/Asia/Hebron
+++ b/library/tzdata/Asia/Hebron
@@ -40,6 +40,10 @@ set TZData(:Asia/Hebron) {
{150843600 7200 0 IST}
{167176800 10800 1 IDT}
{178664400 7200 0 IST}
+ {334015200 10800 1 IDT}
+ {337644000 7200 0 IST}
+ {452556000 10800 1 IDT}
+ {462232800 7200 0 IST}
{482277600 10800 1 IDT}
{495579600 7200 0 IST}
{516751200 10800 1 IDT}
@@ -112,7 +116,7 @@ set TZData(:Asia/Hebron) {
{1509141600 7200 0 EET}
{1521846000 10800 1 EEST}
{1540591200 7200 0 EET}
- {1553295600 10800 1 EEST}
+ {1553900400 10800 1 EEST}
{1572040800 7200 0 EET}
{1585350000 10800 1 EEST}
{1604095200 7200 0 EET}
@@ -122,9 +126,9 @@ set TZData(:Asia/Hebron) {
{1666994400 7200 0 EET}
{1679698800 10800 1 EEST}
{1698444000 7200 0 EET}
- {1711148400 10800 1 EEST}
+ {1711753200 10800 1 EEST}
{1729893600 7200 0 EET}
- {1742598000 10800 1 EEST}
+ {1743202800 10800 1 EEST}
{1761343200 7200 0 EET}
{1774652400 10800 1 EEST}
{1793397600 7200 0 EET}
@@ -134,9 +138,9 @@ set TZData(:Asia/Hebron) {
{1856296800 7200 0 EET}
{1869001200 10800 1 EEST}
{1887746400 7200 0 EET}
- {1900450800 10800 1 EEST}
+ {1901055600 10800 1 EEST}
{1919196000 7200 0 EET}
- {1931900400 10800 1 EEST}
+ {1932505200 10800 1 EEST}
{1950645600 7200 0 EET}
{1963954800 10800 1 EEST}
{1982700000 7200 0 EET}
@@ -146,7 +150,7 @@ set TZData(:Asia/Hebron) {
{2045599200 7200 0 EET}
{2058303600 10800 1 EEST}
{2077048800 7200 0 EET}
- {2089753200 10800 1 EEST}
+ {2090358000 10800 1 EEST}
{2108498400 7200 0 EET}
{2121807600 10800 1 EEST}
{2140552800 7200 0 EET}
@@ -156,9 +160,9 @@ set TZData(:Asia/Hebron) {
{2203452000 7200 0 EET}
{2216156400 10800 1 EEST}
{2234901600 7200 0 EET}
- {2247606000 10800 1 EEST}
+ {2248210800 10800 1 EEST}
{2266351200 7200 0 EET}
- {2279055600 10800 1 EEST}
+ {2279660400 10800 1 EEST}
{2297800800 7200 0 EET}
{2311110000 10800 1 EEST}
{2329855200 7200 0 EET}
@@ -168,7 +172,7 @@ set TZData(:Asia/Hebron) {
{2392754400 7200 0 EET}
{2405458800 10800 1 EEST}
{2424204000 7200 0 EET}
- {2436908400 10800 1 EEST}
+ {2437513200 10800 1 EEST}
{2455653600 7200 0 EET}
{2468962800 10800 1 EEST}
{2487708000 7200 0 EET}
@@ -178,9 +182,9 @@ set TZData(:Asia/Hebron) {
{2550607200 7200 0 EET}
{2563311600 10800 1 EEST}
{2582056800 7200 0 EET}
- {2594761200 10800 1 EEST}
+ {2595366000 10800 1 EEST}
{2613506400 7200 0 EET}
- {2626210800 10800 1 EEST}
+ {2626815600 10800 1 EEST}
{2644956000 7200 0 EET}
{2658265200 10800 1 EEST}
{2677010400 7200 0 EET}
@@ -190,9 +194,9 @@ set TZData(:Asia/Hebron) {
{2739909600 7200 0 EET}
{2752614000 10800 1 EEST}
{2771359200 7200 0 EET}
- {2784063600 10800 1 EEST}
+ {2784668400 10800 1 EEST}
{2802808800 7200 0 EET}
- {2815513200 10800 1 EEST}
+ {2816118000 10800 1 EEST}
{2834258400 7200 0 EET}
{2847567600 10800 1 EEST}
{2866312800 7200 0 EET}
@@ -202,7 +206,7 @@ set TZData(:Asia/Hebron) {
{2929212000 7200 0 EET}
{2941916400 10800 1 EEST}
{2960661600 7200 0 EET}
- {2973366000 10800 1 EEST}
+ {2973970800 10800 1 EEST}
{2992111200 7200 0 EET}
{3005420400 10800 1 EEST}
{3024165600 7200 0 EET}
@@ -212,9 +216,9 @@ set TZData(:Asia/Hebron) {
{3087064800 7200 0 EET}
{3099769200 10800 1 EEST}
{3118514400 7200 0 EET}
- {3131218800 10800 1 EEST}
+ {3131823600 10800 1 EEST}
{3149964000 7200 0 EET}
- {3162668400 10800 1 EEST}
+ {3163273200 10800 1 EEST}
{3181413600 7200 0 EET}
{3194722800 10800 1 EEST}
{3213468000 7200 0 EET}
@@ -224,7 +228,7 @@ set TZData(:Asia/Hebron) {
{3276367200 7200 0 EET}
{3289071600 10800 1 EEST}
{3307816800 7200 0 EET}
- {3320521200 10800 1 EEST}
+ {3321126000 10800 1 EEST}
{3339266400 7200 0 EET}
{3352575600 10800 1 EEST}
{3371320800 7200 0 EET}
@@ -234,9 +238,9 @@ set TZData(:Asia/Hebron) {
{3434220000 7200 0 EET}
{3446924400 10800 1 EEST}
{3465669600 7200 0 EET}
- {3478374000 10800 1 EEST}
+ {3478978800 10800 1 EEST}
{3497119200 7200 0 EET}
- {3509823600 10800 1 EEST}
+ {3510428400 10800 1 EEST}
{3528568800 7200 0 EET}
{3541878000 10800 1 EEST}
{3560623200 7200 0 EET}
@@ -246,9 +250,9 @@ set TZData(:Asia/Hebron) {
{3623522400 7200 0 EET}
{3636226800 10800 1 EEST}
{3654972000 7200 0 EET}
- {3667676400 10800 1 EEST}
+ {3668281200 10800 1 EEST}
{3686421600 7200 0 EET}
- {3699126000 10800 1 EEST}
+ {3699730800 10800 1 EEST}
{3717871200 7200 0 EET}
{3731180400 10800 1 EEST}
{3749925600 7200 0 EET}
@@ -258,7 +262,7 @@ set TZData(:Asia/Hebron) {
{3812824800 7200 0 EET}
{3825529200 10800 1 EEST}
{3844274400 7200 0 EET}
- {3856978800 10800 1 EEST}
+ {3857583600 10800 1 EEST}
{3875724000 7200 0 EET}
{3889033200 10800 1 EEST}
{3907778400 7200 0 EET}
@@ -268,9 +272,9 @@ set TZData(:Asia/Hebron) {
{3970677600 7200 0 EET}
{3983382000 10800 1 EEST}
{4002127200 7200 0 EET}
- {4014831600 10800 1 EEST}
+ {4015436400 10800 1 EEST}
{4033576800 7200 0 EET}
- {4046281200 10800 1 EEST}
+ {4046886000 10800 1 EEST}
{4065026400 7200 0 EET}
{4078335600 10800 1 EEST}
{4097080800 7200 0 EET}
diff --git a/library/tzdata/Asia/Jerusalem b/library/tzdata/Asia/Jerusalem
index 2714963..e1e84f4 100644
--- a/library/tzdata/Asia/Jerusalem
+++ b/library/tzdata/Asia/Jerusalem
@@ -39,6 +39,10 @@ set TZData(:Asia/Jerusalem) {
{150843600 7200 0 IST}
{167176800 10800 1 IDT}
{178664400 7200 0 IST}
+ {334015200 10800 1 IDT}
+ {337644000 7200 0 IST}
+ {452556000 10800 1 IDT}
+ {462232800 7200 0 IST}
{482277600 10800 1 IDT}
{495579600 7200 0 IST}
{516751200 10800 1 IDT}
diff --git a/library/tzdata/Etc/UCT b/library/tzdata/Etc/UCT
index f7d795e..c843cdc 100644
--- a/library/tzdata/Etc/UCT
+++ b/library/tzdata/Etc/UCT
@@ -1,5 +1,5 @@
# created by tools/tclZIC.tcl - do not edit
-
-set TZData(:Etc/UCT) {
- {-9223372036854775808 0 0 UCT}
+if {![info exists TZData(Etc/UTC)]} {
+ LoadTimeZoneFile Etc/UTC
}
+set TZData(:Etc/UCT) $TZData(:Etc/UTC)
diff --git a/library/tzdata/UCT b/library/tzdata/UCT
index 8449328..acfa48e 100644
--- a/library/tzdata/UCT
+++ b/library/tzdata/UCT
@@ -1,5 +1,5 @@
# created by tools/tclZIC.tcl - do not edit
-if {![info exists TZData(Etc/UCT)]} {
- LoadTimeZoneFile Etc/UCT
+if {![info exists TZData(Etc/UTC)]} {
+ LoadTimeZoneFile Etc/UTC
}
-set TZData(:UCT) $TZData(:Etc/UCT)
+set TZData(:UCT) $TZData(:Etc/UTC)
diff --git a/libtommath/bn_mp_clear.c b/libtommath/bn_mp_clear.c
index 1f360b2..b8e724c 100644
--- a/libtommath/bn_mp_clear.c
+++ b/libtommath/bn_mp_clear.c
@@ -25,7 +25,7 @@ void mp_clear(mp_int *a)
}
/* free ram */
- XFREE(a->dp);
+ XFREE(a->dp, sizeof (mp_digit) * (size_t)a->alloc);
/* reset members to make debugging easier */
a->dp = NULL;
diff --git a/libtommath/bn_mp_fwrite.c b/libtommath/bn_mp_fwrite.c
index 9f0c3df..85a942f 100644
--- a/libtommath/bn_mp_fwrite.c
+++ b/libtommath/bn_mp_fwrite.c
@@ -22,24 +22,24 @@ int mp_fwrite(const mp_int *a, int radix, FILE *stream)
return err;
}
- buf = OPT_CAST(char) XMALLOC((size_t)len);
+ buf = (char *) XMALLOC((size_t)len);
if (buf == NULL) {
return MP_MEM;
}
if ((err = mp_toradix(a, buf, radix)) != MP_OKAY) {
- XFREE(buf);
+ XFREE(buf, len);
return err;
}
for (x = 0; x < len; x++) {
if (fputc((int)buf[x], stream) == EOF) {
- XFREE(buf);
+ XFREE(buf, len);
return MP_VAL;
}
}
- XFREE(buf);
+ XFREE(buf, len);
return MP_OKAY;
}
#endif
diff --git a/libtommath/bn_mp_get_bit.c b/libtommath/bn_mp_get_bit.c
index ab732c4..f5d2450 100644
--- a/libtommath/bn_mp_get_bit.c
+++ b/libtommath/bn_mp_get_bit.c
@@ -27,18 +27,8 @@ int mp_get_bit(const mp_int *a, int b)
limb = b / DIGIT_BIT;
- /*
- * Zero is a special value with the member "used" set to zero.
- * Needs to be tested before the check for the upper boundary
- * otherwise (limb >= a->used) would be true for a = 0
- */
-
- if (mp_iszero(a) != MP_NO) {
- return MP_NO;
- }
-
if (limb >= a->used) {
- return MP_VAL;
+ return MP_NO;
}
bit = (mp_digit)(1) << (b % DIGIT_BIT);
diff --git a/libtommath/bn_mp_get_double.c b/libtommath/bn_mp_get_double.c
index 3ed5a71..629eae3 100644
--- a/libtommath/bn_mp_get_double.c
+++ b/libtommath/bn_mp_get_double.c
@@ -19,10 +19,10 @@ double mp_get_double(const mp_int *a)
for (i = 0; i < DIGIT_BIT; ++i) {
fac *= 2.0;
}
- for (i = USED(a); i --> 0;) {
- d = (d * fac) + (double)DIGIT(a, i);
+ for (i = a->used; i --> 0;) {
+ d = (d * fac) + (double)a->dp[i];
}
- return (mp_isneg(a) != MP_NO) ? -d : d;
+ return (a->sign == MP_NEG) ? -d : d;
}
#endif
diff --git a/libtommath/bn_mp_get_int.c b/libtommath/bn_mp_get_int.c
index 13eddbf..d9c7a11 100644
--- a/libtommath/bn_mp_get_int.c
+++ b/libtommath/bn_mp_get_int.c
@@ -15,25 +15,8 @@
/* get the lower 32-bits of an mp_int */
unsigned long mp_get_int(const mp_int *a)
{
- int i;
- mp_min_u32 res;
-
- if (a->used == 0) {
- return 0;
- }
-
- /* get number of digits of the lsb we have to read */
- i = MIN(a->used, ((((int)sizeof(unsigned long) * CHAR_BIT) + DIGIT_BIT - 1) / DIGIT_BIT)) - 1;
-
- /* get most significant digit of result */
- res = DIGIT(a, i);
-
- while (--i >= 0) {
- res = (res << DIGIT_BIT) | DIGIT(a, i);
- }
-
/* force result to 32-bits always so it is consistent on non 32-bit platforms */
- return res & 0xFFFFFFFFUL;
+ return mp_get_long(a) & 0xFFFFFFFFUL;
}
#endif
diff --git a/libtommath/bn_mp_get_long.c b/libtommath/bn_mp_get_long.c
index a4d05d6..b95bb8a 100644
--- a/libtommath/bn_mp_get_long.c
+++ b/libtommath/bn_mp_get_long.c
@@ -18,19 +18,19 @@ unsigned long mp_get_long(const mp_int *a)
int i;
unsigned long res;
- if (a->used == 0) {
+ if (IS_ZERO(a)) {
return 0;
}
/* get number of digits of the lsb we have to read */
- i = MIN(a->used, ((((int)sizeof(unsigned long) * CHAR_BIT) + DIGIT_BIT - 1) / DIGIT_BIT)) - 1;
+ i = MIN(a->used, (((CHAR_BIT * (int)sizeof(unsigned long)) + DIGIT_BIT - 1) / DIGIT_BIT)) - 1;
/* get most significant digit of result */
- res = DIGIT(a, i);
+ res = (unsigned long)a->dp[i];
-#if (ULONG_MAX != 0xffffffffuL) || (DIGIT_BIT < 32)
+#if (ULONG_MAX != 0xFFFFFFFFUL) || (DIGIT_BIT < 32)
while (--i >= 0) {
- res = (res << DIGIT_BIT) | DIGIT(a, i);
+ res = (res << DIGIT_BIT) | (unsigned long)a->dp[i];
}
#endif
return res;
diff --git a/libtommath/bn_mp_get_long_long.c b/libtommath/bn_mp_get_long_long.c
index 61d16ea..49a0208 100644
--- a/libtommath/bn_mp_get_long_long.c
+++ b/libtommath/bn_mp_get_long_long.c
@@ -18,19 +18,19 @@ Tcl_WideUInt mp_get_long_long(const mp_int *a)
int i;
Tcl_WideUInt res;
- if (a->used == 0) {
+ if (IS_ZERO(a)) {
return 0;
}
/* get number of digits of the lsb we have to read */
- i = MIN(a->used, ((((int)sizeof(Tcl_WideUInt) * CHAR_BIT) + DIGIT_BIT - 1) / DIGIT_BIT)) - 1;
+ i = MIN(a->used, (((CHAR_BIT * (int)sizeof(Tcl_WideUInt)) + DIGIT_BIT - 1) / DIGIT_BIT)) - 1;
/* get most significant digit of result */
- res = DIGIT(a, i);
+ res = (unsigned long long)a->dp[i];
#if DIGIT_BIT < 64
while (--i >= 0) {
- res = (res << DIGIT_BIT) | DIGIT(a, i);
+ res = (res << DIGIT_BIT) | (unsigned long long)a->dp[i];
}
#endif
return res;
diff --git a/libtommath/bn_mp_grow.c b/libtommath/bn_mp_grow.c
index 1d92b29..b120194 100644
--- a/libtommath/bn_mp_grow.c
+++ b/libtommath/bn_mp_grow.c
@@ -29,7 +29,9 @@ int mp_grow(mp_int *a, int size)
* in case the operation failed we don't want
* to overwrite the dp member of a.
*/
- tmp = OPT_CAST(mp_digit) XREALLOC(a->dp, sizeof(mp_digit) * (size_t)size);
+ tmp = (mp_digit *) XREALLOC(a->dp,
+ (size_t)a->alloc * sizeof (mp_digit),
+ (size_t)size * sizeof(mp_digit));
if (tmp == NULL) {
/* reallocation failed but "a" is still valid [can be freed] */
return MP_MEM;
diff --git a/libtommath/bn_mp_init.c b/libtommath/bn_mp_init.c
index 7520089..3c0c489 100644
--- a/libtommath/bn_mp_init.c
+++ b/libtommath/bn_mp_init.c
@@ -18,7 +18,7 @@ int mp_init(mp_int *a)
int i;
/* allocate memory required and clear it */
- a->dp = OPT_CAST(mp_digit) XMALLOC(sizeof(mp_digit) * (size_t)MP_PREC);
+ a->dp = (mp_digit *) XMALLOC(MP_PREC * sizeof(mp_digit));
if (a->dp == NULL) {
return MP_MEM;
}
diff --git a/libtommath/bn_mp_init_size.c b/libtommath/bn_mp_init_size.c
index 9b933fb..1becb23 100644
--- a/libtommath/bn_mp_init_size.c
+++ b/libtommath/bn_mp_init_size.c
@@ -21,7 +21,7 @@ int mp_init_size(mp_int *a, int size)
size += (MP_PREC * 2) - (size % MP_PREC);
/* alloc mem */
- a->dp = OPT_CAST(mp_digit) XMALLOC(sizeof(mp_digit) * (size_t)size);
+ a->dp = (mp_digit *) XMALLOC((size_t)size * sizeof(mp_digit));
if (a->dp == NULL) {
return MP_MEM;
}
diff --git a/libtommath/bn_mp_is_square.c b/libtommath/bn_mp_is_square.c
index 5363a47..1dd1d6c 100644
--- a/libtommath/bn_mp_is_square.c
+++ b/libtommath/bn_mp_is_square.c
@@ -49,13 +49,12 @@ int mp_is_square(const mp_int *arg, int *ret)
return MP_VAL;
}
- /* digits used? (TSD) */
- if (arg->used == 0) {
+ if (IS_ZERO(arg)) {
return MP_OKAY;
}
/* First check mod 128 (suppose that DIGIT_BIT is at least 7) */
- if (rem_128[127u & DIGIT(arg, 0)] == (char)1) {
+ if (rem_128[127u & arg->dp[0]] == (char)1) {
return MP_OKAY;
}
diff --git a/libtommath/bn_mp_prime_random_ex.c b/libtommath/bn_mp_prime_random_ex.c
index b0b4632..0ca29ec 100644
--- a/libtommath/bn_mp_prime_random_ex.c
+++ b/libtommath/bn_mp_prime_random_ex.c
@@ -46,19 +46,19 @@ int mp_prime_random_ex(mp_int *a, int t, int size, int flags, ltm_prime_callback
bsize = (size>>3) + ((size&7)?1:0);
/* we need a buffer of bsize bytes */
- tmp = OPT_CAST(unsigned char) XMALLOC((size_t)bsize);
+ tmp = (unsigned char *) XMALLOC((size_t)bsize);
if (tmp == NULL) {
return MP_MEM;
}
/* calc the maskAND value for the MSbyte*/
- maskAND = ((size&7) == 0) ? 0xFF : (0xFF >> (8 - (size & 7)));
+ maskAND = ((size&7) == 0) ? 0xFF : (unsigned char)(0xFF >> (8 - (size & 7)));
/* calc the maskOR_msb */
maskOR_msb = 0;
maskOR_msb_offset = ((size & 7) == 1) ? 1 : 0;
if ((flags & LTM_PRIME_2MSB_ON) != 0) {
- maskOR_msb |= 0x80 >> ((9 - size) & 7);
+ maskOR_msb |= (unsigned char)(0x80 >> ((9 - size) & 7));
}
/* get the maskOR_lsb */
@@ -76,7 +76,7 @@ int mp_prime_random_ex(mp_int *a, int t, int size, int flags, ltm_prime_callback
/* work over the MSbyte */
tmp[0] &= maskAND;
- tmp[0] |= 1 << ((size - 1) & 7);
+ tmp[0] |= (unsigned char)(1 << ((size - 1) & 7));
/* mix in the maskORs */
tmp[maskOR_msb_offset] |= maskOR_msb;
@@ -123,7 +123,7 @@ int mp_prime_random_ex(mp_int *a, int t, int size, int flags, ltm_prime_callback
err = MP_OKAY;
error:
- XFREE(tmp);
+ XFREE(tmp, bsize);
return err;
}
diff --git a/libtommath/bn_mp_read_radix.c b/libtommath/bn_mp_read_radix.c
index 200601e..a8723b7 100644
--- a/libtommath/bn_mp_read_radix.c
+++ b/libtommath/bn_mp_read_radix.c
@@ -12,6 +12,8 @@
* SPDX-License-Identifier: Unlicense
*/
+#define MP_TOUPPER(c) ((((c) >= 'a') && ((c) <= 'z')) ? (((c) + 'A') - 'a') : (c))
+
/* read a string [ASCII] in a given radix */
int mp_read_radix(mp_int *a, const char *str, int radix)
{
@@ -46,7 +48,7 @@ int mp_read_radix(mp_int *a, const char *str, int radix)
* this allows numbers like 1AB and 1ab to represent the same value
* [e.g. in hex]
*/
- ch = (radix <= 36) ? (char)toupper((int)*str) : *str;
+ ch = (radix <= 36) ? (char)MP_TOUPPER((int)*str) : *str;
pos = (unsigned)(ch - '(');
if (mp_s_rmap_reverse_sz < pos) {
break;
diff --git a/libtommath/bn_mp_set_double.c b/libtommath/bn_mp_set_double.c
index 76f6293..c96a3b3 100644
--- a/libtommath/bn_mp_set_double.c
+++ b/libtommath/bn_mp_set_double.c
@@ -41,8 +41,8 @@ int mp_set_double(mp_int *a, double b)
return res;
}
- if (((cast.bits >> 63) != 0ULL) && (mp_iszero(a) == MP_NO)) {
- SIGN(a) = MP_NEG;
+ if (((cast.bits >> 63) != 0ULL) && !IS_ZERO(a)) {
+ a->sign = MP_NEG;
}
return MP_OKAY;
diff --git a/libtommath/bn_mp_shrink.c b/libtommath/bn_mp_shrink.c
index ff7905f..fa30184 100644
--- a/libtommath/bn_mp_shrink.c
+++ b/libtommath/bn_mp_shrink.c
@@ -23,7 +23,9 @@ int mp_shrink(mp_int *a)
}
if (a->alloc != used) {
- if ((tmp = OPT_CAST(mp_digit) XREALLOC(a->dp, sizeof(mp_digit) * (size_t)used)) == NULL) {
+ if ((tmp = (mp_digit *) XREALLOC(a->dp,
+ (size_t)a->alloc * sizeof (mp_digit),
+ (size_t)used * sizeof(mp_digit))) == NULL) {
return MP_MEM;
}
a->dp = tmp;
diff --git a/libtommath/tommath.h b/libtommath/tommath.h
index ce38975..b5faf8c 100644
--- a/libtommath/tommath.h
+++ b/libtommath/tommath.h
@@ -23,7 +23,7 @@ extern "C" {
#endif
/* MS Visual C++ doesn't have a 128bit type for words, so fall back to 32bit MPI's (where words are 64bit) */
-#if defined(_MSC_VER) || defined(__LLP64__) || defined(__e2k__) || defined(__LCC__)
+#if defined(_WIN32) || defined(__LLP64__) || defined(__e2k__) || defined(__LCC__)
# define MP_32BIT
#endif
@@ -91,17 +91,7 @@ typedef unsigned long long mp_word;
# endif
#endif
-/* otherwise the bits per digit is calculated automatically from the size of a mp_digit */
-#ifndef DIGIT_BIT
-# define DIGIT_BIT (((CHAR_BIT * MP_SIZEOF_MP_DIGIT) - 1)) /* bits per digit */
-typedef unsigned long mp_min_u32;
-#else
-typedef mp_digit mp_min_u32;
-#endif
-
-#define MP_DIGIT_BIT DIGIT_BIT
#define MP_MASK ((((mp_digit)1)<<((mp_digit)DIGIT_BIT))-((mp_digit)1))
-#define MP_DIGIT_MAX MP_MASK
/* equalities */
#define MP_LT -1 /* less than */
@@ -127,12 +117,6 @@ typedef mp_digit mp_min_u32;
typedef int mp_err;
-/* you'll have to tune these... */
-extern int KARATSUBA_MUL_CUTOFF,
- KARATSUBA_SQR_CUTOFF,
- TOOM_MUL_CUTOFF,
- TOOM_SQR_CUTOFF;
-
/* define this to use lower memory usage routines (exptmods mostly) */
/* #define MP_LOW_MEM */
@@ -145,9 +129,6 @@ extern int KARATSUBA_MUL_CUTOFF,
# endif
#endif
-/* size of comba arrays, should be at least 2 * 2**(BITS_PER_WORD - BITS_PER_DIGIT*2) */
-#define MP_WARRAY (1u << (((sizeof(mp_word) * CHAR_BIT) - (2 * DIGIT_BIT)) + 1))
-
/* the infamous mp_int structure */
typedef struct {
int used, alloc, sign;
@@ -158,10 +139,6 @@ typedef struct {
typedef int ltm_prime_callback(unsigned char *dst, int len, void *dat);
-#define USED(m) ((m)->used)
-#define DIGIT(m, k) ((m)->dp[(k)])
-#define SIGN(m) ((m)->sign)
-
/* error code to char* string */
const char *mp_error_to_string(int code);
@@ -192,8 +169,8 @@ int mp_init_size(mp_int *a, int size);
/* ---> Basic Manipulations <--- */
#define mp_iszero(a) (((a)->used == 0) ? MP_YES : MP_NO)
-#define mp_iseven(a) ((((a)->used == 0) || (((a)->dp[0] & 1u) == 0u)) ? MP_YES : MP_NO)
-#define mp_isodd(a) ((((a)->used > 0) && (((a)->dp[0] & 1u) == 1u)) ? MP_YES : MP_NO)
+#define mp_iseven(a) (!mp_get_bit((a),0))
+#define mp_isodd(a) mp_get_bit((a),0)
#define mp_isneg(a) (((a)->sign != MP_ZPOS) ? MP_YES : MP_NO)
/* set to zero */
diff --git a/libtommath/tommath_private.h b/libtommath/tommath_private.h
index 8fc3442..b3600a0 100644
--- a/libtommath/tommath_private.h
+++ b/libtommath/tommath_private.h
@@ -13,7 +13,6 @@
#define TOMMATH_PRIV_H_
#include <tommath.h>
-#include <ctype.h>
#ifndef MIN
#define MIN(x, y) (((x) < (y)) ? (x) : (y))
@@ -25,32 +24,35 @@
#ifdef __cplusplus
extern "C" {
-
-/* C++ compilers don't like assigning void * to mp_digit * */
-#define OPT_CAST(x) (x *)
-
-#else
-
-/* C on the other hand doesn't care */
-#define OPT_CAST(x)
-
#endif
/* define heap macros */
#ifndef XMALLOC
/* default to libc stuff */
-# define XMALLOC malloc
-# define XFREE free
-# define XREALLOC realloc
-# define XCALLOC calloc
+# define XMALLOC(size) malloc(size)
+# define XFREE(mem, size) free(mem)
+# define XREALLOC(mem, oldsize, newsize) realloc(mem, newsize)
#elif 0
/* prototypes for our heap functions */
-extern void *XMALLOC(size_t n);
-extern void *XREALLOC(void *p, size_t n);
-extern void *XCALLOC(size_t n, size_t s);
-extern void XFREE(void *p);
+extern void *XMALLOC(size_t size);
+extern void *XREALLOC(void *mem, size_t oldsize, size_t newsize);
+extern void XFREE(void *mem, size_t size);
#endif
+/* you'll have to tune these... */
+#define KARATSUBA_MUL_CUTOFF 80 /* Min. number of digits before Karatsuba multiplication is used. */
+#define KARATSUBA_SQR_CUTOFF 120 /* Min. number of digits before Karatsuba squaring is used. */
+#define TOOM_MUL_CUTOFF 350 /* no optimal values of these are known yet so set em high */
+#define TOOM_SQR_CUTOFF 400
+
+/* size of comba arrays, should be at least 2 * 2**(BITS_PER_WORD - BITS_PER_DIGIT*2) */
+#define MP_WARRAY (1u << (((sizeof(mp_word) * CHAR_BIT) - (2 * DIGIT_BIT)) + 1))
+
+/* ---> Basic Manipulations <--- */
+#define IS_ZERO(a) ((a)->used == 0)
+#define IS_EVEN(a) (((a)->used == 0) || (((a)->dp[0] & 1u) == 0u))
+#define IS_ODD(a) (((a)->used > 0) && (((a)->dp[0] & 1u) == 1u))
+
/* lowlevel functions, do not call! */
int s_mp_add(const mp_int *a, const mp_int *b, mp_int *c);
int s_mp_sub(const mp_int *a, const mp_int *b, mp_int *c);
@@ -78,36 +80,26 @@ extern const size_t mp_s_rmap_reverse_sz;
/* Fancy macro to set an MPI from another type.
* There are several things assumed:
- * x is the counter and unsigned
+ * x is the counter
* a is the pointer to the MPI
* b is the original value that should be set in the MPI.
*/
#define MP_SET_XLONG(func_name, type) \
int func_name (mp_int * a, type b) \
{ \
- unsigned int x; \
- int res; \
- \
- mp_zero (a); \
- \
- /* set four bits at a time */ \
- for (x = 0; x < (sizeof(type) * 2u); x++) { \
- /* shift the number up four bits */ \
- if ((res = mp_mul_2d (a, 4, a)) != MP_OKAY) { \
- return res; \
- } \
- \
- /* OR in the top four bits of the source */ \
- a->dp[0] |= (mp_digit)(b >> ((sizeof(type) * 8u) - 4u)) & 15uL;\
- \
- /* shift the source up to the next four bits */ \
- b <<= 4; \
- \
- /* ensure that digits are not clamped off */ \
- a->used += 1; \
- } \
- mp_clamp (a); \
- return MP_OKAY; \
+ int x = 0; \
+ int new_size = (((CHAR_BIT * sizeof(type)) + DIGIT_BIT) - 1) / DIGIT_BIT; \
+ int res = mp_grow(a, new_size); \
+ if (res == MP_OKAY) { \
+ mp_zero(a); \
+ while (b != 0u) { \
+ a->dp[x++] = ((mp_digit)b & MP_MASK); \
+ if ((CHAR_BIT * sizeof (b)) <= DIGIT_BIT) { break; } \
+ b >>= ((CHAR_BIT * sizeof (b)) <= DIGIT_BIT ? 0 : DIGIT_BIT); \
+ } \
+ a->used = x; \
+ } \
+ return res; \
}
#ifdef __cplusplus
diff --git a/macosx/Tcl.xcode/project.pbxproj b/macosx/Tcl.xcode/project.pbxproj
index 51e9c68..5fb9a47 100644
--- a/macosx/Tcl.xcode/project.pbxproj
+++ b/macosx/Tcl.xcode/project.pbxproj
@@ -145,7 +145,6 @@
F96D495108F272C3004A47F5 /* bn_s_mp_mul_digs.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D42D308F272B3004A47F5 /* bn_s_mp_mul_digs.c */; };
F96D495308F272C3004A47F5 /* bn_s_mp_sqr.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D42D508F272B3004A47F5 /* bn_s_mp_sqr.c */; };
F96D495408F272C3004A47F5 /* bn_s_mp_sub.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D42D608F272B3004A47F5 /* bn_s_mp_sub.c */; };
- F96D495508F272C3004A47F5 /* bncore.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D42D708F272B3004A47F5 /* bncore.c */; };
F96D49A908F272C4004A47F5 /* tclMacOSXBundle.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D433908F272B5004A47F5 /* tclMacOSXBundle.c */; };
F96D49AD08F272C4004A47F5 /* tclMacOSXFCmd.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D433D08F272B5004A47F5 /* tclMacOSXFCmd.c */; };
F96D49AE08F272C4004A47F5 /* tclMacOSXNotify.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D433E08F272B5004A47F5 /* tclMacOSXNotify.c */; };
@@ -620,7 +619,6 @@
F96D42D308F272B3004A47F5 /* bn_s_mp_mul_digs.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = bn_s_mp_mul_digs.c; sourceTree = "<group>"; };
F96D42D508F272B3004A47F5 /* bn_s_mp_sqr.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = bn_s_mp_sqr.c; sourceTree = "<group>"; };
F96D42D608F272B3004A47F5 /* bn_s_mp_sub.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = bn_s_mp_sub.c; sourceTree = "<group>"; };
- F96D42D708F272B3004A47F5 /* bncore.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = bncore.c; sourceTree = "<group>"; };
F96D432908F272B4004A47F5 /* tommath_class.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tommath_class.h; sourceTree = "<group>"; };
F96D432A08F272B4004A47F5 /* tommath_superclass.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tommath_superclass.h; sourceTree = "<group>"; };
F96D432B08F272B4004A47F5 /* license.terms */ = {isa = PBXFileReference; explicitFileType = text; fileEncoding = 4; path = license.terms; sourceTree = "<group>"; };
@@ -1482,7 +1480,6 @@
F96D42D308F272B3004A47F5 /* bn_s_mp_mul_digs.c */,
F96D42D508F272B3004A47F5 /* bn_s_mp_sqr.c */,
F96D42D608F272B3004A47F5 /* bn_s_mp_sub.c */,
- F96D42D708F272B3004A47F5 /* bncore.c */,
F96D432908F272B4004A47F5 /* tommath_class.h */,
F96D432A08F272B4004A47F5 /* tommath_superclass.h */,
);
@@ -2114,7 +2111,6 @@
F96D495108F272C3004A47F5 /* bn_s_mp_mul_digs.c in Sources */,
F96D495308F272C3004A47F5 /* bn_s_mp_sqr.c in Sources */,
F96D495408F272C3004A47F5 /* bn_s_mp_sub.c in Sources */,
- F96D495508F272C3004A47F5 /* bncore.c in Sources */,
F96D49A908F272C4004A47F5 /* tclMacOSXBundle.c in Sources */,
F96D49AD08F272C4004A47F5 /* tclMacOSXFCmd.c in Sources */,
F96D49AE08F272C4004A47F5 /* tclMacOSXNotify.c in Sources */,
diff --git a/macosx/Tcl.xcodeproj/project.pbxproj b/macosx/Tcl.xcodeproj/project.pbxproj
index cef23e3..408af36 100644
--- a/macosx/Tcl.xcodeproj/project.pbxproj
+++ b/macosx/Tcl.xcodeproj/project.pbxproj
@@ -145,7 +145,6 @@
F96D495108F272C3004A47F5 /* bn_s_mp_mul_digs.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D42D308F272B3004A47F5 /* bn_s_mp_mul_digs.c */; };
F96D495308F272C3004A47F5 /* bn_s_mp_sqr.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D42D508F272B3004A47F5 /* bn_s_mp_sqr.c */; };
F96D495408F272C3004A47F5 /* bn_s_mp_sub.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D42D608F272B3004A47F5 /* bn_s_mp_sub.c */; };
- F96D495508F272C3004A47F5 /* bncore.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D42D708F272B3004A47F5 /* bncore.c */; };
F96D49A908F272C4004A47F5 /* tclMacOSXBundle.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D433908F272B5004A47F5 /* tclMacOSXBundle.c */; };
F96D49AD08F272C4004A47F5 /* tclMacOSXFCmd.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D433D08F272B5004A47F5 /* tclMacOSXFCmd.c */; };
F96D49AE08F272C4004A47F5 /* tclMacOSXNotify.c in Sources */ = {isa = PBXBuildFile; fileRef = F96D433E08F272B5004A47F5 /* tclMacOSXNotify.c */; };
@@ -621,7 +620,6 @@
F96D42D308F272B3004A47F5 /* bn_s_mp_mul_digs.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = bn_s_mp_mul_digs.c; sourceTree = "<group>"; };
F96D42D508F272B3004A47F5 /* bn_s_mp_sqr.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = bn_s_mp_sqr.c; sourceTree = "<group>"; };
F96D42D608F272B3004A47F5 /* bn_s_mp_sub.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = bn_s_mp_sub.c; sourceTree = "<group>"; };
- F96D42D708F272B3004A47F5 /* bncore.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = bncore.c; sourceTree = "<group>"; };
F96D432908F272B4004A47F5 /* tommath_class.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tommath_class.h; sourceTree = "<group>"; };
F96D432A08F272B4004A47F5 /* tommath_superclass.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tommath_superclass.h; sourceTree = "<group>"; };
F96D432B08F272B4004A47F5 /* license.terms */ = {isa = PBXFileReference; explicitFileType = text; fileEncoding = 4; path = license.terms; sourceTree = "<group>"; };
@@ -1483,7 +1481,6 @@
F96D42D308F272B3004A47F5 /* bn_s_mp_mul_digs.c */,
F96D42D508F272B3004A47F5 /* bn_s_mp_sqr.c */,
F96D42D608F272B3004A47F5 /* bn_s_mp_sub.c */,
- F96D42D708F272B3004A47F5 /* bncore.c */,
F96D432908F272B4004A47F5 /* tommath_class.h */,
F96D432A08F272B4004A47F5 /* tommath_superclass.h */,
);
@@ -2115,7 +2112,6 @@
F96D495108F272C3004A47F5 /* bn_s_mp_mul_digs.c in Sources */,
F96D495308F272C3004A47F5 /* bn_s_mp_sqr.c in Sources */,
F96D495408F272C3004A47F5 /* bn_s_mp_sub.c in Sources */,
- F96D495508F272C3004A47F5 /* bncore.c in Sources */,
F96D49A908F272C4004A47F5 /* tclMacOSXBundle.c in Sources */,
F96D49AD08F272C4004A47F5 /* tclMacOSXFCmd.c in Sources */,
F96D49AE08F272C4004A47F5 /* tclMacOSXNotify.c in Sources */,
diff --git a/macosx/tclMacOSXFCmd.c b/macosx/tclMacOSXFCmd.c
index f09a441..7c65088 100644
--- a/macosx/tclMacOSXFCmd.c
+++ b/macosx/tclMacOSXFCmd.c
@@ -192,7 +192,7 @@ TclMacOSXGetFileAttribute(
OSSwapBigToHostInt32(finder->type));
break;
case MACOSX_HIDDEN_ATTRIBUTE:
- *attributePtrPtr = Tcl_NewBooleanObj(
+ *attributePtrPtr = Tcl_NewWideIntObj(
(finder->fdFlags & kFinfoIsInvisible) != 0);
break;
case MACOSX_RSRCLENGTH_ATTRIBUTE:
@@ -577,10 +577,10 @@ GetOSTypeFromObj(
{
int result = TCL_OK;
- if (objPtr->typePtr != &tclOSTypeType) {
+ if (!TclHasIntRep(objPtr, &tclOSTypeType)) {
result = SetOSTypeFromAny(interp, objPtr);
}
- *osTypePtr = (OSType) objPtr->internalRep.longValue;
+ *osTypePtr = (OSType) objPtr->internalRep.wideValue;
return result;
}
@@ -609,7 +609,7 @@ NewOSTypeObj(
TclNewObj(objPtr);
TclInvalidateStringRep(objPtr);
- objPtr->internalRep.longValue = (long) osType;
+ objPtr->internalRep.wideValue = (Tcl_WideInt) osType;
objPtr->typePtr = &tclOSTypeType;
return objPtr;
}
@@ -654,13 +654,13 @@ SetOSTypeFromAny(
OSType osType;
char bytes[4] = {'\0','\0','\0','\0'};
- memcpy(bytes, Tcl_DStringValue(&ds), (size_t)Tcl_DStringLength(&ds));
+ memcpy(bytes, Tcl_DStringValue(&ds), Tcl_DStringLength(&ds));
osType = (OSType) bytes[0] << 24 |
(OSType) bytes[1] << 16 |
(OSType) bytes[2] << 8 |
(OSType) bytes[3];
TclFreeIntRep(objPtr);
- objPtr->internalRep.longValue = (long) osType;
+ objPtr->internalRep.wideValue = (Tcl_WideInt) osType;
objPtr->typePtr = &tclOSTypeType;
}
Tcl_DStringFree(&ds);
@@ -694,7 +694,7 @@ UpdateStringOfOSType(
{
const int size = TCL_UTF_MAX * 4;
char *dst = Tcl_InitStringRep(objPtr, NULL, size);
- OSType osType = (OSType) objPtr->internalRep.longValue;
+ OSType osType = (OSType) objPtr->internalRep.wideValue;
int written = 0;
Tcl_Encoding encoding;
char src[5];
diff --git a/tests-perf/clock.perf.tcl b/tests-perf/clock.perf.tcl
new file mode 100644
index 0000000..f80746f
--- /dev/null
+++ b/tests-perf/clock.perf.tcl
@@ -0,0 +1,411 @@
+#!/usr/bin/tclsh
+# ------------------------------------------------------------------------
+#
+# test-performance.tcl --
+#
+# This file provides common performance tests for comparison of tcl-speed
+# degradation by switching between branches.
+# (currently for clock ensemble only)
+#
+# ------------------------------------------------------------------------
+#
+# Copyright (c) 2014 Serg G. Brester (aka sebres)
+#
+# See the file "license.terms" for information on usage and redistribution
+# of this file.
+#
+
+array set in {-time 500}
+if {[info exists ::argv0] && [file tail $::argv0] eq [file tail [info script]]} {
+ array set in $argv
+}
+
+## common test performance framework:
+if {![namespace exists ::tclTestPerf]} {
+ source [file join [file dirname [info script]] test-performance.tcl]
+}
+
+namespace eval ::tclTestPerf-TclClock {
+
+namespace path {::tclTestPerf}
+
+## set testing defaults:
+set ::env(TCL_TZ) :CET
+
+# warm-up interpeter compiler env, clock platform-related features:
+
+## warm-up test-related features (load clock.tcl, system zones, locales, etc.):
+clock scan "" -gmt 1
+clock scan ""
+clock scan "" -timezone :CET
+clock scan "" -format "" -locale en
+clock scan "" -format "" -locale de
+
+## ------------------------------------------
+
+proc test-format {{reptime 1000}} {
+ _test_run $reptime {
+ # Format : short, week only (in gmt)
+ {clock format 1482525936 -format "%u" -gmt 1}
+ # Format : short, week only (system zone)
+ {clock format 1482525936 -format "%u"}
+ # Format : short, week only (CEST)
+ {clock format 1482525936 -format "%u" -timezone :CET}
+ # Format : date only (in gmt)
+ {clock format 1482525936 -format "%Y-%m-%d" -gmt 1}
+ # Format : date only (system zone)
+ {clock format 1482525936 -format "%Y-%m-%d"}
+ # Format : date only (CEST)
+ {clock format 1482525936 -format "%Y-%m-%d" -timezone :CET}
+ # Format : time only (in gmt)
+ {clock format 1482525936 -format "%H:%M" -gmt 1}
+ # Format : time only (system zone)
+ {clock format 1482525936 -format "%H:%M"}
+ # Format : time only (CEST)
+ {clock format 1482525936 -format "%H:%M" -timezone :CET}
+ # Format : time only (in gmt)
+ {clock format 1482525936 -format "%H:%M:%S" -gmt 1}
+ # Format : time only (system zone)
+ {clock format 1482525936 -format "%H:%M:%S"}
+ # Format : time only (CEST)
+ {clock format 1482525936 -format "%H:%M:%S" -timezone :CET}
+ # Format : default (in gmt)
+ {clock format 1482525936 -gmt 1 -locale en}
+ # Format : default (system zone)
+ {clock format 1482525936 -locale en}
+ # Format : default (CEST)
+ {clock format 1482525936 -timezone :CET -locale en}
+ # Format : ISO date-time (in gmt, numeric zone)
+ {clock format 1246379400 -format "%Y-%m-%dT%H:%M:%S %z" -gmt 1}
+ # Format : ISO date-time (system zone, CEST, numeric zone)
+ {clock format 1246379400 -format "%Y-%m-%dT%H:%M:%S %z"}
+ # Format : ISO date-time (CEST, numeric zone)
+ {clock format 1246379400 -format "%Y-%m-%dT%H:%M:%S %z" -timezone :CET}
+ # Format : ISO date-time (system zone, CEST)
+ {clock format 1246379400 -format "%Y-%m-%dT%H:%M:%S %Z"}
+ # Format : julian day with time (in gmt):
+ {clock format 1246379415 -format "%J %H:%M:%S" -gmt 1}
+ # Format : julian day with time (system zone):
+ {clock format 1246379415 -format "%J %H:%M:%S"}
+
+ # Format : locale date-time (en):
+ {clock format 1246379415 -format "%x %X" -locale en}
+ # Format : locale date-time (de):
+ {clock format 1246379415 -format "%x %X" -locale de}
+
+ # Format : locale lookup table month:
+ {clock format 1246379400 -format "%b" -locale en -gmt 1}
+ # Format : locale lookup 2 tables - month and day:
+ {clock format 1246379400 -format "%b %Od" -locale en -gmt 1}
+ # Format : locale lookup 3 tables - week, month and day:
+ {clock format 1246379400 -format "%a %b %Od" -locale en -gmt 1}
+ # Format : locale lookup 4 tables - week, month, day and year:
+ {clock format 1246379400 -format "%a %b %Od %Oy" -locale en -gmt 1}
+
+ # Format : dynamic clock value (without converter caches):
+ setup {set i 0}
+ {clock format [incr i] -format "%Y-%m-%dT%H:%M:%S" -locale en -timezone :CET}
+ cleanup {puts [clock format $i -format "%Y-%m-%dT%H:%M:%S" -locale en -timezone :CET]}
+ # Format : dynamic clock value (without any converter caches, zone range overflow):
+ setup {set i 0}
+ {clock format [incr i 86400] -format "%Y-%m-%dT%H:%M:%S" -locale en -timezone :CET}
+ cleanup {puts [clock format $i -format "%Y-%m-%dT%H:%M:%S" -locale en -timezone :CET]}
+
+ # Format : dynamic format (cacheable)
+ {clock format 1246379415 -format [string trim "%d.%m.%Y %H:%M:%S "] -gmt 1}
+
+ # Format : all (in gmt, locale en)
+ {clock format 1482525936 -format "%%a = %a | %%A = %A | %%b = %b | %%h = %h | %%B = %B | %%C = %C | %%d = %d | %%e = %e | %%g = %g | %%G = %G | %%H = %H | %%I = %I | %%j = %j | %%J = %J | %%k = %k | %%l = %l | %%m = %m | %%M = %M | %%N = %N | %%p = %p | %%P = %P | %%Q = %Q | %%s = %s | %%S = %S | %%t = %t | %%u = %u | %%U = %U | %%V = %V | %%w = %w | %%W = %W | %%y = %y | %%Y = %Y | %%z = %z | %%Z = %Z | %%n = %n | %%EE = %EE | %%EC = %EC | %%Ey = %Ey | %%n = %n | %%Od = %Od | %%Oe = %Oe | %%OH = %OH | %%Ok = %Ok | %%OI = %OI | %%Ol = %Ol | %%Om = %Om | %%OM = %OM | %%OS = %OS | %%Ou = %Ou | %%Ow = %Ow | %%Oy = %Oy" -gmt 1 -locale en}
+ # Format : all (in CET, locale de)
+ {clock format 1482525936 -format "%%a = %a | %%A = %A | %%b = %b | %%h = %h | %%B = %B | %%C = %C | %%d = %d | %%e = %e | %%g = %g | %%G = %G | %%H = %H | %%I = %I | %%j = %j | %%J = %J | %%k = %k | %%l = %l | %%m = %m | %%M = %M | %%N = %N | %%p = %p | %%P = %P | %%Q = %Q | %%s = %s | %%S = %S | %%t = %t | %%u = %u | %%U = %U | %%V = %V | %%w = %w | %%W = %W | %%y = %y | %%Y = %Y | %%z = %z | %%Z = %Z | %%n = %n | %%EE = %EE | %%EC = %EC | %%Ey = %Ey | %%n = %n | %%Od = %Od | %%Oe = %Oe | %%OH = %OH | %%Ok = %Ok | %%OI = %OI | %%Ol = %Ol | %%Om = %Om | %%OM = %OM | %%OS = %OS | %%Ou = %Ou | %%Ow = %Ow | %%Oy = %Oy" -timezone :CET -locale de}
+ }
+}
+
+proc test-scan {{reptime 1000}} {
+ _test_run $reptime {
+ # Scan : date (in gmt)
+ {clock scan "25.11.2015" -format "%d.%m.%Y" -base 0 -gmt 1}
+ # Scan : date (system time zone, with base)
+ {clock scan "25.11.2015" -format "%d.%m.%Y" -base 0}
+ # Scan : date (system time zone, without base)
+ {clock scan "25.11.2015" -format "%d.%m.%Y"}
+ # Scan : greedy match
+ {clock scan "111" -format "%d%m%y" -base 0 -gmt 1}
+ {clock scan "1111" -format "%d%m%y" -base 0 -gmt 1}
+ {clock scan "11111" -format "%d%m%y" -base 0 -gmt 1}
+ {clock scan "111111" -format "%d%m%y" -base 0 -gmt 1}
+ # Scan : greedy match (space separated)
+ {clock scan "1 1 1" -format "%d%m%y" -base 0 -gmt 1}
+ {clock scan "111 1" -format "%d%m%y" -base 0 -gmt 1}
+ {clock scan "1 111" -format "%d%m%y" -base 0 -gmt 1}
+ {clock scan "1 11 1" -format "%d%m%y" -base 0 -gmt 1}
+ {clock scan "1 11 11" -format "%d%m%y" -base 0 -gmt 1}
+ {clock scan "11 11 11" -format "%d%m%y" -base 0 -gmt 1}
+
+ # Scan : time (in gmt)
+ {clock scan "10:35:55" -format "%H:%M:%S" -base 1000000000 -gmt 1}
+ # Scan : time (system time zone, with base)
+ {clock scan "10:35:55" -format "%H:%M:%S" -base 1000000000}
+ # Scan : time (gmt, without base)
+ {clock scan "10:35:55" -format "%H:%M:%S" -gmt 1}
+ # Scan : time (system time zone, without base)
+ {clock scan "10:35:55" -format "%H:%M:%S"}
+
+ # Scan : date-time (in gmt)
+ {clock scan "25.11.2015 10:35:55" -format "%d.%m.%Y %H:%M:%S" -base 0 -gmt 1}
+ # Scan : date-time (system time zone with base)
+ {clock scan "25.11.2015 10:35:55" -format "%d.%m.%Y %H:%M:%S" -base 0}
+ # Scan : date-time (system time zone without base)
+ {clock scan "25.11.2015 10:35:55" -format "%d.%m.%Y %H:%M:%S"}
+
+ # Scan : julian day in gmt
+ {clock scan 2451545 -format %J -gmt 1}
+ # Scan : julian day in system TZ
+ {clock scan 2451545 -format %J}
+ # Scan : julian day in other TZ
+ {clock scan 2451545 -format %J -timezone +0200}
+ # Scan : julian day with time:
+ {clock scan "2451545 10:20:30" -format "%J %H:%M:%S"}
+ # Scan : julian day with time (greedy match):
+ {clock scan "2451545 102030" -format "%J%H%M%S"}
+
+ # Scan : century, lookup table month
+ {clock scan {1970 Jan 2} -format {%C%y %b %d} -locale en -gmt 1}
+ # Scan : century, lookup table month and day (both entries are first)
+ {clock scan {1970 Jan 01} -format {%C%y %b %Od} -locale en -gmt 1}
+ # Scan : century, lookup table month and day (list scan: entries with position 12 / 31)
+ {clock scan {2016 Dec 31} -format {%C%y %b %Od} -locale en -gmt 1}
+
+ # Scan : ISO date-time (CEST)
+ {clock scan "2009-06-30T18:30:00+02:00" -format "%Y-%m-%dT%H:%M:%S%z"}
+ {clock scan "2009-06-30T18:30:00 CEST" -format "%Y-%m-%dT%H:%M:%S %z"}
+ # Scan : ISO date-time (UTC)
+ {clock scan "2009-06-30T18:30:00Z" -format "%Y-%m-%dT%H:%M:%S%z"}
+ {clock scan "2009-06-30T18:30:00 UTC" -format "%Y-%m-%dT%H:%M:%S %z"}
+
+ # Scan : locale date-time (en):
+ {clock scan "06/30/2009 18:30:15" -format "%x %X" -gmt 1 -locale en}
+ # Scan : locale date-time (de):
+ {clock scan "30.06.2009 18:30:15" -format "%x %X" -gmt 1 -locale de}
+
+ # Scan : dynamic format (cacheable)
+ {clock scan "25.11.2015 10:35:55" -format [string trim "%d.%m.%Y %H:%M:%S "] -base 0 -gmt 1}
+
+ break
+ # # Scan : long format test (allock chain)
+ # {clock scan "25.11.2015" -format "%d.%m.%Y %d.%m.%Y %d.%m.%Y %d.%m.%Y %d.%m.%Y %d.%m.%Y %d.%m.%Y %d.%m.%Y" -base 0 -gmt 1}
+ # # Scan : dynamic, very long format test (create obj representation, allock chain, GC, etc):
+ # {clock scan "25.11.2015" -format [string repeat "[incr i] %d.%m.%Y %d.%m.%Y" 10] -base 0 -gmt 1}
+ # # Scan : again:
+ # {clock scan "25.11.2015" -format [string repeat "[incr i -1] %d.%m.%Y %d.%m.%Y" 10] -base 0 -gmt 1}
+ } {puts [clock format $_(r) -locale en]}
+}
+
+proc test-freescan {{reptime 1000}} {
+ _test_run $reptime {
+ # FreeScan : relative date
+ {clock scan "5 years 18 months 385 days" -base 0 -gmt 1}
+ # FreeScan : relative date with relative weekday
+ {clock scan "5 years 18 months 385 days Fri" -base 0 -gmt 1}
+ # FreeScan : relative date with ordinal month
+ {clock scan "5 years 18 months 385 days next 1 January" -base 0 -gmt 1}
+ # FreeScan : relative date with ordinal month and relative weekday
+ {clock scan "5 years 18 months 385 days next January Fri" -base 0 -gmt 1}
+ # FreeScan : ordinal month
+ {clock scan "next January" -base 0 -gmt 1}
+ # FreeScan : relative week
+ {clock scan "next Fri" -base 0 -gmt 1}
+ # FreeScan : relative weekday and week offset
+ {clock scan "next January + 2 week" -base 0 -gmt 1}
+ # FreeScan : time only with base
+ {clock scan "19:18:30" -base 148863600 -gmt 1}
+ # FreeScan : time only without base, gmt
+ {clock scan "19:18:30" -gmt 1}
+ # FreeScan : time only without base, system
+ {clock scan "19:18:30"}
+ # FreeScan : date, system time zone
+ {clock scan "05/08/2016 20:18:30"}
+ # FreeScan : date, supplied time zone
+ {clock scan "05/08/2016 20:18:30" -timezone :CET}
+ # FreeScan : date, supplied gmt (equivalent -timezone :GMT)
+ {clock scan "05/08/2016 20:18:30" -gmt 1}
+ # FreeScan : date, supplied time zone gmt
+ {clock scan "05/08/2016 20:18:30" -timezone :GMT}
+ # FreeScan : time only, numeric zone in string, base time gmt (exchange zones between gmt / -0500)
+ {clock scan "20:18:30 -0500" -base 148863600 -gmt 1}
+ # FreeScan : time only, zone in string (exchange zones between system / gmt)
+ {clock scan "19:18:30 GMT" -base 148863600}
+ # FreeScan : fast switch of zones in cycle - GMT, MST, CET (system) and EST
+ {clock scan "19:18:30 MST" -base 148863600 -gmt 1
+ clock scan "19:18:30 EST" -base 148863600
+ }
+ } {puts [clock format $_(r) -locale en]}
+}
+
+proc test-add {{reptime 1000}} {
+ set tests {
+ # Add : years
+ {clock add 1246379415 5 years -gmt 1}
+ # Add : months
+ {clock add 1246379415 18 months -gmt 1}
+ # Add : weeks
+ {clock add 1246379415 20 weeks -gmt 1}
+ # Add : days
+ {clock add 1246379415 385 days -gmt 1}
+ # Add : weekdays
+ {clock add 1246379415 3 weekdays -gmt 1}
+
+ # Add : hours
+ {clock add 1246379415 5 hours -gmt 1}
+ # Add : minutes
+ {clock add 1246379415 55 minutes -gmt 1}
+ # Add : seconds
+ {clock add 1246379415 100 seconds -gmt 1}
+
+ # Add : +/- in gmt
+ {clock add 1246379415 -5 years +21 months -20 weeks +386 days -19 hours +30 minutes -10 seconds -gmt 1}
+ # Add : +/- in system timezone
+ {clock add 1246379415 -5 years +21 months -20 weeks +386 days -19 hours +30 minutes -10 seconds -timezone :CET}
+
+ # Add : gmt
+ {clock add 1246379415 -5 years 18 months 366 days 5 hours 30 minutes 10 seconds -gmt 1}
+ # Add : system timezone
+ {clock add 1246379415 -5 years 18 months 366 days 5 hours 30 minutes 10 seconds -timezone :CET}
+
+ # Add : all in gmt
+ {clock add 1246379415 4 years 18 months 50 weeks 378 days 3 weekdays 5 hours 30 minutes 10 seconds -gmt 1}
+ # Add : all in system timezone
+ {clock add 1246379415 4 years 18 months 50 weeks 378 days 3 weekdays 5 hours 30 minutes 10 seconds -timezone :CET}
+
+ }
+ # if does not support add of weekdays:
+ if {[catch {clock add 0 3 weekdays -gmt 1}]} {
+ regsub -all {\mweekdays\M} $tests "days" tests
+ }
+ _test_run $reptime $tests {puts [clock format $_(r) -locale en]}
+}
+
+proc test-convert {{reptime 1000}} {
+ _test_run $reptime {
+ # Convert locale (en -> de):
+ {clock format [clock scan "Tue May 30 2017" -format "%a %b %d %Y" -gmt 1 -locale en] -format "%a %b %d %Y" -gmt 1 -locale de}
+ # Convert locale (de -> en):
+ {clock format [clock scan "Di Mai 30 2017" -format "%a %b %d %Y" -gmt 1 -locale de] -format "%a %b %d %Y" -gmt 1 -locale en}
+
+ # Convert TZ: direct
+ {clock format [clock scan "19:18:30" -base 148863600 -timezone EST] -timezone MST}
+ {clock format [clock scan "19:18:30" -base 148863600 -timezone MST] -timezone EST}
+ # Convert TZ: included in scan string & format
+ {clock format [clock scan "19:18:30 EST" -base 148863600] -format "%H:%M:%S %z" -timezone MST}
+ {clock format [clock scan "19:18:30 EST" -base 148863600] -format "%H:%M:%S %z" -timezone EST}
+
+ # Format locale 1x: comparison values
+ {clock format 0 -gmt 1 -locale en}
+ {clock format 0 -gmt 1 -locale de}
+ {clock format 0 -gmt 1 -locale fr}
+ # Format locale 2x: without switching locale (en, en)
+ {clock format 0 -gmt 1 -locale en; clock format 0 -gmt 1 -locale en}
+ # Format locale 2x: with switching locale (en, de)
+ {clock format 0 -gmt 1 -locale en; clock format 0 -gmt 1 -locale de}
+ # Format locale 3x: without switching locale (en, en, en)
+ {clock format 0 -gmt 1 -locale en; clock format 0 -gmt 1 -locale en; clock format 0 -gmt 1 -locale en}
+ # Format locale 3x: with switching locale (en, de, fr)
+ {clock format 0 -gmt 1 -locale en; clock format 0 -gmt 1 -locale de; clock format 0 -gmt 1 -locale fr}
+
+ # Scan locale 2x: without switching locale (en, en) + (de, de)
+ {clock scan "Tue May 30 2017" -format "%a %b %d %Y" -gmt 1 -locale en; clock scan "Tue May 30 2017" -format "%a %b %d %Y" -gmt 1 -locale en}
+ {clock scan "Di Mai 30 2017" -format "%a %b %d %Y" -gmt 1 -locale de; clock scan "Di Mai 30 2017" -format "%a %b %d %Y" -gmt 1 -locale de}
+ # Scan locale 2x: with switching locale (en, de)
+ {clock scan "Tue May 30 2017" -format "%a %b %d %Y" -gmt 1 -locale en; clock scan "Di Mai 30 2017" -format "%a %b %d %Y" -gmt 1 -locale de}
+ # Scan locale 3x: with switching locale (en, de, fr)
+ {clock scan "Tue May 30 2017" -format "%a %b %d %Y" -gmt 1 -locale en; clock scan "Di Mai 30 2017" -format "%a %b %d %Y" -gmt 1 -locale de; clock scan "mar. mai 30 2017" -format "%a %b %d %Y" -gmt 1 -locale fr}
+
+ # Format TZ 2x: comparison values
+ {clock format 0 -timezone CET -format "%Y-%m-%d %H:%M:%S %z"}
+ {clock format 0 -timezone EST -format "%Y-%m-%d %H:%M:%S %z"}
+ # Format TZ 2x: without switching
+ {clock format 0 -timezone CET -format "%Y-%m-%d %H:%M:%S %z"; clock format 0 -timezone CET -format "%Y-%m-%d %H:%M:%S %z"}
+ {clock format 0 -timezone EST -format "%Y-%m-%d %H:%M:%S %z"; clock format 0 -timezone EST -format "%Y-%m-%d %H:%M:%S %z"}
+ # Format TZ 2x: with switching
+ {clock format 0 -timezone CET -format "%Y-%m-%d %H:%M:%S %z"; clock format 0 -timezone EST -format "%Y-%m-%d %H:%M:%S %z"}
+ # Format TZ 3x: with switching (CET, EST, MST)
+ {clock format 0 -timezone CET -format "%Y-%m-%d %H:%M:%S %z"; clock format 0 -timezone EST -format "%Y-%m-%d %H:%M:%S %z"; clock format 0 -timezone MST -format "%Y-%m-%d %H:%M:%S %z"}
+ # Format TZ 3x: with switching (GMT, EST, MST)
+ {clock format 0 -gmt 1 -format "%Y-%m-%d %H:%M:%S %z"; clock format 0 -timezone EST -format "%Y-%m-%d %H:%M:%S %z"; clock format 0 -timezone MST -format "%Y-%m-%d %H:%M:%S %z"}
+
+ # FreeScan TZ 2x (+1 system-default): without switching TZ
+ {clock scan "19:18:30 MST" -base 148863600; clock scan "19:18:30 MST" -base 148863600}
+ {clock scan "19:18:30 EST" -base 148863600; clock scan "19:18:30 EST" -base 148863600}
+ # FreeScan TZ 2x (+1 system-default): with switching TZ
+ {clock scan "19:18:30 MST" -base 148863600; clock scan "19:18:30 EST" -base 148863600}
+ # FreeScan TZ 2x (+1 gmt, +1 system-default)
+ {clock scan "19:18:30 MST" -base 148863600 -gmt 1; clock scan "19:18:30 EST" -base 148863600}
+
+ # Scan TZ: comparison included in scan string vs. given
+ {clock scan "2009-06-30T18:30:00 CEST" -format "%Y-%m-%dT%H:%M:%S %z"}
+ {clock scan "2009-06-30T18:30:00 CET" -format "%Y-%m-%dT%H:%M:%S %z"}
+ {clock scan "2009-06-30T18:30:00" -timezone CET -format "%Y-%m-%dT%H:%M:%S"}
+ }
+}
+
+proc test-other {{reptime 1000}} {
+ _test_run $reptime {
+ # Bad zone
+ {catch {clock scan "1 day" -timezone BAD_ZONE -locale en}}
+
+ # Scan : julian day (overflow)
+ {catch {clock scan 5373485 -format %J}}
+
+ # Scan : test rotate of GC objects (format is dynamic, so tcl-obj removed with last reference)
+ {set i 0; time { clock scan "[incr i] - 25.11.2015" -format "$i - %d.%m.%Y" -base 0 -gmt 1 } 50}
+ # Scan : test reusability of GC objects (format is dynamic, so tcl-obj removed with last reference)
+ {set i 50; time { clock scan "[incr i -1] - 25.11.2015" -format "$i - %d.%m.%Y" -base 0 -gmt 1 } 50}
+ }
+}
+
+proc test-ensemble-perf {{reptime 1000}} {
+ _test_run $reptime {
+ # Clock clicks (ensemble)
+ {clock clicks}
+ # Clock clicks (direct)
+ {::tcl::clock::clicks}
+ # Clock seconds (ensemble)
+ {clock seconds}
+ # Clock seconds (direct)
+ {::tcl::clock::seconds}
+ # Clock microseconds (ensemble)
+ {clock microseconds}
+ # Clock microseconds (direct)
+ {::tcl::clock::microseconds}
+ # Clock scan (ensemble)
+ {clock scan ""}
+ # Clock scan (direct)
+ {::tcl::clock::scan ""}
+ # Clock format (ensemble)
+ {clock format 0 -f %s}
+ # Clock format (direct)
+ {::tcl::clock::format 0 -f %s}
+ }
+}
+
+proc test {{reptime 1000}} {
+ puts ""
+ test-ensemble-perf [expr {$reptime / 2}]; #fast enough
+ test-format $reptime
+ test-scan $reptime
+ test-freescan $reptime
+ test-add $reptime
+ test-convert [expr {$reptime / 2}]; #fast enough
+ test-other $reptime
+
+ puts \n**OK**
+}
+
+}; # end of ::tclTestPerf-TclClock
+
+# ------------------------------------------------------------------------
+
+# if calling direct:
+if {[info exists ::argv0] && [file tail $::argv0] eq [file tail [info script]]} {
+ ::tclTestPerf-TclClock::test $in(-time)
+}
diff --git a/tests-perf/test-performance.tcl b/tests-perf/test-performance.tcl
new file mode 100644
index 0000000..1ddecb5
--- /dev/null
+++ b/tests-perf/test-performance.tcl
@@ -0,0 +1,144 @@
+# ------------------------------------------------------------------------
+#
+# test-performance.tcl --
+#
+# This file provides common performance tests for comparison of tcl-speed
+# degradation or regression by switching between branches.
+#
+# To execute test case evaluate direct corresponding file "tests-perf\*.perf.tcl".
+#
+# ------------------------------------------------------------------------
+#
+# Copyright (c) 2014 Serg G. Brester (aka sebres)
+#
+# See the file "license.terms" for information on usage and redistribution
+# of this file.
+#
+
+namespace eval ::tclTestPerf {
+# warm-up interpeter compiler env, calibrate timerate measurement functionality:
+
+# if no timerate here - import from unsupported:
+if {[namespace which -command timerate] eq {}} {
+ namespace inscope ::tcl::unsupported {namespace export timerate}
+ namespace import ::tcl::unsupported::timerate
+}
+
+# if not yet calibrated:
+if {[lindex [timerate {} 10] 6] >= (10-1)} {
+ puts -nonewline "Calibration ... "; flush stdout
+ puts "done: [lrange \
+ [timerate -calibrate {}] \
+ 0 1]"
+}
+
+proc {**STOP**} {args} {
+ return -code error -level 4 "**STOP** in [info level [expr {[info level]-2}]] [join $args { }]"
+}
+
+proc _test_get_commands {lst} {
+ regsub -all {(?:^|\n)[ \t]*(\#[^\n]*|\msetup\M[^\n]*|\mcleanup\M[^\n]*)(?=\n\s*(?:[\{\#]|setup|cleanup|$))} $lst "\n{\\1}"
+}
+
+proc _test_out_total {} {
+ upvar _ _
+
+ set tcnt [llength $_(itm)]
+ if {!$tcnt} {
+ puts ""
+ return
+ }
+
+ set mintm 0x7fffffff
+ set maxtm 0
+ set nett 0
+ set wtm 0
+ set wcnt 0
+ set i 0
+ foreach tm $_(itm) {
+ if {[llength $tm] > 6} {
+ set nett [expr {$nett + [lindex $tm 6]}]
+ }
+ set wtm [expr {$wtm + [lindex $tm 0]}]
+ set wcnt [expr {$wcnt + [lindex $tm 2]}]
+ set tm [lindex $tm 0]
+ if {$tm > $maxtm} {set maxtm $tm; set maxi $i}
+ if {$tm < $mintm} {set mintm $tm; set mini $i}
+ incr i
+ }
+
+ puts [string repeat ** 40]
+ set s [format "%d cases in %.2f sec." $tcnt [expr {([clock milliseconds] - $_(starttime)) / 1000.0}]]
+ if {$nett > 0} {
+ append s [format " (%.2f nett-sec.)" [expr {$nett / 1000.0}]]
+ }
+ puts "Total $s:"
+ lset _(m) 0 [format %.6f $wtm]
+ lset _(m) 2 $wcnt
+ lset _(m) 4 [format %.3f [expr {$wcnt / (($nett ? $nett : ($tcnt * [lindex $_(reptime) 0])) / 1000.0)}]]
+ if {[llength $_(m)] > 6} {
+ lset _(m) 6 [format %.3f $nett]
+ }
+ puts $_(m)
+ puts "Average:"
+ lset _(m) 0 [format %.6f [expr {[lindex $_(m) 0] / $tcnt}]]
+ lset _(m) 2 [expr {[lindex $_(m) 2] / $tcnt}]
+ if {[llength $_(m)] > 6} {
+ lset _(m) 6 [format %.3f [expr {[lindex $_(m) 6] / $tcnt}]]
+ lset _(m) 4 [format %.0f [expr {[lindex $_(m) 2] / [lindex $_(m) 6] * 1000}]]
+ }
+ puts $_(m)
+ puts "Min:"
+ puts [lindex $_(itm) $mini]
+ puts "Max:"
+ puts [lindex $_(itm) $maxi]
+ puts [string repeat ** 40]
+ puts ""
+}
+
+proc _test_run {args} {
+ upvar _ _
+ # parse args:
+ set _(out-result) 1
+ if {[lindex $args 0] eq "-no-result"} {
+ set _(out-result) 0
+ set args [lrange $args 1 end]
+ }
+ if {[llength $args] < 2 || [llength $args] > 3} {
+ return -code error "wrong # args: should be \"[lindex [info level [info level]] 0] ?-no-result? reptime lst ?outcmd?\""
+ }
+ set outcmd {puts $_(r)}
+ set args [lassign $args reptime lst]
+ if {[llength $args]} {
+ set outcmd [lindex $args 0]
+ }
+ # avoid output if only once:
+ if {[lindex $reptime 0] <= 1 || ([llength $reptime] > 1 && [lindex $reptime 1] == 1)} {
+ set _(out-result) 0
+ }
+ array set _ [list itm {} reptime $reptime starttime [clock milliseconds]]
+
+ # process measurement:
+ foreach _(c) [_test_get_commands $lst] {
+ puts "% [regsub -all {\n[ \t]*} $_(c) {; }]"
+ if {[regexp {^\s*\#} $_(c)]} continue
+ if {[regexp {^\s*(?:setup|cleanup)\s+} $_(c)]} {
+ puts [if 1 [lindex $_(c) 1]]
+ continue
+ }
+ # if output result (and not once):
+ if {$_(out-result)} {
+ set _(r) [if 1 $_(c)]
+ if {$outcmd ne {}} $outcmd
+ if {[llength $_(reptime)] > 1} { # decrement max-count
+ lset _(reptime) 1 [expr {[lindex $_(reptime) 1] - 1}]
+ }
+ }
+ puts [set _(m) [timerate $_(c) {*}$_(reptime)]]
+ lappend _(itm) $_(m)
+ puts ""
+ }
+ _test_out_total
+}
+
+}; # end of namespace ::tclTestPerf
diff --git a/tests-perf/timer-event.perf.tcl b/tests-perf/timer-event.perf.tcl
new file mode 100644
index 0000000..f68a56a
--- /dev/null
+++ b/tests-perf/timer-event.perf.tcl
@@ -0,0 +1,182 @@
+#!/usr/bin/tclsh
+
+# ------------------------------------------------------------------------
+#
+# timer-event.perf.tcl --
+#
+# This file provides performance tests for comparison of tcl-speed
+# of timer events (event-driven tcl-handling).
+#
+# ------------------------------------------------------------------------
+#
+# Copyright (c) 2014 Serg G. Brester (aka sebres)
+#
+# See the file "license.terms" for information on usage and redistribution
+# of this file.
+#
+
+
+if {![namespace exists ::tclTestPerf]} {
+ source [file join [file dirname [info script]] test-performance.tcl]
+}
+
+
+namespace eval ::tclTestPerf-Timer-Event {
+
+namespace path {::tclTestPerf}
+
+proc test-queue {{reptime {1000 10000}}} {
+
+ set howmuch [lindex $reptime 1]
+
+ # because of extremely short measurement times by tests below, wait a little bit (warming-up),
+ # to minimize influence of the time-gradation (just for better dispersion resp. result-comparison)
+ timerate {after 0} 156
+
+ puts "*** up to $howmuch events ***"
+ # single iteration by update, so using -no-result (measure only):
+ _test_run -no-result $reptime [string map [list \{*\}\$reptime $reptime \$howmuch $howmuch \\# \#] {
+ # generate up to $howmuch idle-events:
+ {after idle {set foo bar}}
+ # update / after idle:
+ {update; if {![llength [after info]]} break}
+
+ # generate up to $howmuch idle-events:
+ {after idle {set foo bar}}
+ # update idletasks / after idle:
+ {update idletasks; if {![llength [after info]]} break}
+
+ # generate up to $howmuch immediate events:
+ {after 0 {set foo bar}}
+ # update / after 0:
+ {update; if {![llength [after info]]} break}
+
+ # generate up to $howmuch 1-ms events:
+ {after 1 {set foo bar}}
+ setup {after 1}
+ # update / after 1:
+ {update; if {![llength [after info]]} break}
+
+ # generate up to $howmuch immediate events (+ 1 event of the second generation):
+ {after 0 {after 0 {}}}
+ # update / after 0 (double generation):
+ {update; if {![llength [after info]]} break}
+
+ # cancel forwards "after idle" / $howmuch idle-events in queue:
+ setup {set i 0; timerate {set ev([incr i]) [after idle {set foo bar}]} {*}$reptime}
+ setup {set le $i; set i 0; list 1 .. $le; # cancel up to $howmuch events}
+ {after cancel $ev([incr i]); if {$i >= $le} break}
+ cleanup {update; unset -nocomplain ev}
+ # cancel backwards "after idle" / $howmuch idle-events in queue:
+ setup {set i 0; timerate {set ev([incr i]) [after idle {set foo bar}]} {*}$reptime}
+ setup {set le $i; incr i; list $le .. 1; # cancel up to $howmuch events}
+ {after cancel $ev([incr i -1]); if {$i <= 1} break}
+ cleanup {update; unset -nocomplain ev}
+
+ # cancel forwards "after 0" / $howmuch timer-events in queue:
+ setup {set i 0; timerate {set ev([incr i]) [after 0 {set foo bar}]} {*}$reptime}
+ setup {set le $i; set i 0; list 1 .. $le; # cancel up to $howmuch events}
+ {after cancel $ev([incr i]); if {$i >= $le} break}
+ cleanup {update; unset -nocomplain ev}
+ # cancel backwards "after 0" / $howmuch timer-events in queue:
+ setup {set i 0; timerate {set ev([incr i]) [after 0 {set foo bar}]} {*}$reptime}
+ setup {set le $i; incr i; list $le .. 1; # cancel up to $howmuch events}
+ {after cancel $ev([incr i -1]); if {$i <= 1} break}
+ cleanup {update; unset -nocomplain ev}
+
+ # end $howmuch events.
+ cleanup {if [llength [after info]] {error "unexpected: [llength [after info]] events are still there."}}
+ }]
+}
+
+proc test-access {{reptime {1000 5000}}} {
+ set howmuch [lindex $reptime 1]
+
+ _test_run $reptime [string map [list \{*\}\$reptime $reptime \$howmuch $howmuch] {
+ # event random access: after idle + after info (by $howmuch events)
+ setup {set i -1; timerate {set ev([incr i]) [after idle {}]} {*}$reptime}
+ {after info $ev([expr {int(rand()*$i)}])}
+ cleanup {update; unset -nocomplain ev}
+ # event random access: after 0 + after info (by $howmuch events)
+ setup {set i -1; timerate {set ev([incr i]) [after 0 {}]} {*}$reptime}
+ {after info $ev([expr {int(rand()*$i)}])}
+ cleanup {update; unset -nocomplain ev}
+
+ # end $howmuch events.
+ cleanup {if [llength [after info]] {error "unexpected: [llength [after info]] events are still there."}}
+ }]
+}
+
+proc test-exec {{reptime 1000}} {
+ _test_run $reptime {
+ # after idle + after cancel
+ {after cancel [after idle {set foo bar}]}
+ # after 0 + after cancel
+ {after cancel [after 0 {set foo bar}]}
+ # after idle + update idletasks
+ {after idle {set foo bar}; update idletasks}
+ # after idle + update
+ {after idle {set foo bar}; update}
+ # immediate: after 0 + update
+ {after 0 {set foo bar}; update}
+ # delayed: after 1 + update
+ {after 1 {set foo bar}; update}
+ # empty update:
+ {update}
+ # empty update idle tasks:
+ {update idletasks}
+
+ # simple shortest sleep:
+ {after 0}
+ }
+}
+
+proc test-nrt-capability {{reptime 1000}} {
+ _test_run $reptime {
+ # comparison values:
+ {after 0 {set a 5}; update}
+ {after 0 {set a 5}; vwait a}
+
+ # conditional vwait with very brief wait-time:
+ {after 1 {set a timeout}; vwait a; expr {$::a ne "timeout" ? 1 : "0[unset ::a]"}}
+ {after 0 {set a timeout}; vwait a; expr {$::a ne "timeout" ? 1 : "0[unset ::a]"}}
+ }
+}
+
+proc test-long {{reptime 1000}} {
+ _test_run $reptime {
+ # in-between important event by amount of idle events:
+ {time {after idle {after 30}} 10; after 1 {set important 1}; vwait important;}
+ cleanup {foreach i [after info] {after cancel $i}}
+ # in-between important event (of new generation) by amount of idle events:
+ {time {after idle {after 30}} 10; after 1 {after 0 {set important 1}}; vwait important;}
+ cleanup {foreach i [after info] {after cancel $i}}
+ }
+}
+
+proc test {{reptime 1000}} {
+ test-exec $reptime
+ foreach howmuch {5000 50000} {
+ test-access [list $reptime $howmuch]
+ }
+ test-nrt-capability $reptime
+ test-long $reptime
+
+ puts ""
+ foreach howmuch { 10000 20000 40000 60000 } {
+ test-queue [list $reptime $howmuch]
+ }
+
+ puts \n**OK**
+}
+
+}; # end of ::tclTestPerf-Timer-Event
+
+# ------------------------------------------------------------------------
+
+# if calling direct:
+if {[info exists ::argv0] && [file tail $::argv0] eq [file tail [info script]]} {
+ array set in {-time 500}
+ array set in $argv
+ ::tclTestPerf-Timer-Event::test $in(-time)
+}
diff --git a/tests/cmdMZ.test b/tests/cmdMZ.test
index a5f3009..80258dc 100644
--- a/tests/cmdMZ.test
+++ b/tests/cmdMZ.test
@@ -342,6 +342,90 @@ test cmdMZ-5.7 {Tcl_TimeObjCmd: errors generate right trace} {
invoked from within
"time {error foo}"}}
+test cmdMZ-6.1 {Tcl_TimeRateObjCmd: basic format of command} {
+ list [catch {timerate} msg] $msg
+} {1 {wrong # args: should be "timerate ?-direct? ?-calibrate? ?-overhead double? command ?time ?max-count??"}}
+test cmdMZ-6.2.1 {Tcl_TimeRateObjCmd: basic format of command} {
+ list [catch {timerate a b c d} msg] $msg
+} {1 {wrong # args: should be "timerate ?-direct? ?-calibrate? ?-overhead double? command ?time ?max-count??"}}
+test cmdMZ-6.2.2 {Tcl_TimeRateObjCmd: basic format of command} {
+ list [catch {timerate a b c} msg] $msg
+} {1 {expected integer but got "b"}}
+test cmdMZ-6.2.3 {Tcl_TimeRateObjCmd: basic format of command} {
+ list [catch {timerate a b} msg] $msg
+} {1 {expected integer but got "b"}}
+test cmdMZ-6.3 {Tcl_TimeRateObjCmd: basic format of command} {
+ list [catch {timerate -overhead b {} a b} msg] $msg
+} {1 {expected floating-point number but got "b"}}
+test cmdMZ-6.4 {Tcl_TimeRateObjCmd: compile of script happens even with negative iteration counts} {
+ list [catch {timerate "foreach a {c d e} \{" -12456} msg] $msg
+} {1 {missing close-brace}}
+test cmdMZ-6.5a {Tcl_TimeRateObjCmd: result format and one iteration} {
+ regexp {^\d+(?:\.\d+)? \ws/# 1 # \d+(?:\.\d+)? #/sec \d+(?:\.\d+)? nett-ms$} [timerate {} 0]
+} 1
+test cmdMZ-6.5b {Tcl_TimeRateObjCmd: result format without iterations} {
+ regexp {^0 \ws/# 0 # 0 #/sec 0 nett-ms$} [timerate {} 0 0]
+} 1
+test cmdMZ-6.6 {Tcl_TimeRateObjCmd: slower commands take longer, but it remains almost the same time of measument} {
+ set m1 [timerate {after 0} 20]
+ set m2 [timerate {after 1} 20]
+ list \
+ [expr {[lindex $m1 0] < [lindex $m2 0]}] \
+ [expr {[lindex $m1 0] < 100}] \
+ [expr {[lindex $m2 0] >= 500}] \
+ [expr {[lindex $m1 2] > 1000}] \
+ [expr {[lindex $m2 2] <= 50}] \
+ [expr {[lindex $m1 4] > 10000}] \
+ [expr {[lindex $m2 4] < 10000}] \
+ [expr {[lindex $m1 6] > 10 && [lindex $m1 6] < 50}] \
+ [expr {[lindex $m2 6] > 10 && [lindex $m2 6] < 50}]
+} [lrepeat 9 1]
+test cmdMZ-6.7 {Tcl_TimeRateObjCmd: errors generate right trace} {
+ list [catch {timerate {error foo} 1} msg] $msg $::errorInfo
+} {1 foo {foo
+ while executing
+"error foo"
+ invoked from within
+"timerate {error foo} 1"}}
+test cmdMZ-6.8 {Tcl_TimeRateObjCmd: allow (conditional) break from timerate} {
+ set m1 [timerate {break}]
+ list \
+ [expr {[lindex $m1 0] < 1000}] \
+ [expr {[lindex $m1 2] == 1}] \
+ [expr {[lindex $m1 4] > 1000}] \
+ [expr {[lindex $m1 6] < 10}]
+} {1 1 1 1}
+test cmdMZ-6.9 {Tcl_TimeRateObjCmd: max count of iterations} {
+ set m1 [timerate {} 1000 5]; # max-count wins
+ set m2 [timerate {after 20} 1 5]; # max-time wins
+ list [lindex $m1 2] [lindex $m2 2]
+} {5 1}
+test cmdMZ-6.10 {Tcl_TimeRateObjCmd: huge overhead cause 0us result} {
+ set m1 [timerate -overhead 1e6 {after 10} 100 1]
+ list \
+ [expr {[lindex $m1 0] == 0.0}] \
+ [expr {[lindex $m1 2] == 1}] \
+ [expr {[lindex $m1 4] == 1000000}] \
+ [expr {[lindex $m1 6] <= 0.001}]
+} {1 1 1 1}
+
+test cmdMZ-try-1.0 {
+
+ fix for issue 45b9faf103f2
+
+ [try] interaction with local variable names produces segmentation violation
+
+} -body {
+ ::apply {{} {
+ set cmd try
+ $cmd {
+ lindex 5
+ } on ok res {}
+ set res
+ }}
+} -result 5
+
+
# The tests for Tcl_WhileObjCmd are in while.test
# cleanup
diff --git a/tests/encoding.test b/tests/encoding.test
index ab60617..4736928 100644
--- a/tests/encoding.test
+++ b/tests/encoding.test
@@ -36,7 +36,6 @@ proc runtests {} {
testConstraint testencoding [llength [info commands testencoding]]
testConstraint testbytestring [llength [info commands testbytestring]]
testConstraint teststringbytes [llength [info commands teststringbytes]]
-testConstraint tip389 [expr {[string length \U010000] == 2}]
testConstraint exec [llength [info commands exec]]
testConstraint testgetencpath [llength [info commands testgetencpath]]
@@ -323,16 +322,16 @@ test encoding-15.3 {UtfToUtfProc null character input} teststringbytes {
set z
} c080
-test encoding-16.1 {UnicodeToUtfProc} -constraints tip389 -body {
+test encoding-16.1 {UnicodeToUtfProc} -body {
set val [encoding convertfrom unicode NN]
list $val [format %x [scan $val %c]]
} -result "\u4e4e 4e4e"
-test encoding-16.2 {UnicodeToUtfProc} -constraints tip389 -body {
+test encoding-16.2 {UnicodeToUtfProc} -body {
set val [encoding convertfrom unicode "\xd8\xd8\xdc\xdc"]
list $val [format %x [scan $val %c]]
} -result "\U460dc 460dc"
-test encoding-17.1 {UtfToUnicodeProc} -constraints tip389 -body {
+test encoding-17.1 {UtfToUnicodeProc} -body {
encoding convertto unicode "\U460dc"
} -result "\xd8\xd8\xdc\xdc"
diff --git a/tests/expr.test b/tests/expr.test
index 7136afc..cb0c24d 100644
--- a/tests/expr.test
+++ b/tests/expr.test
@@ -1107,7 +1107,7 @@ test expr-23.54.11 {INST_EXPON: Bug 2798543} {
expr {3**9 == 3**131081}
} 0
test expr-23.54.12 {INST_EXPON: Bug 2798543} -body {
- expr {3**9 == 3**268435465}
+ expr {3**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.54.13 {INST_EXPON: Bug 2798543} {
expr {(-3)**9 == (-3)**65545}
@@ -1122,7 +1122,7 @@ test expr-23.55.2 {INST_EXPON: Bug 2798543} {
expr {4**9 == 4**131081}
} 0
test expr-23.55.3 {INST_EXPON: Bug 2798543} -body {
- expr {4**9 == 4**268435465}
+ expr {4**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.55.4 {INST_EXPON: Bug 2798543} {
expr {(-4)**9 == (-4)**65545}
@@ -1137,7 +1137,7 @@ test expr-23.56.2 {INST_EXPON: Bug 2798543} {
expr {5**9 == 5**131081}
} 0
test expr-23.56.3 {INST_EXPON: Bug 2798543} -body {
- expr {5**9 == 5**268435465}
+ expr {5**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.56.4 {INST_EXPON: Bug 2798543} {
expr {(-5)**9 == (-5)**65545}
@@ -1152,7 +1152,7 @@ test expr-23.57.2 {INST_EXPON: Bug 2798543} {
expr {6**9 == 6**131081}
} 0
test expr-23.57.3 {INST_EXPON: Bug 2798543} -body {
- expr {6**9 == 6**268435465}
+ expr {6**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.57.4 {INST_EXPON: Bug 2798543} {
expr {(-6)**9 == (-6)**65545}
@@ -1167,7 +1167,7 @@ test expr-23.58.2 {INST_EXPON: Bug 2798543} {
expr {7**9 == 7**131081}
} 0
test expr-23.58.3 {INST_EXPON: Bug 2798543} -body {
- expr {7**9 == 7**268435465}
+ expr {7**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.58.4 {INST_EXPON: Bug 2798543} {
expr {(-7)**9 == (-7)**65545}
@@ -1182,7 +1182,7 @@ test expr-23.59.2 {INST_EXPON: Bug 2798543} {
expr {8**9 == 8**131081}
} 0
test expr-23.59.3 {INST_EXPON: Bug 2798543} -body {
- expr {8**9 == 8**268435465}
+ expr {8**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.59.4 {INST_EXPON: Bug 2798543} {
expr {(-8)**9 == (-8)**65545}
@@ -1194,7 +1194,7 @@ test expr-23.60.1 {INST_EXPON: Bug 2798543} {
expr {9**9 == 9**131081}
} 0
test expr-23.60.2 {INST_EXPON: Bug 2798543} -body {
- expr {9**9 == 9**268435465}
+ expr {9**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.60.3 {INST_EXPON: Bug 2798543} {
expr {(-9)**9 == (-9)**65545}
@@ -1206,7 +1206,7 @@ test expr-23.61.1 {INST_EXPON: Bug 2798543} {
expr {10**9 == 10**131081}
} 0
test expr-23.61.2 {INST_EXPON: Bug 2798543} -body {
- expr {10**9 == 10**268435465}
+ expr {10**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.61.3 {INST_EXPON: Bug 2798543} {
expr {(-10)**9 == (-10)**65545}
@@ -1218,7 +1218,7 @@ test expr-23.62.1 {INST_EXPON: Bug 2798543} {
expr {11**9 == 11**131081}
} 0
test expr-23.62.2 {INST_EXPON: Bug 2798543} -body {
- expr {11**9 == 11**268435465}
+ expr {11**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.62.3 {INST_EXPON: Bug 2798543} {
expr {(-11)**9 == (-11)**65545}
@@ -1233,7 +1233,7 @@ test expr-23.63.2 {INST_EXPON: Bug 2798543} {
expr {3**20 == 3**131092}
} 0
test expr-23.63.3 {INST_EXPON: Bug 2798543} -body {
- expr {3**20 == 3**268435476}
+ expr {3**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.63.4 {INST_EXPON: Bug 2798543} {
expr {(-3)**20 == (-3)**65556}
@@ -1248,7 +1248,7 @@ test expr-23.64.2 {INST_EXPON: Bug 2798543} {
expr {4**17 == 4**131089}
} 0
test expr-23.64.3 {INST_EXPON: Bug 2798543} -body {
- expr {4**17 == 4**268435473}
+ expr {4**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.64.4 {INST_EXPON: Bug 2798543} {
expr {(-4)**17 == (-4)**65553}
@@ -1263,7 +1263,7 @@ test expr-23.65.2 {INST_EXPON: Bug 2798543} {
expr {5**17 == 5**131089}
} 0
test expr-23.65.3 {INST_EXPON: Bug 2798543} -body {
- expr {5**17 == 5**268435473}
+ expr {5**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.65.4 {INST_EXPON: Bug 2798543} {
expr {(-5)**17 == (-5)**65553}
@@ -1278,7 +1278,7 @@ test expr-23.66.2 {INST_EXPON: Bug 2798543} {
expr {6**17 == 6**131089}
} 0
test expr-23.66.3 {INST_EXPON: Bug 2798543} -body {
- expr {6**17 == 6**268435473}
+ expr {6**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.66.4 {INST_EXPON: Bug 2798543} {
expr {(-6)**17 == (-6)**65553}
@@ -1293,7 +1293,7 @@ test expr-23.67.2 {INST_EXPON: Bug 2798543} {
expr {7**17 == 7**131089}
} 0
test expr-23.67.3 {INST_EXPON: Bug 2798543} -body {
- expr {7**17 == 7**268435473}
+ expr {7**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.67.4 {INST_EXPON: Bug 2798543} {
expr {(-7)**17 == (-7)**65553}
@@ -1308,7 +1308,7 @@ test expr-23.68.2 {INST_EXPON: Bug 2798543} {
expr {8**17 == 8**131089}
} 0
test expr-23.68.3 {INST_EXPON: Bug 2798543} -body {
- expr {8**17 == 8**268435473}
+ expr {8**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.68.4 {INST_EXPON: Bug 2798543} {
expr {(-8)**17 == (-8)**65553}
@@ -1323,7 +1323,7 @@ test expr-23.69.2 {INST_EXPON: Bug 2798543} {
expr {9**17 == 9**131089}
} 0
test expr-23.69.3 {INST_EXPON: Bug 2798543} -body {
- expr {9**17 == 9**268435473}
+ expr {9**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.69.4 {INST_EXPON: Bug 2798543} {
expr {(-9)**17 == (-9)**65553}
@@ -1338,7 +1338,7 @@ test expr-23.70.2 {INST_EXPON: Bug 2798543} {
expr {10**17 == 10**131089}
} 0
test expr-23.70.3 {INST_EXPON: Bug 2798543} -body {
- expr {10**17 == 10**268435473}
+ expr {10**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.70.4 {INST_EXPON: Bug 2798543} {
expr {(-10)**17 == (-10)**65553}
@@ -1353,7 +1353,7 @@ test expr-23.71.2 {INST_EXPON: Bug 2798543} {
expr {11**17 == 11**131089}
} 0
test expr-23.71.3 {INST_EXPON: Bug 2798543} -body {
- expr {11**17 == 11**268435473}
+ expr {11**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.71.4 {INST_EXPON: Bug 2798543} {
expr {(-11)**17 == (-11)**65553}
@@ -1365,7 +1365,7 @@ test expr-23.72.1 {INST_EXPON: Bug 2798543} {
expr {12**17 == 12**131089}
} 0
test expr-23.72.2 {INST_EXPON: Bug 2798543} -body {
- expr {12**17 == 12**268435473}
+ expr {12**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.72.3 {INST_EXPON: Bug 2798543} {
expr {(-12)**17 == (-12)**65553}
@@ -1377,7 +1377,7 @@ test expr-23.73.1 {INST_EXPON: Bug 2798543} {
expr {13**17 == 13**131089}
} 0
test expr-23.73.2 {INST_EXPON: Bug 2798543} -body {
- expr {13**17 == 13**268435473}
+ expr {13**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.73.3 {INST_EXPON: Bug 2798543} {
expr {(-13)**17 == (-13)**65553}
@@ -1389,7 +1389,7 @@ test expr-23.74.1 {INST_EXPON: Bug 2798543} {
expr {14**17 == 14**131089}
} 0
test expr-23.74.2 {INST_EXPON: Bug 2798543} -body {
- expr {14**17 == 14**268435473}
+ expr {14**268435456}
} -returnCodes error -result {exponent too large}
test expr-23.74.3 {INST_EXPON: Bug 2798543} {
expr {(-14)**17 == (-14)**65553}
diff --git a/tests/obj.test b/tests/obj.test
index 87c8d08..5bcffa3 100644
--- a/tests/obj.test
+++ b/tests/obj.test
@@ -476,11 +476,11 @@ test obj-26.1 {UpdateStringOfInt} testobj {
lappend result [testintobj get 1] ;# must update string rep
} {512 5120 5120}
-test obj-27.1 {Tcl_NewLongObj} testobj {
+test obj-27.1 {Tcl_NewWideObj} testobj {
set result ""
lappend result [testobj freeallvars]
- testintobj setmaxlong 1
- lappend result [testintobj ismaxlong 1]
+ testintobj setmax 1
+ lappend result [testintobj ismax 1]
lappend result [testobj type 1]
lappend result [testobj refcount 1]
} {{} 1 int 1}
@@ -489,7 +489,7 @@ test obj-28.1 {Tcl_SetLongObj, existing "empty string" object} testobj {
set result ""
lappend result [testobj freeallvars]
lappend result [testobj newobj 1]
- lappend result [testintobj setlong 1 77] ;# makes existing obj long int
+ lappend result [testintobj setint 1 77] ;# makes existing obj int
lappend result [testobj type 1]
lappend result [testobj refcount 1]
} {{} {} 77 int 2}
@@ -497,32 +497,32 @@ test obj-28.2 {Tcl_SetLongObj, existing non-"empty string" object} testobj {
set result ""
lappend result [testobj freeallvars]
lappend result [testdoubleobj set 1 12.34]
- lappend result [testintobj setlong 1 77] ;# makes existing obj long int
+ lappend result [testintobj setint 1 77] ;# makes existing obj int
lappend result [testobj type 1]
lappend result [testobj refcount 1]
} {{} 12.34 77 int 2}
-test obj-29.1 {Tcl_GetLongFromObj, existing long integer object} testobj {
+test obj-29.1 {Tcl_GetWideIntFromObj, existing int object} testobj {
set result ""
- lappend result [testintobj setlong 1 22]
- lappend result [testintobj mult10 1] ;# gets existing long int rep
+ lappend result [testintobj setint 1 22]
+ lappend result [testintobj mult10 1] ;# gets existingint rep
} {22 220}
-test obj-29.2 {Tcl_GetLongFromObj, convert to long} testobj {
+test obj-29.2 {Tcl_GetWideIntFromObj, convert to int} testobj {
set result ""
- lappend result [testintobj setlong 1 477]
+ lappend result [testintobj setint 1 477]
lappend result [testintobj div10 1] ;# must convert to bool
lappend result [testobj type 1]
} {477 47 int}
-test obj-29.3 {Tcl_GetLongFromObj, error converting to long integer} testobj {
+test obj-29.3 {Tcl_GetWideIntFromObj, error converting to int} testobj {
set result ""
lappend result [teststringobj set 1 abc]
- lappend result [catch {testintobj ismaxlong 1} msg] ;# cvts to long int
+ lappend result [catch {testintobj ismax 1} msg] ;# cvts to long int
lappend result $msg
} {abc 1 {expected integer but got "abc"}}
-test obj-29.4 {Tcl_GetLongFromObj, error converting from "empty string"} testobj {
+test obj-29.4 {Tcl_GetWideIntFromObj, error converting from "empty string"} testobj {
set result ""
lappend result [testobj newobj 1]
- lappend result [catch {testintobj ismaxlong 1} msg] ;# cvts to long int
+ lappend result [catch {testintobj ismax 1} msg] ;# cvts to long int
lappend result $msg
} {{} 1 {expected integer but got ""}}
diff --git a/tests/proc.test b/tests/proc.test
index 1893d0f..43d76d8 100644
--- a/tests/proc.test
+++ b/tests/proc.test
@@ -321,6 +321,9 @@ test proc-4.8 {TclCreateProc, procbody obj, no leak on multiple iterations} -set
rename getbytes {}
unset -nocomplain end i tmp leakedBytes
} -result 0
+test proc-4.9 {[39fed4dae5] Valid Tcl_PkgPresent return} procbodytest {
+ procbodytest::check
+} 1
test proc-5.1 {Bytecompiling noop; test for correct argument substitution} -body {
proc p args {} ; # this will be bytecompiled into t
diff --git a/tests/socket.test b/tests/socket.test
index d3d56fa..b91668e 100644
--- a/tests/socket.test
+++ b/tests/socket.test
@@ -68,6 +68,10 @@ if {[lsearch [namespace children] ::tcltest] == -1} {
::tcltest::loadTestedCommands
catch [list package require -exact Tcltest [info patchlevel]]
+if {[expr {[info exists ::env(TRAVIS_OSX_IMAGE)] && [string match xcode* $::env(TRAVIS_OSX_IMAGE)]}]} {
+ return
+}
+
# Some tests require the Thread package or exec command
testConstraint thread [expr {0 == [catch {package require Thread 2.7-}]}]
testConstraint exec [llength [info commands exec]]
@@ -125,9 +129,9 @@ catch {socket 127.0.0.1 [randport]}
set t2 [clock milliseconds]
set lat2 [expr {($t2-$t1)*3}]
-# Use the maximum of the two latency calculations, but at least 100ms
+# Use the maximum of the two latency calculations, but at least 200ms
set latency [expr {$lat1 > $lat2 ? $lat1 : $lat2}]
-set latency [expr {$latency > 100 ? $latency : 1000}]
+set latency [expr {$latency > 200 ? $latency : 200}]
unset t1 t2 s1 s2 lat1 lat2 server
# If remoteServerIP or remoteServerPort are not set, check in the environment
@@ -668,7 +672,7 @@ test socket_$af-2.11 {detecting new data} -constraints [list socket supported_$a
vwait sock
puts $s2 one
flush $s2
- after idle {set x 1}
+ after $latency {set x 1}; # Spurious failures in Travis CI, if we do [after idle]
vwait x
fconfigure $sock -blocking 0
set result a:[gets $sock]
diff --git a/tests/utf.test b/tests/utf.test
index e820359..72b8d97 100644
--- a/tests/utf.test
+++ b/tests/utf.test
@@ -44,16 +44,16 @@ test utf-1.6 {Tcl_UniCharToUtf: negative Tcl_UniChar} testbytestring {
test utf-1.7 {Tcl_UniCharToUtf: 4 byte sequences} -constraints testbytestring -body {
expr {"\U014e4e" eq [testbytestring "\xf0\x94\xb9\x8e"]}
} -result 1
-test utf-1.8 {Tcl_UniCharToUtf: 3 byte sequence, upper surrogate} testbytestring {
+test utf-1.8 {Tcl_UniCharToUtf: 3 byte sequence, high surrogate} testbytestring {
expr {"\ud842" eq [testbytestring "\xed\xa1\x82"]}
} 1
-test utf-1.9 {Tcl_UniCharToUtf: 3 byte sequence, lower surrogate} testbytestring {
+test utf-1.9 {Tcl_UniCharToUtf: 3 byte sequence, low surrogate} testbytestring {
expr {"\udc42" eq [testbytestring "\xed\xb1\x82"]}
} 1
-test utf-1.10 {Tcl_UniCharToUtf: 3 byte sequence, upper surrogate} testbytestring {
+test utf-1.10 {Tcl_UniCharToUtf: 3 byte sequence, high surrogate} testbytestring {
expr {[format %c 0xd842] eq [testbytestring "\xed\xa1\x82"]}
} 1
-test utf-1.11 {Tcl_UniCharToUtf: 3 byte sequence, lower surrogate} testbytestring {
+test utf-1.11 {Tcl_UniCharToUtf: 3 byte sequence, low surrogate} testbytestring {
expr {[format %c 0xdc42] eq [testbytestring "\xed\xb1\x82"]}
} 1
@@ -108,7 +108,7 @@ test utf-4.2 {Tcl_NumUtfChars: length 1} {testnumutfchars testbytestring} {
testnumutfchars [testbytestring "\xC2\xA2"]
} {1}
test utf-4.3 {Tcl_NumUtfChars: long string} {testnumutfchars testbytestring} {
- testnumutfchars [testbytestring "abc\xC2\xA2\xe4\xb9\x8e\uA2\u4e4e"]
+ testnumutfchars [testbytestring "abc\xC2\xA2\xE4\xB9\x8E\uA2\x4E"]
} {7}
test utf-4.4 {Tcl_NumUtfChars: #u0000} {testnumutfchars testbytestring} {
testnumutfchars [testbytestring "\xC0\x80"]
@@ -120,7 +120,7 @@ test utf-4.6 {Tcl_NumUtfChars: length 1, calc len} {testnumutfchars testbytestri
testnumutfchars [testbytestring "\xC2\xA2"] 2
} {1}
test utf-4.7 {Tcl_NumUtfChars: long string, calc len} {testnumutfchars testbytestring} {
- testnumutfchars [testbytestring "abc\xC2\xA2\xe4\xb9\x8e\uA2\u4e4e"] 10
+ testnumutfchars [testbytestring "abc\xC2\xA2\xE4\xB9\x8E\uA2\x4E"] 10
} {7}
test utf-4.8 {Tcl_NumUtfChars: #u0000, calc len} {testnumutfchars testbytestring} {
testnumutfchars [testbytestring "\xC0\x80"] 2
@@ -158,10 +158,10 @@ test utf-8.3 {Tcl_UniCharAtIndex: index > 0} {
test utf-8.4 {Tcl_UniCharAtIndex: index > 0} {
string index \u4e4e\u25a\xff\u543 2
} "\uff"
-test utf-8.5 {Tcl_UniCharAtIndex: upper surrogate} {
+test utf-8.5 {Tcl_UniCharAtIndex: high surrogate} {
string index \ud842 0
} "\ud842"
-test utf-8.5 {Tcl_UniCharAtIndex: lower surrogate} {
+test utf-8.5 {Tcl_UniCharAtIndex: low surrogate} {
string index \udc42 0
} "\udc42"
@@ -189,6 +189,12 @@ test utf-10.4 {Tcl_UtfBackslash: stops at first non-hex} testbytestring {
test utf-10.5 {Tcl_UtfBackslash: stops after 4 hex chars} testbytestring {
expr {"\u4e216" eq "[testbytestring \xe4\xb8\xa1]6"}
} 1
+test utf-10.6 {Tcl_UtfBackslash: stops after 5 hex chars} testbytestring {
+ expr {"\U1e2165" eq "[testbytestring \xf0\x9e\x88\x96]5"}
+} 1
+test utf-10.6 {Tcl_UtfBackslash: stops after 6 hex chars} testbytestring {
+ expr {"\U10e2165" eq "[testbytestring \xf4\x8e\x88\x96]5"}
+} 1
proc bsCheck {char num} {
global errNum
test utf-10.$errNum {backslash substitution} {
diff --git a/tests/util.test b/tests/util.test
index 5079a89..a9199f4 100644
--- a/tests/util.test
+++ b/tests/util.test
@@ -22,6 +22,9 @@ testConstraint testconcatobj [llength [info commands testconcatobj]]
testConstraint testdoubledigits [llength [info commands testdoubledigits]]
testConstraint testprint [llength [info commands testprint]]
+testConstraint precision [expr {![catch {set saved_precision $::tcl_precision}]}]
+
+
# Big test for correct ordering of data in [expr]
proc testIEEE {} {
@@ -279,7 +282,7 @@ test util-5.17 {Tcl_StringMatch: UTF-8} {
test util-5.18 {Tcl_StringMatch: UTF-8} testbytestring {
# pattern += Tcl_UtfToUniChar(pattern, &endChar);
# proper advance: wrong answer would match on UTF trail byte of \u4e4f
- Wrapper_Tcl_StringMatch {a[a\u4e4fc]c} [testbytestring a\u008fc]
+ Wrapper_Tcl_StringMatch {a[a\u4e4fc]c} [testbytestring a\x8fc]
} 0
test util-5.19 {Tcl_StringMatch: UTF-8} {
# pattern += Tcl_UtfToUniChar(pattern, &endChar);
@@ -385,7 +388,7 @@ test util-5.51 {Tcl_StringMatch} {
Wrapper_Tcl_StringMatch "" ""
} 1
-test util-6.1 {Tcl_PrintDouble - using tcl_precision} -setup {
+test util-6.1 {Tcl_PrintDouble - using tcl_precision} -constraints precision -setup {
set old_precision $::tcl_precision
set ::tcl_precision 12
} -body {
@@ -393,7 +396,7 @@ test util-6.1 {Tcl_PrintDouble - using tcl_precision} -setup {
} -cleanup {
set ::tcl_precision $old_precision
} -result {x1.4}
-test util-6.2 {Tcl_PrintDouble - using tcl_precision} -setup {
+test util-6.2 {Tcl_PrintDouble - using tcl_precision} -constraints precision -setup {
set old_precision $::tcl_precision
set ::tcl_precision 12
} -body {
@@ -401,7 +404,7 @@ test util-6.2 {Tcl_PrintDouble - using tcl_precision} -setup {
} -cleanup {
set ::tcl_precision $old_precision
} -result {x1.39999999999}
-test util-6.3 {Tcl_PrintDouble - using tcl_precision} -setup {
+test util-6.3 {Tcl_PrintDouble - using tcl_precision} -constraints precision -setup {
set old_precision $::tcl_precision
set ::tcl_precision 12
} -body {
@@ -409,7 +412,7 @@ test util-6.3 {Tcl_PrintDouble - using tcl_precision} -setup {
} -cleanup {
set ::tcl_precision $old_precision
} -result {x1.4}
-test util-6.4 {Tcl_PrintDouble - using tcl_precision} -setup {
+test util-6.4 {Tcl_PrintDouble - using tcl_precision} -constraints precision -setup {
set old_precision $::tcl_precision
set ::tcl_precision 5
} -body {
@@ -424,7 +427,7 @@ test util-6.6 {Tcl_PrintDouble - make sure there's a decimal point} {
concat x[expr 3.0e98]
} {x3e+98}
-test util-7.1 {TclPrecTraceProc - unset callbacks} -setup {
+test util-7.1 {TclPrecTraceProc - unset callbacks} -constraints precision -setup {
set old_precision $::tcl_precision
} -body {
set tcl_precision 7
@@ -434,7 +437,7 @@ test util-7.1 {TclPrecTraceProc - unset callbacks} -setup {
} -cleanup {
set ::tcl_precision $old_precision
} -result {7 7}
-test util-7.2 {TclPrecTraceProc - read traces, sharing among interpreters} -setup {
+test util-7.2 {TclPrecTraceProc - read traces, sharing among interpreters} -constraints precision -setup {
set old_precision $::tcl_precision
} -body {
set tcl_precision 12
@@ -446,7 +449,7 @@ test util-7.2 {TclPrecTraceProc - read traces, sharing among interpreters} -set
} -cleanup {
set ::tcl_precision $old_precision
} -result {12 6}
-test util-7.3 {TclPrecTraceProc - write traces, safe interpreters} -setup {
+test util-7.3 {TclPrecTraceProc - write traces, safe interpreters} -constraints precision -setup {
set old_precision $::tcl_precision
} -body {
set tcl_precision 12
@@ -459,7 +462,7 @@ test util-7.3 {TclPrecTraceProc - write traces, safe interpreters} -setup {
} -cleanup {
set ::tcl_precision $old_precision
} -result {{1 {can't set "tcl_precision": can't modify precision from a safe interpreter}} 12}
-test util-7.4 {TclPrecTraceProc - write traces, bogus values} -setup {
+test util-7.4 {TclPrecTraceProc - write traces, bogus values} -constraints precision -setup {
set old_precision $::tcl_precision
} -body {
set tcl_precision 12
@@ -2181,7 +2184,6 @@ test util-15.8 {smallest normal} {*}{
}
}
-set saved_precision $::tcl_precision
foreach ::tcl_precision {0 12} {
for {set e -312} {$e < -9} {incr e} {
test util-16.1.$::tcl_precision.$e {shortening of numbers} \
@@ -2195,7 +2197,7 @@ for {set e -9} {$e < -4} {incr e} {
}
set tcl_precision 12
for {set e -9} {$e < -4} {incr e} {
- test util-16.1.$::tcl_precision.$e {8.4 compatible formatting of doubles} \
+ test util-16.1.$::tcl_precision.$e {8.4 compatible formatting of doubles} precision \
"expr 1.1e$e" 1.1e[format %+03d $e]
}
foreach ::tcl_precision {0 12} {
@@ -2225,1828 +2227,1828 @@ foreach ::tcl_precision {0 12} {
}
}
set tcl_precision 17
-test util-16.1.17.-300 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-300 {8.4 compatible formatting of doubles} precision \
{expr 1e-300} \
1e-300
-test util-16.1.17.-299 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-299 {8.4 compatible formatting of doubles} precision \
{expr 1e-299} \
9.9999999999999999e-300
-test util-16.1.17.-298 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-298 {8.4 compatible formatting of doubles} precision \
{expr 1e-298} \
9.9999999999999991e-299
-test util-16.1.17.-297 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-297 {8.4 compatible formatting of doubles} precision \
{expr 1e-297} \
1e-297
-test util-16.1.17.-296 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-296 {8.4 compatible formatting of doubles} precision \
{expr 1e-296} \
1e-296
-test util-16.1.17.-295 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-295 {8.4 compatible formatting of doubles} precision \
{expr 1e-295} \
1.0000000000000001e-295
-test util-16.1.17.-294 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-294 {8.4 compatible formatting of doubles} precision \
{expr 1e-294} \
1e-294
-test util-16.1.17.-293 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-293 {8.4 compatible formatting of doubles} precision \
{expr 1e-293} \
1.0000000000000001e-293
-test util-16.1.17.-292 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-292 {8.4 compatible formatting of doubles} precision \
{expr 1e-292} \
1.0000000000000001e-292
-test util-16.1.17.-291 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-291 {8.4 compatible formatting of doubles} precision \
{expr 1e-291} \
9.9999999999999996e-292
-test util-16.1.17.-290 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-290 {8.4 compatible formatting of doubles} precision \
{expr 1e-290} \
1.0000000000000001e-290
-test util-16.1.17.-289 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-289 {8.4 compatible formatting of doubles} precision \
{expr 1e-289} \
1e-289
-test util-16.1.17.-288 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-288 {8.4 compatible formatting of doubles} precision \
{expr 1e-288} \
1.0000000000000001e-288
-test util-16.1.17.-287 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-287 {8.4 compatible formatting of doubles} precision \
{expr 1e-287} \
1e-287
-test util-16.1.17.-286 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-286 {8.4 compatible formatting of doubles} precision \
{expr 1e-286} \
1.0000000000000001e-286
-test util-16.1.17.-285 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-285 {8.4 compatible formatting of doubles} precision \
{expr 1e-285} \
1.0000000000000001e-285
-test util-16.1.17.-284 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-284 {8.4 compatible formatting of doubles} precision \
{expr 1e-284} \
1e-284
-test util-16.1.17.-283 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-283 {8.4 compatible formatting of doubles} precision \
{expr 1e-283} \
9.9999999999999995e-284
-test util-16.1.17.-282 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-282 {8.4 compatible formatting of doubles} precision \
{expr 1e-282} \
1e-282
-test util-16.1.17.-281 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-281 {8.4 compatible formatting of doubles} precision \
{expr 1e-281} \
1e-281
-test util-16.1.17.-280 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-280 {8.4 compatible formatting of doubles} precision \
{expr 1e-280} \
9.9999999999999996e-281
-test util-16.1.17.-279 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-279 {8.4 compatible formatting of doubles} precision \
{expr 1e-279} \
1.0000000000000001e-279
-test util-16.1.17.-278 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-278 {8.4 compatible formatting of doubles} precision \
{expr 1e-278} \
9.9999999999999994e-279
-test util-16.1.17.-277 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-277 {8.4 compatible formatting of doubles} precision \
{expr 1e-277} \
9.9999999999999997e-278
-test util-16.1.17.-276 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-276 {8.4 compatible formatting of doubles} precision \
{expr 1e-276} \
1.0000000000000001e-276
-test util-16.1.17.-275 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-275 {8.4 compatible formatting of doubles} precision \
{expr 1e-275} \
9.9999999999999993e-276
-test util-16.1.17.-274 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-274 {8.4 compatible formatting of doubles} precision \
{expr 1e-274} \
9.9999999999999997e-275
-test util-16.1.17.-273 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-273 {8.4 compatible formatting of doubles} precision \
{expr 1e-273} \
1.0000000000000001e-273
-test util-16.1.17.-272 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-272 {8.4 compatible formatting of doubles} precision \
{expr 1e-272} \
9.9999999999999993e-273
-test util-16.1.17.-271 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-271 {8.4 compatible formatting of doubles} precision \
{expr 1e-271} \
9.9999999999999996e-272
-test util-16.1.17.-270 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-270 {8.4 compatible formatting of doubles} precision \
{expr 1e-270} \
1e-270
-test util-16.1.17.-269 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-269 {8.4 compatible formatting of doubles} precision \
{expr 1e-269} \
9.9999999999999996e-270
-test util-16.1.17.-268 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-268 {8.4 compatible formatting of doubles} precision \
{expr 1e-268} \
9.9999999999999996e-269
-test util-16.1.17.-267 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-267 {8.4 compatible formatting of doubles} precision \
{expr 1e-267} \
9.9999999999999998e-268
-test util-16.1.17.-266 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-266 {8.4 compatible formatting of doubles} precision \
{expr 1e-266} \
9.9999999999999998e-267
-test util-16.1.17.-265 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-265 {8.4 compatible formatting of doubles} precision \
{expr 1e-265} \
9.9999999999999998e-266
-test util-16.1.17.-264 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-264 {8.4 compatible formatting of doubles} precision \
{expr 1e-264} \
1e-264
-test util-16.1.17.-263 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-263 {8.4 compatible formatting of doubles} precision \
{expr 1e-263} \
1e-263
-test util-16.1.17.-262 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-262 {8.4 compatible formatting of doubles} precision \
{expr 1e-262} \
1e-262
-test util-16.1.17.-261 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-261 {8.4 compatible formatting of doubles} precision \
{expr 1e-261} \
9.9999999999999998e-262
-test util-16.1.17.-260 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-260 {8.4 compatible formatting of doubles} precision \
{expr 1e-260} \
9.9999999999999996e-261
-test util-16.1.17.-259 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-259 {8.4 compatible formatting of doubles} precision \
{expr 1e-259} \
1.0000000000000001e-259
-test util-16.1.17.-258 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-258 {8.4 compatible formatting of doubles} precision \
{expr 1e-258} \
9.9999999999999995e-259
-test util-16.1.17.-257 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-257 {8.4 compatible formatting of doubles} precision \
{expr 1e-257} \
9.9999999999999998e-258
-test util-16.1.17.-256 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-256 {8.4 compatible formatting of doubles} precision \
{expr 1e-256} \
9.9999999999999998e-257
-test util-16.1.17.-255 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-255 {8.4 compatible formatting of doubles} precision \
{expr 1e-255} \
1e-255
-test util-16.1.17.-254 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-254 {8.4 compatible formatting of doubles} precision \
{expr 1e-254} \
9.9999999999999991e-255
-test util-16.1.17.-253 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-253 {8.4 compatible formatting of doubles} precision \
{expr 1e-253} \
1.0000000000000001e-253
-test util-16.1.17.-252 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-252 {8.4 compatible formatting of doubles} precision \
{expr 1e-252} \
9.9999999999999994e-253
-test util-16.1.17.-251 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-251 {8.4 compatible formatting of doubles} precision \
{expr 1e-251} \
1e-251
-test util-16.1.17.-250 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-250 {8.4 compatible formatting of doubles} precision \
{expr 1e-250} \
1.0000000000000001e-250
-test util-16.1.17.-249 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-249 {8.4 compatible formatting of doubles} precision \
{expr 1e-249} \
1.0000000000000001e-249
-test util-16.1.17.-248 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-248 {8.4 compatible formatting of doubles} precision \
{expr 1e-248} \
9.9999999999999998e-249
-test util-16.1.17.-247 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-247 {8.4 compatible formatting of doubles} precision \
{expr 1e-247} \
1e-247
-test util-16.1.17.-246 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-246 {8.4 compatible formatting of doubles} precision \
{expr 1e-246} \
9.9999999999999996e-247
-test util-16.1.17.-245 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-245 {8.4 compatible formatting of doubles} precision \
{expr 1e-245} \
9.9999999999999993e-246
-test util-16.1.17.-244 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-244 {8.4 compatible formatting of doubles} precision \
{expr 1e-244} \
9.9999999999999993e-245
-test util-16.1.17.-243 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-243 {8.4 compatible formatting of doubles} precision \
{expr 1e-243} \
1e-243
-test util-16.1.17.-242 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-242 {8.4 compatible formatting of doubles} precision \
{expr 1e-242} \
9.9999999999999997e-243
-test util-16.1.17.-241 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-241 {8.4 compatible formatting of doubles} precision \
{expr 1e-241} \
9.9999999999999997e-242
-test util-16.1.17.-240 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-240 {8.4 compatible formatting of doubles} precision \
{expr 1e-240} \
9.9999999999999997e-241
-test util-16.1.17.-239 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-239 {8.4 compatible formatting of doubles} precision \
{expr 1e-239} \
1.0000000000000001e-239
-test util-16.1.17.-238 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-238 {8.4 compatible formatting of doubles} precision \
{expr 1e-238} \
9.9999999999999999e-239
-test util-16.1.17.-237 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-237 {8.4 compatible formatting of doubles} precision \
{expr 1e-237} \
9.9999999999999999e-238
-test util-16.1.17.-236 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-236 {8.4 compatible formatting of doubles} precision \
{expr 1e-236} \
1e-236
-test util-16.1.17.-235 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-235 {8.4 compatible formatting of doubles} precision \
{expr 1e-235} \
9.9999999999999996e-236
-test util-16.1.17.-234 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-234 {8.4 compatible formatting of doubles} precision \
{expr 1e-234} \
9.9999999999999996e-235
-test util-16.1.17.-233 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-233 {8.4 compatible formatting of doubles} precision \
{expr 1e-233} \
9.9999999999999996e-234
-test util-16.1.17.-232 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-232 {8.4 compatible formatting of doubles} precision \
{expr 1e-232} \
1e-232
-test util-16.1.17.-231 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-231 {8.4 compatible formatting of doubles} precision \
{expr 1e-231} \
9.9999999999999999e-232
-test util-16.1.17.-230 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-230 {8.4 compatible formatting of doubles} precision \
{expr 1e-230} \
1e-230
-test util-16.1.17.-229 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-229 {8.4 compatible formatting of doubles} precision \
{expr 1e-229} \
1.0000000000000001e-229
-test util-16.1.17.-228 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-228 {8.4 compatible formatting of doubles} precision \
{expr 1e-228} \
1e-228
-test util-16.1.17.-227 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-227 {8.4 compatible formatting of doubles} precision \
{expr 1e-227} \
9.9999999999999994e-228
-test util-16.1.17.-226 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-226 {8.4 compatible formatting of doubles} precision \
{expr 1e-226} \
9.9999999999999992e-227
-test util-16.1.17.-225 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-225 {8.4 compatible formatting of doubles} precision \
{expr 1e-225} \
9.9999999999999996e-226
-test util-16.1.17.-224 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-224 {8.4 compatible formatting of doubles} precision \
{expr 1e-224} \
1e-224
-test util-16.1.17.-223 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-223 {8.4 compatible formatting of doubles} precision \
{expr 1e-223} \
9.9999999999999997e-224
-test util-16.1.17.-222 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-222 {8.4 compatible formatting of doubles} precision \
{expr 1e-222} \
1e-222
-test util-16.1.17.-221 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-221 {8.4 compatible formatting of doubles} precision \
{expr 1e-221} \
1e-221
-test util-16.1.17.-220 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-220 {8.4 compatible formatting of doubles} precision \
{expr 1e-220} \
9.9999999999999999e-221
-test util-16.1.17.-219 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-219 {8.4 compatible formatting of doubles} precision \
{expr 1e-219} \
1e-219
-test util-16.1.17.-218 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-218 {8.4 compatible formatting of doubles} precision \
{expr 1e-218} \
1e-218
-test util-16.1.17.-217 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-217 {8.4 compatible formatting of doubles} precision \
{expr 1e-217} \
1.0000000000000001e-217
-test util-16.1.17.-216 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-216 {8.4 compatible formatting of doubles} precision \
{expr 1e-216} \
1e-216
-test util-16.1.17.-215 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-215 {8.4 compatible formatting of doubles} precision \
{expr 1e-215} \
1e-215
-test util-16.1.17.-214 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-214 {8.4 compatible formatting of doubles} precision \
{expr 1e-214} \
9.9999999999999991e-215
-test util-16.1.17.-213 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-213 {8.4 compatible formatting of doubles} precision \
{expr 1e-213} \
9.9999999999999995e-214
-test util-16.1.17.-212 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-212 {8.4 compatible formatting of doubles} precision \
{expr 1e-212} \
9.9999999999999995e-213
-test util-16.1.17.-211 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-211 {8.4 compatible formatting of doubles} precision \
{expr 1e-211} \
1.0000000000000001e-211
-test util-16.1.17.-210 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-210 {8.4 compatible formatting of doubles} precision \
{expr 1e-210} \
1e-210
-test util-16.1.17.-209 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-209 {8.4 compatible formatting of doubles} precision \
{expr 1e-209} \
1e-209
-test util-16.1.17.-208 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-208 {8.4 compatible formatting of doubles} precision \
{expr 1e-208} \
1.0000000000000001e-208
-test util-16.1.17.-207 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-207 {8.4 compatible formatting of doubles} precision \
{expr 1e-207} \
9.9999999999999993e-208
-test util-16.1.17.-206 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-206 {8.4 compatible formatting of doubles} precision \
{expr 1e-206} \
1e-206
-test util-16.1.17.-205 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-205 {8.4 compatible formatting of doubles} precision \
{expr 1e-205} \
1e-205
-test util-16.1.17.-204 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-204 {8.4 compatible formatting of doubles} precision \
{expr 1e-204} \
1e-204
-test util-16.1.17.-203 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-203 {8.4 compatible formatting of doubles} precision \
{expr 1e-203} \
1e-203
-test util-16.1.17.-202 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-202 {8.4 compatible formatting of doubles} precision \
{expr 1e-202} \
1e-202
-test util-16.1.17.-201 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-201 {8.4 compatible formatting of doubles} precision \
{expr 1e-201} \
9.9999999999999995e-202
-test util-16.1.17.-200 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-200 {8.4 compatible formatting of doubles} precision \
{expr 1e-200} \
9.9999999999999998e-201
-test util-16.1.17.-199 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-199 {8.4 compatible formatting of doubles} precision \
{expr 1e-199} \
9.9999999999999998e-200
-test util-16.1.17.-198 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-198 {8.4 compatible formatting of doubles} precision \
{expr 1e-198} \
9.9999999999999991e-199
-test util-16.1.17.-197 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-197 {8.4 compatible formatting of doubles} precision \
{expr 1e-197} \
9.9999999999999999e-198
-test util-16.1.17.-196 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-196 {8.4 compatible formatting of doubles} precision \
{expr 1e-196} \
1e-196
-test util-16.1.17.-195 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-195 {8.4 compatible formatting of doubles} precision \
{expr 1e-195} \
1.0000000000000001e-195
-test util-16.1.17.-194 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-194 {8.4 compatible formatting of doubles} precision \
{expr 1e-194} \
1e-194
-test util-16.1.17.-193 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-193 {8.4 compatible formatting of doubles} precision \
{expr 1e-193} \
1e-193
-test util-16.1.17.-192 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-192 {8.4 compatible formatting of doubles} precision \
{expr 1e-192} \
1.0000000000000001e-192
-test util-16.1.17.-191 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-191 {8.4 compatible formatting of doubles} precision \
{expr 1e-191} \
1e-191
-test util-16.1.17.-190 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-190 {8.4 compatible formatting of doubles} precision \
{expr 1e-190} \
1e-190
-test util-16.1.17.-189 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-189 {8.4 compatible formatting of doubles} precision \
{expr 1e-189} \
1.0000000000000001e-189
-test util-16.1.17.-188 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-188 {8.4 compatible formatting of doubles} precision \
{expr 1e-188} \
9.9999999999999995e-189
-test util-16.1.17.-187 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-187 {8.4 compatible formatting of doubles} precision \
{expr 1e-187} \
1e-187
-test util-16.1.17.-186 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-186 {8.4 compatible formatting of doubles} precision \
{expr 1e-186} \
9.9999999999999991e-187
-test util-16.1.17.-185 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-185 {8.4 compatible formatting of doubles} precision \
{expr 1e-185} \
9.9999999999999999e-186
-test util-16.1.17.-184 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-184 {8.4 compatible formatting of doubles} precision \
{expr 1e-184} \
1.0000000000000001e-184
-test util-16.1.17.-183 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-183 {8.4 compatible formatting of doubles} precision \
{expr 1e-183} \
1e-183
-test util-16.1.17.-182 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-182 {8.4 compatible formatting of doubles} precision \
{expr 1e-182} \
1e-182
-test util-16.1.17.-181 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-181 {8.4 compatible formatting of doubles} precision \
{expr 1e-181} \
1e-181
-test util-16.1.17.-180 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-180 {8.4 compatible formatting of doubles} precision \
{expr 1e-180} \
1e-180
-test util-16.1.17.-179 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-179 {8.4 compatible formatting of doubles} precision \
{expr 1e-179} \
1e-179
-test util-16.1.17.-178 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-178 {8.4 compatible formatting of doubles} precision \
{expr 1e-178} \
9.9999999999999995e-179
-test util-16.1.17.-177 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-177 {8.4 compatible formatting of doubles} precision \
{expr 1e-177} \
9.9999999999999995e-178
-test util-16.1.17.-176 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-176 {8.4 compatible formatting of doubles} precision \
{expr 1e-176} \
1e-176
-test util-16.1.17.-175 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-175 {8.4 compatible formatting of doubles} precision \
{expr 1e-175} \
1e-175
-test util-16.1.17.-174 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-174 {8.4 compatible formatting of doubles} precision \
{expr 1e-174} \
1e-174
-test util-16.1.17.-173 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-173 {8.4 compatible formatting of doubles} precision \
{expr 1e-173} \
1e-173
-test util-16.1.17.-172 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-172 {8.4 compatible formatting of doubles} precision \
{expr 1e-172} \
1e-172
-test util-16.1.17.-171 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-171 {8.4 compatible formatting of doubles} precision \
{expr 1e-171} \
9.9999999999999998e-172
-test util-16.1.17.-170 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-170 {8.4 compatible formatting of doubles} precision \
{expr 1e-170} \
9.9999999999999998e-171
-test util-16.1.17.-169 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-169 {8.4 compatible formatting of doubles} precision \
{expr 1e-169} \
1e-169
-test util-16.1.17.-168 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-168 {8.4 compatible formatting of doubles} precision \
{expr 1e-168} \
1e-168
-test util-16.1.17.-167 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-167 {8.4 compatible formatting of doubles} precision \
{expr 1e-167} \
1e-167
-test util-16.1.17.-166 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-166 {8.4 compatible formatting of doubles} precision \
{expr 1e-166} \
1e-166
-test util-16.1.17.-165 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-165 {8.4 compatible formatting of doubles} precision \
{expr 1e-165} \
1e-165
-test util-16.1.17.-164 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-164 {8.4 compatible formatting of doubles} precision \
{expr 1e-164} \
9.9999999999999996e-165
-test util-16.1.17.-163 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-163 {8.4 compatible formatting of doubles} precision \
{expr 1e-163} \
9.9999999999999992e-164
-test util-16.1.17.-162 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-162 {8.4 compatible formatting of doubles} precision \
{expr 1e-162} \
9.9999999999999995e-163
-test util-16.1.17.-161 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-161 {8.4 compatible formatting of doubles} precision \
{expr 1e-161} \
1e-161
-test util-16.1.17.-160 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-160 {8.4 compatible formatting of doubles} precision \
{expr 1e-160} \
9.9999999999999999e-161
-test util-16.1.17.-159 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-159 {8.4 compatible formatting of doubles} precision \
{expr 1e-159} \
9.9999999999999999e-160
-test util-16.1.17.-158 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-158 {8.4 compatible formatting of doubles} precision \
{expr 1e-158} \
1.0000000000000001e-158
-test util-16.1.17.-157 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-157 {8.4 compatible formatting of doubles} precision \
{expr 1e-157} \
9.9999999999999994e-158
-test util-16.1.17.-156 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-156 {8.4 compatible formatting of doubles} precision \
{expr 1e-156} \
1e-156
-test util-16.1.17.-155 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-155 {8.4 compatible formatting of doubles} precision \
{expr 1e-155} \
1e-155
-test util-16.1.17.-154 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-154 {8.4 compatible formatting of doubles} precision \
{expr 1e-154} \
9.9999999999999997e-155
-test util-16.1.17.-153 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-153 {8.4 compatible formatting of doubles} precision \
{expr 1e-153} \
1e-153
-test util-16.1.17.-152 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-152 {8.4 compatible formatting of doubles} precision \
{expr 1e-152} \
1.0000000000000001e-152
-test util-16.1.17.-151 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-151 {8.4 compatible formatting of doubles} precision \
{expr 1e-151} \
9.9999999999999994e-152
-test util-16.1.17.-150 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-150 {8.4 compatible formatting of doubles} precision \
{expr 1e-150} \
1e-150
-test util-16.1.17.-149 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-149 {8.4 compatible formatting of doubles} precision \
{expr 1e-149} \
9.9999999999999998e-150
-test util-16.1.17.-148 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-148 {8.4 compatible formatting of doubles} precision \
{expr 1e-148} \
9.9999999999999994e-149
-test util-16.1.17.-147 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-147 {8.4 compatible formatting of doubles} precision \
{expr 1e-147} \
9.9999999999999997e-148
-test util-16.1.17.-146 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-146 {8.4 compatible formatting of doubles} precision \
{expr 1e-146} \
1e-146
-test util-16.1.17.-145 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-145 {8.4 compatible formatting of doubles} precision \
{expr 1e-145} \
9.9999999999999991e-146
-test util-16.1.17.-144 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-144 {8.4 compatible formatting of doubles} precision \
{expr 1e-144} \
9.9999999999999995e-145
-test util-16.1.17.-143 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-143 {8.4 compatible formatting of doubles} precision \
{expr 1e-143} \
9.9999999999999995e-144
-test util-16.1.17.-142 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-142 {8.4 compatible formatting of doubles} precision \
{expr 1e-142} \
1e-142
-test util-16.1.17.-141 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-141 {8.4 compatible formatting of doubles} precision \
{expr 1e-141} \
1e-141
-test util-16.1.17.-140 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-140 {8.4 compatible formatting of doubles} precision \
{expr 1e-140} \
9.9999999999999998e-141
-test util-16.1.17.-139 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-139 {8.4 compatible formatting of doubles} precision \
{expr 1e-139} \
1e-139
-test util-16.1.17.-138 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-138 {8.4 compatible formatting of doubles} precision \
{expr 1e-138} \
1.0000000000000001e-138
-test util-16.1.17.-137 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-137 {8.4 compatible formatting of doubles} precision \
{expr 1e-137} \
9.9999999999999998e-138
-test util-16.1.17.-136 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-136 {8.4 compatible formatting of doubles} precision \
{expr 1e-136} \
1e-136
-test util-16.1.17.-135 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-135 {8.4 compatible formatting of doubles} precision \
{expr 1e-135} \
1e-135
-test util-16.1.17.-134 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-134 {8.4 compatible formatting of doubles} precision \
{expr 1e-134} \
1e-134
-test util-16.1.17.-133 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-133 {8.4 compatible formatting of doubles} precision \
{expr 1e-133} \
1.0000000000000001e-133
-test util-16.1.17.-132 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-132 {8.4 compatible formatting of doubles} precision \
{expr 1e-132} \
9.9999999999999999e-133
-test util-16.1.17.-131 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-131 {8.4 compatible formatting of doubles} precision \
{expr 1e-131} \
9.9999999999999999e-132
-test util-16.1.17.-130 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-130 {8.4 compatible formatting of doubles} precision \
{expr 1e-130} \
1.0000000000000001e-130
-test util-16.1.17.-129 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-129 {8.4 compatible formatting of doubles} precision \
{expr 1e-129} \
9.9999999999999993e-130
-test util-16.1.17.-128 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-128 {8.4 compatible formatting of doubles} precision \
{expr 1e-128} \
1.0000000000000001e-128
-test util-16.1.17.-127 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-127 {8.4 compatible formatting of doubles} precision \
{expr 1e-127} \
1e-127
-test util-16.1.17.-126 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-126 {8.4 compatible formatting of doubles} precision \
{expr 1e-126} \
9.9999999999999995e-127
-test util-16.1.17.-125 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-125 {8.4 compatible formatting of doubles} precision \
{expr 1e-125} \
1e-125
-test util-16.1.17.-124 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-124 {8.4 compatible formatting of doubles} precision \
{expr 1e-124} \
9.9999999999999993e-125
-test util-16.1.17.-123 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-123 {8.4 compatible formatting of doubles} precision \
{expr 1e-123} \
1.0000000000000001e-123
-test util-16.1.17.-122 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-122 {8.4 compatible formatting of doubles} precision \
{expr 1e-122} \
1.0000000000000001e-122
-test util-16.1.17.-121 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-121 {8.4 compatible formatting of doubles} precision \
{expr 1e-121} \
9.9999999999999998e-122
-test util-16.1.17.-120 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-120 {8.4 compatible formatting of doubles} precision \
{expr 1e-120} \
9.9999999999999998e-121
-test util-16.1.17.-119 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-119 {8.4 compatible formatting of doubles} precision \
{expr 1e-119} \
1e-119
-test util-16.1.17.-118 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-118 {8.4 compatible formatting of doubles} precision \
{expr 1e-118} \
9.9999999999999999e-119
-test util-16.1.17.-117 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-117 {8.4 compatible formatting of doubles} precision \
{expr 1e-117} \
1e-117
-test util-16.1.17.-116 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-116 {8.4 compatible formatting of doubles} precision \
{expr 1e-116} \
9.9999999999999999e-117
-test util-16.1.17.-115 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-115 {8.4 compatible formatting of doubles} precision \
{expr 1e-115} \
1.0000000000000001e-115
-test util-16.1.17.-114 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-114 {8.4 compatible formatting of doubles} precision \
{expr 1e-114} \
1.0000000000000001e-114
-test util-16.1.17.-113 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-113 {8.4 compatible formatting of doubles} precision \
{expr 1e-113} \
9.9999999999999998e-114
-test util-16.1.17.-112 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-112 {8.4 compatible formatting of doubles} precision \
{expr 1e-112} \
9.9999999999999995e-113
-test util-16.1.17.-111 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-111 {8.4 compatible formatting of doubles} precision \
{expr 1e-111} \
1.0000000000000001e-111
-test util-16.1.17.-110 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-110 {8.4 compatible formatting of doubles} precision \
{expr 1e-110} \
1.0000000000000001e-110
-test util-16.1.17.-109 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-109 {8.4 compatible formatting of doubles} precision \
{expr 1e-109} \
9.9999999999999999e-110
-test util-16.1.17.-108 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-108 {8.4 compatible formatting of doubles} precision \
{expr 1e-108} \
1e-108
-test util-16.1.17.-107 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-107 {8.4 compatible formatting of doubles} precision \
{expr 1e-107} \
1e-107
-test util-16.1.17.-106 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-106 {8.4 compatible formatting of doubles} precision \
{expr 1e-106} \
9.9999999999999994e-107
-test util-16.1.17.-105 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-105 {8.4 compatible formatting of doubles} precision \
{expr 1e-105} \
9.9999999999999997e-106
-test util-16.1.17.-104 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-104 {8.4 compatible formatting of doubles} precision \
{expr 1e-104} \
9.9999999999999993e-105
-test util-16.1.17.-103 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-103 {8.4 compatible formatting of doubles} precision \
{expr 1e-103} \
9.9999999999999996e-104
-test util-16.1.17.-102 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-102 {8.4 compatible formatting of doubles} precision \
{expr 1e-102} \
9.9999999999999993e-103
-test util-16.1.17.-101 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-101 {8.4 compatible formatting of doubles} precision \
{expr 1e-101} \
1.0000000000000001e-101
-test util-16.1.17.-100 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-100 {8.4 compatible formatting of doubles} precision \
{expr 1e-100} \
1e-100
-test util-16.1.17.-99 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-99 {8.4 compatible formatting of doubles} precision \
{expr 1e-99} \
1e-99
-test util-16.1.17.-98 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-98 {8.4 compatible formatting of doubles} precision \
{expr 1e-98} \
9.9999999999999994e-99
-test util-16.1.17.-97 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-97 {8.4 compatible formatting of doubles} precision \
{expr 1e-97} \
1e-97
-test util-16.1.17.-96 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-96 {8.4 compatible formatting of doubles} precision \
{expr 1e-96} \
9.9999999999999991e-97
-test util-16.1.17.-95 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-95 {8.4 compatible formatting of doubles} precision \
{expr 1e-95} \
9.9999999999999999e-96
-test util-16.1.17.-94 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-94 {8.4 compatible formatting of doubles} precision \
{expr 1e-94} \
9.9999999999999996e-95
-test util-16.1.17.-93 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-93 {8.4 compatible formatting of doubles} precision \
{expr 1e-93} \
9.999999999999999e-94
-test util-16.1.17.-92 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-92 {8.4 compatible formatting of doubles} precision \
{expr 1e-92} \
9.9999999999999999e-93
-test util-16.1.17.-91 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-91 {8.4 compatible formatting of doubles} precision \
{expr 1e-91} \
1e-91
-test util-16.1.17.-90 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-90 {8.4 compatible formatting of doubles} precision \
{expr 1e-90} \
9.9999999999999999e-91
-test util-16.1.17.-89 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-89 {8.4 compatible formatting of doubles} precision \
{expr 1e-89} \
1e-89
-test util-16.1.17.-88 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-88 {8.4 compatible formatting of doubles} precision \
{expr 1e-88} \
9.9999999999999993e-89
-test util-16.1.17.-87 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-87 {8.4 compatible formatting of doubles} precision \
{expr 1e-87} \
1e-87
-test util-16.1.17.-86 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-86 {8.4 compatible formatting of doubles} precision \
{expr 1e-86} \
1.0000000000000001e-86
-test util-16.1.17.-85 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-85 {8.4 compatible formatting of doubles} precision \
{expr 1e-85} \
9.9999999999999998e-86
-test util-16.1.17.-84 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-84 {8.4 compatible formatting of doubles} precision \
{expr 1e-84} \
1e-84
-test util-16.1.17.-83 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-83 {8.4 compatible formatting of doubles} precision \
{expr 1e-83} \
1e-83
-test util-16.1.17.-82 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-82 {8.4 compatible formatting of doubles} precision \
{expr 1e-82} \
9.9999999999999996e-83
-test util-16.1.17.-81 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-81 {8.4 compatible formatting of doubles} precision \
{expr 1e-81} \
9.9999999999999996e-82
-test util-16.1.17.-80 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-80 {8.4 compatible formatting of doubles} precision \
{expr 1e-80} \
9.9999999999999996e-81
-test util-16.1.17.-79 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-79 {8.4 compatible formatting of doubles} precision \
{expr 1e-79} \
1e-79
-test util-16.1.17.-78 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-78 {8.4 compatible formatting of doubles} precision \
{expr 1e-78} \
1e-78
-test util-16.1.17.-77 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-77 {8.4 compatible formatting of doubles} precision \
{expr 1e-77} \
9.9999999999999993e-78
-test util-16.1.17.-76 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-76 {8.4 compatible formatting of doubles} precision \
{expr 1e-76} \
9.9999999999999993e-77
-test util-16.1.17.-75 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-75 {8.4 compatible formatting of doubles} precision \
{expr 1e-75} \
9.9999999999999996e-76
-test util-16.1.17.-74 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-74 {8.4 compatible formatting of doubles} precision \
{expr 1e-74} \
9.9999999999999996e-75
-test util-16.1.17.-73 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-73 {8.4 compatible formatting of doubles} precision \
{expr 1e-73} \
1e-73
-test util-16.1.17.-72 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-72 {8.4 compatible formatting of doubles} precision \
{expr 1e-72} \
9.9999999999999997e-73
-test util-16.1.17.-71 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-71 {8.4 compatible formatting of doubles} precision \
{expr 1e-71} \
9.9999999999999992e-72
-test util-16.1.17.-70 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-70 {8.4 compatible formatting of doubles} precision \
{expr 1e-70} \
1e-70
-test util-16.1.17.-69 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-69 {8.4 compatible formatting of doubles} precision \
{expr 1e-69} \
9.9999999999999996e-70
-test util-16.1.17.-68 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-68 {8.4 compatible formatting of doubles} precision \
{expr 1e-68} \
1.0000000000000001e-68
-test util-16.1.17.-67 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-67 {8.4 compatible formatting of doubles} precision \
{expr 1e-67} \
9.9999999999999994e-68
-test util-16.1.17.-66 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-66 {8.4 compatible formatting of doubles} precision \
{expr 1e-66} \
9.9999999999999998e-67
-test util-16.1.17.-65 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-65 {8.4 compatible formatting of doubles} precision \
{expr 1e-65} \
9.9999999999999992e-66
-test util-16.1.17.-64 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-64 {8.4 compatible formatting of doubles} precision \
{expr 1e-64} \
9.9999999999999997e-65
-test util-16.1.17.-63 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-63 {8.4 compatible formatting of doubles} precision \
{expr 1e-63} \
1.0000000000000001e-63
-test util-16.1.17.-62 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-62 {8.4 compatible formatting of doubles} precision \
{expr 1e-62} \
1e-62
-test util-16.1.17.-61 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-61 {8.4 compatible formatting of doubles} precision \
{expr 1e-61} \
1e-61
-test util-16.1.17.-60 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-60 {8.4 compatible formatting of doubles} precision \
{expr 1e-60} \
9.9999999999999997e-61
-test util-16.1.17.-59 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-59 {8.4 compatible formatting of doubles} precision \
{expr 1e-59} \
1e-59
-test util-16.1.17.-58 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-58 {8.4 compatible formatting of doubles} precision \
{expr 1e-58} \
1e-58
-test util-16.1.17.-57 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-57 {8.4 compatible formatting of doubles} precision \
{expr 1e-57} \
9.9999999999999995e-58
-test util-16.1.17.-56 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-56 {8.4 compatible formatting of doubles} precision \
{expr 1e-56} \
1e-56
-test util-16.1.17.-55 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-55 {8.4 compatible formatting of doubles} precision \
{expr 1e-55} \
9.9999999999999999e-56
-test util-16.1.17.-54 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-54 {8.4 compatible formatting of doubles} precision \
{expr 1e-54} \
1e-54
-test util-16.1.17.-53 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-53 {8.4 compatible formatting of doubles} precision \
{expr 1e-53} \
1e-53
-test util-16.1.17.-52 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-52 {8.4 compatible formatting of doubles} precision \
{expr 1e-52} \
1e-52
-test util-16.1.17.-51 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-51 {8.4 compatible formatting of doubles} precision \
{expr 1e-51} \
1e-51
-test util-16.1.17.-50 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-50 {8.4 compatible formatting of doubles} precision \
{expr 1e-50} \
1e-50
-test util-16.1.17.-49 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-49 {8.4 compatible formatting of doubles} precision \
{expr 1e-49} \
9.9999999999999994e-50
-test util-16.1.17.-48 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-48 {8.4 compatible formatting of doubles} precision \
{expr 1e-48} \
9.9999999999999997e-49
-test util-16.1.17.-47 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-47 {8.4 compatible formatting of doubles} precision \
{expr 1e-47} \
9.9999999999999997e-48
-test util-16.1.17.-46 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-46 {8.4 compatible formatting of doubles} precision \
{expr 1e-46} \
1e-46
-test util-16.1.17.-45 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-45 {8.4 compatible formatting of doubles} precision \
{expr 1e-45} \
9.9999999999999998e-46
-test util-16.1.17.-44 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-44 {8.4 compatible formatting of doubles} precision \
{expr 1e-44} \
9.9999999999999995e-45
-test util-16.1.17.-43 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-43 {8.4 compatible formatting of doubles} precision \
{expr 1e-43} \
1.0000000000000001e-43
-test util-16.1.17.-42 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-42 {8.4 compatible formatting of doubles} precision \
{expr 1e-42} \
1e-42
-test util-16.1.17.-41 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-41 {8.4 compatible formatting of doubles} precision \
{expr 1e-41} \
1e-41
-test util-16.1.17.-40 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-40 {8.4 compatible formatting of doubles} precision \
{expr 1e-40} \
9.9999999999999993e-41
-test util-16.1.17.-39 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-39 {8.4 compatible formatting of doubles} precision \
{expr 1e-39} \
9.9999999999999993e-40
-test util-16.1.17.-38 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-38 {8.4 compatible formatting of doubles} precision \
{expr 1e-38} \
9.9999999999999996e-39
-test util-16.1.17.-37 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-37 {8.4 compatible formatting of doubles} precision \
{expr 1e-37} \
1.0000000000000001e-37
-test util-16.1.17.-36 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-36 {8.4 compatible formatting of doubles} precision \
{expr 1e-36} \
9.9999999999999994e-37
-test util-16.1.17.-35 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-35 {8.4 compatible formatting of doubles} precision \
{expr 1e-35} \
1e-35
-test util-16.1.17.-34 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-34 {8.4 compatible formatting of doubles} precision \
{expr 1e-34} \
9.9999999999999993e-35
-test util-16.1.17.-33 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-33 {8.4 compatible formatting of doubles} precision \
{expr 1e-33} \
1.0000000000000001e-33
-test util-16.1.17.-32 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-32 {8.4 compatible formatting of doubles} precision \
{expr 1e-32} \
1.0000000000000001e-32
-test util-16.1.17.-31 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-31 {8.4 compatible formatting of doubles} precision \
{expr 1e-31} \
1.0000000000000001e-31
-test util-16.1.17.-30 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-30 {8.4 compatible formatting of doubles} precision \
{expr 1e-30} \
1.0000000000000001e-30
-test util-16.1.17.-29 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-29 {8.4 compatible formatting of doubles} precision \
{expr 1e-29} \
9.9999999999999994e-30
-test util-16.1.17.-28 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-28 {8.4 compatible formatting of doubles} precision \
{expr 1e-28} \
9.9999999999999997e-29
-test util-16.1.17.-27 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-27 {8.4 compatible formatting of doubles} precision \
{expr 1e-27} \
1e-27
-test util-16.1.17.-26 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-26 {8.4 compatible formatting of doubles} precision \
{expr 1e-26} \
1e-26
-test util-16.1.17.-25 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-25 {8.4 compatible formatting of doubles} precision \
{expr 1e-25} \
1e-25
-test util-16.1.17.-24 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-24 {8.4 compatible formatting of doubles} precision \
{expr 1e-24} \
9.9999999999999992e-25
-test util-16.1.17.-23 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-23 {8.4 compatible formatting of doubles} precision \
{expr 1e-23} \
9.9999999999999996e-24
-test util-16.1.17.-22 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-22 {8.4 compatible formatting of doubles} precision \
{expr 1e-22} \
1e-22
-test util-16.1.17.-21 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-21 {8.4 compatible formatting of doubles} precision \
{expr 1e-21} \
9.9999999999999991e-22
-test util-16.1.17.-20 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-20 {8.4 compatible formatting of doubles} precision \
{expr 1e-20} \
9.9999999999999995e-21
-test util-16.1.17.-19 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-19 {8.4 compatible formatting of doubles} precision \
{expr 1e-19} \
9.9999999999999998e-20
-test util-16.1.17.-18 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-18 {8.4 compatible formatting of doubles} precision \
{expr 1e-18} \
1.0000000000000001e-18
-test util-16.1.17.-17 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-17 {8.4 compatible formatting of doubles} precision \
{expr 1e-17} \
1.0000000000000001e-17
-test util-16.1.17.-16 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-16 {8.4 compatible formatting of doubles} precision \
{expr 1e-16} \
9.9999999999999998e-17
-test util-16.1.17.-15 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-15 {8.4 compatible formatting of doubles} precision \
{expr 1e-15} \
1.0000000000000001e-15
-test util-16.1.17.-14 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-14 {8.4 compatible formatting of doubles} precision \
{expr 1e-14} \
1e-14
-test util-16.1.17.-13 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-13 {8.4 compatible formatting of doubles} precision \
{expr 1e-13} \
1e-13
-test util-16.1.17.-12 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-12 {8.4 compatible formatting of doubles} precision \
{expr 1e-12} \
9.9999999999999998e-13
-test util-16.1.17.-11 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-11 {8.4 compatible formatting of doubles} precision \
{expr 1e-11} \
9.9999999999999994e-12
-test util-16.1.17.-10 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-10 {8.4 compatible formatting of doubles} precision \
{expr 1e-10} \
1e-10
-test util-16.1.17.-9 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-9 {8.4 compatible formatting of doubles} precision \
{expr 1e-9} \
1.0000000000000001e-09
-test util-16.1.17.-8 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-8 {8.4 compatible formatting of doubles} precision \
{expr 1e-8} \
1e-08
-test util-16.1.17.-7 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-7 {8.4 compatible formatting of doubles} precision \
{expr 1e-7} \
9.9999999999999995e-08
-test util-16.1.17.-6 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-6 {8.4 compatible formatting of doubles} precision \
{expr 1e-6} \
9.9999999999999995e-07
-test util-16.1.17.-5 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-5 {8.4 compatible formatting of doubles} precision \
{expr 1e-5} \
1.0000000000000001e-05
-test util-16.1.17.-4 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-4 {8.4 compatible formatting of doubles} precision \
{expr 1e-4} \
0.0001
-test util-16.1.17.-3 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-3 {8.4 compatible formatting of doubles} precision \
{expr 1e-3} \
0.001
-test util-16.1.17.-2 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-2 {8.4 compatible formatting of doubles} precision \
{expr 1e-2} \
0.01
-test util-16.1.17.-1 {8.4 compatible formatting of doubles} \
+test util-16.1.17.-1 {8.4 compatible formatting of doubles} precision \
{expr 1e-1} \
0.10000000000000001
-test util-16.1.17.0 {8.4 compatible formatting of doubles} \
+test util-16.1.17.0 {8.4 compatible formatting of doubles} precision \
{expr 1e0} \
1.0
-test util-16.1.17.1 {8.4 compatible formatting of doubles} \
+test util-16.1.17.1 {8.4 compatible formatting of doubles} precision \
{expr 1e1} \
10.0
-test util-16.1.17.2 {8.4 compatible formatting of doubles} \
+test util-16.1.17.2 {8.4 compatible formatting of doubles} precision \
{expr 1e2} \
100.0
-test util-16.1.17.3 {8.4 compatible formatting of doubles} \
+test util-16.1.17.3 {8.4 compatible formatting of doubles} precision \
{expr 1e3} \
1000.0
-test util-16.1.17.4 {8.4 compatible formatting of doubles} \
+test util-16.1.17.4 {8.4 compatible formatting of doubles} precision \
{expr 1e4} \
10000.0
-test util-16.1.17.5 {8.4 compatible formatting of doubles} \
+test util-16.1.17.5 {8.4 compatible formatting of doubles} precision \
{expr 1e5} \
100000.0
-test util-16.1.17.6 {8.4 compatible formatting of doubles} \
+test util-16.1.17.6 {8.4 compatible formatting of doubles} precision \
{expr 1e6} \
1000000.0
-test util-16.1.17.7 {8.4 compatible formatting of doubles} \
+test util-16.1.17.7 {8.4 compatible formatting of doubles} precision \
{expr 1e7} \
10000000.0
-test util-16.1.17.8 {8.4 compatible formatting of doubles} \
+test util-16.1.17.8 {8.4 compatible formatting of doubles} precision \
{expr 1e8} \
100000000.0
-test util-16.1.17.9 {8.4 compatible formatting of doubles} \
+test util-16.1.17.9 {8.4 compatible formatting of doubles} precision \
{expr 1e9} \
1000000000.0
-test util-16.1.17.10 {8.4 compatible formatting of doubles} \
+test util-16.1.17.10 {8.4 compatible formatting of doubles} precision \
{expr 1e10} \
10000000000.0
-test util-16.1.17.11 {8.4 compatible formatting of doubles} \
+test util-16.1.17.11 {8.4 compatible formatting of doubles} precision \
{expr 1e11} \
100000000000.0
-test util-16.1.17.12 {8.4 compatible formatting of doubles} \
+test util-16.1.17.12 {8.4 compatible formatting of doubles} precision \
{expr 1e12} \
1000000000000.0
-test util-16.1.17.13 {8.4 compatible formatting of doubles} \
+test util-16.1.17.13 {8.4 compatible formatting of doubles} precision \
{expr 1e13} \
10000000000000.0
-test util-16.1.17.14 {8.4 compatible formatting of doubles} \
+test util-16.1.17.14 {8.4 compatible formatting of doubles} precision \
{expr 1e14} \
100000000000000.0
-test util-16.1.17.15 {8.4 compatible formatting of doubles} \
+test util-16.1.17.15 {8.4 compatible formatting of doubles} precision \
{expr 1e15} \
1000000000000000.0
-test util-16.1.17.16 {8.4 compatible formatting of doubles} \
+test util-16.1.17.16 {8.4 compatible formatting of doubles} precision \
{expr 1e16} \
10000000000000000.0
-test util-16.1.17.17 {8.4 compatible formatting of doubles} \
+test util-16.1.17.17 {8.4 compatible formatting of doubles} precision \
{expr 1e17} \
1e+17
-test util-16.1.17.18 {8.4 compatible formatting of doubles} \
+test util-16.1.17.18 {8.4 compatible formatting of doubles} precision \
{expr 1e18} \
1e+18
-test util-16.1.17.19 {8.4 compatible formatting of doubles} \
+test util-16.1.17.19 {8.4 compatible formatting of doubles} precision \
{expr 1e19} \
1e+19
-test util-16.1.17.20 {8.4 compatible formatting of doubles} \
+test util-16.1.17.20 {8.4 compatible formatting of doubles} precision \
{expr 1e20} \
1e+20
-test util-16.1.17.21 {8.4 compatible formatting of doubles} \
+test util-16.1.17.21 {8.4 compatible formatting of doubles} precision \
{expr 1e21} \
1e+21
-test util-16.1.17.22 {8.4 compatible formatting of doubles} \
+test util-16.1.17.22 {8.4 compatible formatting of doubles} precision \
{expr 1e22} \
1e+22
-test util-16.1.17.23 {8.4 compatible formatting of doubles} \
+test util-16.1.17.23 {8.4 compatible formatting of doubles} precision \
{expr 1e23} \
9.9999999999999992e+22
-test util-16.1.17.24 {8.4 compatible formatting of doubles} \
+test util-16.1.17.24 {8.4 compatible formatting of doubles} precision \
{expr 1e24} \
9.9999999999999998e+23
-test util-16.1.17.25 {8.4 compatible formatting of doubles} \
+test util-16.1.17.25 {8.4 compatible formatting of doubles} precision \
{expr 1e25} \
1.0000000000000001e+25
-test util-16.1.17.26 {8.4 compatible formatting of doubles} \
+test util-16.1.17.26 {8.4 compatible formatting of doubles} precision \
{expr 1e26} \
1e+26
-test util-16.1.17.27 {8.4 compatible formatting of doubles} \
+test util-16.1.17.27 {8.4 compatible formatting of doubles} precision \
{expr 1e27} \
1e+27
-test util-16.1.17.28 {8.4 compatible formatting of doubles} \
+test util-16.1.17.28 {8.4 compatible formatting of doubles} precision \
{expr 1e28} \
9.9999999999999996e+27
-test util-16.1.17.29 {8.4 compatible formatting of doubles} \
+test util-16.1.17.29 {8.4 compatible formatting of doubles} precision \
{expr 1e29} \
9.9999999999999991e+28
-test util-16.1.17.30 {8.4 compatible formatting of doubles} \
+test util-16.1.17.30 {8.4 compatible formatting of doubles} precision \
{expr 1e30} \
1e+30
-test util-16.1.17.31 {8.4 compatible formatting of doubles} \
+test util-16.1.17.31 {8.4 compatible formatting of doubles} precision \
{expr 1e31} \
9.9999999999999996e+30
-test util-16.1.17.32 {8.4 compatible formatting of doubles} \
+test util-16.1.17.32 {8.4 compatible formatting of doubles} precision \
{expr 1e32} \
1.0000000000000001e+32
-test util-16.1.17.33 {8.4 compatible formatting of doubles} \
+test util-16.1.17.33 {8.4 compatible formatting of doubles} precision \
{expr 1e33} \
9.9999999999999995e+32
-test util-16.1.17.34 {8.4 compatible formatting of doubles} \
+test util-16.1.17.34 {8.4 compatible formatting of doubles} precision \
{expr 1e34} \
9.9999999999999995e+33
-test util-16.1.17.35 {8.4 compatible formatting of doubles} \
+test util-16.1.17.35 {8.4 compatible formatting of doubles} precision \
{expr 1e35} \
9.9999999999999997e+34
-test util-16.1.17.36 {8.4 compatible formatting of doubles} \
+test util-16.1.17.36 {8.4 compatible formatting of doubles} precision \
{expr 1e36} \
1e+36
-test util-16.1.17.37 {8.4 compatible formatting of doubles} \
+test util-16.1.17.37 {8.4 compatible formatting of doubles} precision \
{expr 1e37} \
9.9999999999999995e+36
-test util-16.1.17.38 {8.4 compatible formatting of doubles} \
+test util-16.1.17.38 {8.4 compatible formatting of doubles} precision \
{expr 1e38} \
9.9999999999999998e+37
-test util-16.1.17.39 {8.4 compatible formatting of doubles} \
+test util-16.1.17.39 {8.4 compatible formatting of doubles} precision \
{expr 1e39} \
9.9999999999999994e+38
-test util-16.1.17.40 {8.4 compatible formatting of doubles} \
+test util-16.1.17.40 {8.4 compatible formatting of doubles} precision \
{expr 1e40} \
1e+40
-test util-16.1.17.41 {8.4 compatible formatting of doubles} \
+test util-16.1.17.41 {8.4 compatible formatting of doubles} precision \
{expr 1e41} \
1e+41
-test util-16.1.17.42 {8.4 compatible formatting of doubles} \
+test util-16.1.17.42 {8.4 compatible formatting of doubles} precision \
{expr 1e42} \
1e+42
-test util-16.1.17.43 {8.4 compatible formatting of doubles} \
+test util-16.1.17.43 {8.4 compatible formatting of doubles} precision \
{expr 1e43} \
1e+43
-test util-16.1.17.44 {8.4 compatible formatting of doubles} \
+test util-16.1.17.44 {8.4 compatible formatting of doubles} precision \
{expr 1e44} \
1.0000000000000001e+44
-test util-16.1.17.45 {8.4 compatible formatting of doubles} \
+test util-16.1.17.45 {8.4 compatible formatting of doubles} precision \
{expr 1e45} \
9.9999999999999993e+44
-test util-16.1.17.46 {8.4 compatible formatting of doubles} \
+test util-16.1.17.46 {8.4 compatible formatting of doubles} precision \
{expr 1e46} \
9.9999999999999999e+45
-test util-16.1.17.47 {8.4 compatible formatting of doubles} \
+test util-16.1.17.47 {8.4 compatible formatting of doubles} precision \
{expr 1e47} \
1e+47
-test util-16.1.17.48 {8.4 compatible formatting of doubles} \
+test util-16.1.17.48 {8.4 compatible formatting of doubles} precision \
{expr 1e48} \
1e+48
-test util-16.1.17.49 {8.4 compatible formatting of doubles} \
+test util-16.1.17.49 {8.4 compatible formatting of doubles} precision \
{expr 1e49} \
9.9999999999999995e+48
-test util-16.1.17.50 {8.4 compatible formatting of doubles} \
+test util-16.1.17.50 {8.4 compatible formatting of doubles} precision \
{expr 1e50} \
1.0000000000000001e+50
-test util-16.1.17.51 {8.4 compatible formatting of doubles} \
+test util-16.1.17.51 {8.4 compatible formatting of doubles} precision \
{expr 1e51} \
9.9999999999999999e+50
-test util-16.1.17.52 {8.4 compatible formatting of doubles} \
+test util-16.1.17.52 {8.4 compatible formatting of doubles} precision \
{expr 1e52} \
9.9999999999999999e+51
-test util-16.1.17.53 {8.4 compatible formatting of doubles} \
+test util-16.1.17.53 {8.4 compatible formatting of doubles} precision \
{expr 1e53} \
9.9999999999999999e+52
-test util-16.1.17.54 {8.4 compatible formatting of doubles} \
+test util-16.1.17.54 {8.4 compatible formatting of doubles} precision \
{expr 1e54} \
1.0000000000000001e+54
-test util-16.1.17.55 {8.4 compatible formatting of doubles} \
+test util-16.1.17.55 {8.4 compatible formatting of doubles} precision \
{expr 1e55} \
1e+55
-test util-16.1.17.56 {8.4 compatible formatting of doubles} \
+test util-16.1.17.56 {8.4 compatible formatting of doubles} precision \
{expr 1e56} \
1.0000000000000001e+56
-test util-16.1.17.57 {8.4 compatible formatting of doubles} \
+test util-16.1.17.57 {8.4 compatible formatting of doubles} precision \
{expr 1e57} \
1e+57
-test util-16.1.17.58 {8.4 compatible formatting of doubles} \
+test util-16.1.17.58 {8.4 compatible formatting of doubles} precision \
{expr 1e58} \
9.9999999999999994e+57
-test util-16.1.17.59 {8.4 compatible formatting of doubles} \
+test util-16.1.17.59 {8.4 compatible formatting of doubles} precision \
{expr 1e59} \
9.9999999999999997e+58
-test util-16.1.17.60 {8.4 compatible formatting of doubles} \
+test util-16.1.17.60 {8.4 compatible formatting of doubles} precision \
{expr 1e60} \
9.9999999999999995e+59
-test util-16.1.17.61 {8.4 compatible formatting of doubles} \
+test util-16.1.17.61 {8.4 compatible formatting of doubles} precision \
{expr 1e61} \
9.9999999999999995e+60
-test util-16.1.17.62 {8.4 compatible formatting of doubles} \
+test util-16.1.17.62 {8.4 compatible formatting of doubles} precision \
{expr 1e62} \
1e+62
-test util-16.1.17.63 {8.4 compatible formatting of doubles} \
+test util-16.1.17.63 {8.4 compatible formatting of doubles} precision \
{expr 1e63} \
1.0000000000000001e+63
-test util-16.1.17.64 {8.4 compatible formatting of doubles} \
+test util-16.1.17.64 {8.4 compatible formatting of doubles} precision \
{expr 1e64} \
1e+64
-test util-16.1.17.65 {8.4 compatible formatting of doubles} \
+test util-16.1.17.65 {8.4 compatible formatting of doubles} precision \
{expr 1e65} \
9.9999999999999999e+64
-test util-16.1.17.66 {8.4 compatible formatting of doubles} \
+test util-16.1.17.66 {8.4 compatible formatting of doubles} precision \
{expr 1e66} \
9.9999999999999995e+65
-test util-16.1.17.67 {8.4 compatible formatting of doubles} \
+test util-16.1.17.67 {8.4 compatible formatting of doubles} precision \
{expr 1e67} \
9.9999999999999998e+66
-test util-16.1.17.68 {8.4 compatible formatting of doubles} \
+test util-16.1.17.68 {8.4 compatible formatting of doubles} precision \
{expr 1e68} \
9.9999999999999995e+67
-test util-16.1.17.69 {8.4 compatible formatting of doubles} \
+test util-16.1.17.69 {8.4 compatible formatting of doubles} precision \
{expr 1e69} \
1.0000000000000001e+69
-test util-16.1.17.70 {8.4 compatible formatting of doubles} \
+test util-16.1.17.70 {8.4 compatible formatting of doubles} precision \
{expr 1e70} \
1.0000000000000001e+70
-test util-16.1.17.71 {8.4 compatible formatting of doubles} \
+test util-16.1.17.71 {8.4 compatible formatting of doubles} precision \
{expr 1e71} \
1e+71
-test util-16.1.17.72 {8.4 compatible formatting of doubles} \
+test util-16.1.17.72 {8.4 compatible formatting of doubles} precision \
{expr 1e72} \
9.9999999999999994e+71
-test util-16.1.17.73 {8.4 compatible formatting of doubles} \
+test util-16.1.17.73 {8.4 compatible formatting of doubles} precision \
{expr 1e73} \
9.9999999999999998e+72
-test util-16.1.17.74 {8.4 compatible formatting of doubles} \
+test util-16.1.17.74 {8.4 compatible formatting of doubles} precision \
{expr 1e74} \
9.9999999999999995e+73
-test util-16.1.17.75 {8.4 compatible formatting of doubles} \
+test util-16.1.17.75 {8.4 compatible formatting of doubles} precision \
{expr 1e75} \
9.9999999999999993e+74
-test util-16.1.17.76 {8.4 compatible formatting of doubles} \
+test util-16.1.17.76 {8.4 compatible formatting of doubles} precision \
{expr 1e76} \
1e+76
-test util-16.1.17.77 {8.4 compatible formatting of doubles} \
+test util-16.1.17.77 {8.4 compatible formatting of doubles} precision \
{expr 1e77} \
9.9999999999999998e+76
-test util-16.1.17.78 {8.4 compatible formatting of doubles} \
+test util-16.1.17.78 {8.4 compatible formatting of doubles} precision \
{expr 1e78} \
1e+78
-test util-16.1.17.79 {8.4 compatible formatting of doubles} \
+test util-16.1.17.79 {8.4 compatible formatting of doubles} precision \
{expr 1e79} \
9.9999999999999997e+78
-test util-16.1.17.80 {8.4 compatible formatting of doubles} \
+test util-16.1.17.80 {8.4 compatible formatting of doubles} precision \
{expr 1e80} \
1e+80
-test util-16.1.17.81 {8.4 compatible formatting of doubles} \
+test util-16.1.17.81 {8.4 compatible formatting of doubles} precision \
{expr 1e81} \
9.9999999999999992e+80
-test util-16.1.17.82 {8.4 compatible formatting of doubles} \
+test util-16.1.17.82 {8.4 compatible formatting of doubles} precision \
{expr 1e82} \
9.9999999999999996e+81
-test util-16.1.17.83 {8.4 compatible formatting of doubles} \
+test util-16.1.17.83 {8.4 compatible formatting of doubles} precision \
{expr 1e83} \
1e+83
-test util-16.1.17.84 {8.4 compatible formatting of doubles} \
+test util-16.1.17.84 {8.4 compatible formatting of doubles} precision \
{expr 1e84} \
1.0000000000000001e+84
-test util-16.1.17.85 {8.4 compatible formatting of doubles} \
+test util-16.1.17.85 {8.4 compatible formatting of doubles} precision \
{expr 1e85} \
1e+85
-test util-16.1.17.86 {8.4 compatible formatting of doubles} \
+test util-16.1.17.86 {8.4 compatible formatting of doubles} precision \
{expr 1e86} \
1e+86
-test util-16.1.17.87 {8.4 compatible formatting of doubles} \
+test util-16.1.17.87 {8.4 compatible formatting of doubles} precision \
{expr 1e87} \
9.9999999999999996e+86
-test util-16.1.17.88 {8.4 compatible formatting of doubles} \
+test util-16.1.17.88 {8.4 compatible formatting of doubles} precision \
{expr 1e88} \
9.9999999999999996e+87
-test util-16.1.17.89 {8.4 compatible formatting of doubles} \
+test util-16.1.17.89 {8.4 compatible formatting of doubles} precision \
{expr 1e89} \
9.9999999999999999e+88
-test util-16.1.17.90 {8.4 compatible formatting of doubles} \
+test util-16.1.17.90 {8.4 compatible formatting of doubles} precision \
{expr 1e90} \
9.9999999999999997e+89
-test util-16.1.17.91 {8.4 compatible formatting of doubles} \
+test util-16.1.17.91 {8.4 compatible formatting of doubles} precision \
{expr 1e91} \
1.0000000000000001e+91
-test util-16.1.17.92 {8.4 compatible formatting of doubles} \
+test util-16.1.17.92 {8.4 compatible formatting of doubles} precision \
{expr 1e92} \
1e+92
-test util-16.1.17.93 {8.4 compatible formatting of doubles} \
+test util-16.1.17.93 {8.4 compatible formatting of doubles} precision \
{expr 1e93} \
1e+93
-test util-16.1.17.94 {8.4 compatible formatting of doubles} \
+test util-16.1.17.94 {8.4 compatible formatting of doubles} precision \
{expr 1e94} \
1e+94
-test util-16.1.17.95 {8.4 compatible formatting of doubles} \
+test util-16.1.17.95 {8.4 compatible formatting of doubles} precision \
{expr 1e95} \
1e+95
-test util-16.1.17.96 {8.4 compatible formatting of doubles} \
+test util-16.1.17.96 {8.4 compatible formatting of doubles} precision \
{expr 1e96} \
1e+96
-test util-16.1.17.97 {8.4 compatible formatting of doubles} \
+test util-16.1.17.97 {8.4 compatible formatting of doubles} precision \
{expr 1e97} \
1.0000000000000001e+97
-test util-16.1.17.98 {8.4 compatible formatting of doubles} \
+test util-16.1.17.98 {8.4 compatible formatting of doubles} precision \
{expr 1e98} \
1e+98
-test util-16.1.17.99 {8.4 compatible formatting of doubles} \
+test util-16.1.17.99 {8.4 compatible formatting of doubles} precision \
{expr 1e99} \
9.9999999999999997e+98
-test util-16.1.17.100 {8.4 compatible formatting of doubles} \
+test util-16.1.17.100 {8.4 compatible formatting of doubles} precision \
{expr 1e100} \
1e+100
-test util-16.1.17.101 {8.4 compatible formatting of doubles} \
+test util-16.1.17.101 {8.4 compatible formatting of doubles} precision \
{expr 1e101} \
9.9999999999999998e+100
-test util-16.1.17.102 {8.4 compatible formatting of doubles} \
+test util-16.1.17.102 {8.4 compatible formatting of doubles} precision \
{expr 1e102} \
9.9999999999999998e+101
-test util-16.1.17.103 {8.4 compatible formatting of doubles} \
+test util-16.1.17.103 {8.4 compatible formatting of doubles} precision \
{expr 1e103} \
1e+103
-test util-16.1.17.104 {8.4 compatible formatting of doubles} \
+test util-16.1.17.104 {8.4 compatible formatting of doubles} precision \
{expr 1e104} \
1e+104
-test util-16.1.17.105 {8.4 compatible formatting of doubles} \
+test util-16.1.17.105 {8.4 compatible formatting of doubles} precision \
{expr 1e105} \
9.9999999999999994e+104
-test util-16.1.17.106 {8.4 compatible formatting of doubles} \
+test util-16.1.17.106 {8.4 compatible formatting of doubles} precision \
{expr 1e106} \
1.0000000000000001e+106
-test util-16.1.17.107 {8.4 compatible formatting of doubles} \
+test util-16.1.17.107 {8.4 compatible formatting of doubles} precision \
{expr 1e107} \
9.9999999999999997e+106
-test util-16.1.17.108 {8.4 compatible formatting of doubles} \
+test util-16.1.17.108 {8.4 compatible formatting of doubles} precision \
{expr 1e108} \
1e+108
-test util-16.1.17.109 {8.4 compatible formatting of doubles} \
+test util-16.1.17.109 {8.4 compatible formatting of doubles} precision \
{expr 1e109} \
9.9999999999999998e+108
-test util-16.1.17.110 {8.4 compatible formatting of doubles} \
+test util-16.1.17.110 {8.4 compatible formatting of doubles} precision \
{expr 1e110} \
1e+110
-test util-16.1.17.111 {8.4 compatible formatting of doubles} \
+test util-16.1.17.111 {8.4 compatible formatting of doubles} precision \
{expr 1e111} \
9.9999999999999996e+110
-test util-16.1.17.112 {8.4 compatible formatting of doubles} \
+test util-16.1.17.112 {8.4 compatible formatting of doubles} precision \
{expr 1e112} \
9.9999999999999993e+111
-test util-16.1.17.113 {8.4 compatible formatting of doubles} \
+test util-16.1.17.113 {8.4 compatible formatting of doubles} precision \
{expr 1e113} \
1e+113
-test util-16.1.17.114 {8.4 compatible formatting of doubles} \
+test util-16.1.17.114 {8.4 compatible formatting of doubles} precision \
{expr 1e114} \
1e+114
-test util-16.1.17.115 {8.4 compatible formatting of doubles} \
+test util-16.1.17.115 {8.4 compatible formatting of doubles} precision \
{expr 1e115} \
1e+115
-test util-16.1.17.116 {8.4 compatible formatting of doubles} \
+test util-16.1.17.116 {8.4 compatible formatting of doubles} precision \
{expr 1e116} \
1e+116
-test util-16.1.17.117 {8.4 compatible formatting of doubles} \
+test util-16.1.17.117 {8.4 compatible formatting of doubles} precision \
{expr 1e117} \
1.0000000000000001e+117
-test util-16.1.17.118 {8.4 compatible formatting of doubles} \
+test util-16.1.17.118 {8.4 compatible formatting of doubles} precision \
{expr 1e118} \
9.9999999999999997e+117
-test util-16.1.17.119 {8.4 compatible formatting of doubles} \
+test util-16.1.17.119 {8.4 compatible formatting of doubles} precision \
{expr 1e119} \
9.9999999999999994e+118
-test util-16.1.17.120 {8.4 compatible formatting of doubles} \
+test util-16.1.17.120 {8.4 compatible formatting of doubles} precision \
{expr 1e120} \
9.9999999999999998e+119
-test util-16.1.17.121 {8.4 compatible formatting of doubles} \
+test util-16.1.17.121 {8.4 compatible formatting of doubles} precision \
{expr 1e121} \
1e+121
-test util-16.1.17.122 {8.4 compatible formatting of doubles} \
+test util-16.1.17.122 {8.4 compatible formatting of doubles} precision \
{expr 1e122} \
1e+122
-test util-16.1.17.123 {8.4 compatible formatting of doubles} \
+test util-16.1.17.123 {8.4 compatible formatting of doubles} precision \
{expr 1e123} \
9.9999999999999998e+122
-test util-16.1.17.124 {8.4 compatible formatting of doubles} \
+test util-16.1.17.124 {8.4 compatible formatting of doubles} precision \
{expr 1e124} \
9.9999999999999995e+123
-test util-16.1.17.125 {8.4 compatible formatting of doubles} \
+test util-16.1.17.125 {8.4 compatible formatting of doubles} precision \
{expr 1e125} \
9.9999999999999992e+124
-test util-16.1.17.126 {8.4 compatible formatting of doubles} \
+test util-16.1.17.126 {8.4 compatible formatting of doubles} precision \
{expr 1e126} \
9.9999999999999992e+125
-test util-16.1.17.127 {8.4 compatible formatting of doubles} \
+test util-16.1.17.127 {8.4 compatible formatting of doubles} precision \
{expr 1e127} \
9.9999999999999995e+126
-test util-16.1.17.128 {8.4 compatible formatting of doubles} \
+test util-16.1.17.128 {8.4 compatible formatting of doubles} precision \
{expr 1e128} \
1.0000000000000001e+128
-test util-16.1.17.129 {8.4 compatible formatting of doubles} \
+test util-16.1.17.129 {8.4 compatible formatting of doubles} precision \
{expr 1e129} \
1e+129
-test util-16.1.17.130 {8.4 compatible formatting of doubles} \
+test util-16.1.17.130 {8.4 compatible formatting of doubles} precision \
{expr 1e130} \
1.0000000000000001e+130
-test util-16.1.17.131 {8.4 compatible formatting of doubles} \
+test util-16.1.17.131 {8.4 compatible formatting of doubles} precision \
{expr 1e131} \
9.9999999999999991e+130
-test util-16.1.17.132 {8.4 compatible formatting of doubles} \
+test util-16.1.17.132 {8.4 compatible formatting of doubles} precision \
{expr 1e132} \
9.9999999999999999e+131
-test util-16.1.17.133 {8.4 compatible formatting of doubles} \
+test util-16.1.17.133 {8.4 compatible formatting of doubles} precision \
{expr 1e133} \
1e+133
-test util-16.1.17.134 {8.4 compatible formatting of doubles} \
+test util-16.1.17.134 {8.4 compatible formatting of doubles} precision \
{expr 1e134} \
9.9999999999999992e+133
-test util-16.1.17.135 {8.4 compatible formatting of doubles} \
+test util-16.1.17.135 {8.4 compatible formatting of doubles} precision \
{expr 1e135} \
9.9999999999999996e+134
-test util-16.1.17.136 {8.4 compatible formatting of doubles} \
+test util-16.1.17.136 {8.4 compatible formatting of doubles} precision \
{expr 1e136} \
1.0000000000000001e+136
-test util-16.1.17.137 {8.4 compatible formatting of doubles} \
+test util-16.1.17.137 {8.4 compatible formatting of doubles} precision \
{expr 1e137} \
1e+137
-test util-16.1.17.138 {8.4 compatible formatting of doubles} \
+test util-16.1.17.138 {8.4 compatible formatting of doubles} precision \
{expr 1e138} \
1e+138
-test util-16.1.17.139 {8.4 compatible formatting of doubles} \
+test util-16.1.17.139 {8.4 compatible formatting of doubles} precision \
{expr 1e139} \
1e+139
-test util-16.1.17.140 {8.4 compatible formatting of doubles} \
+test util-16.1.17.140 {8.4 compatible formatting of doubles} precision \
{expr 1e140} \
1.0000000000000001e+140
-test util-16.1.17.141 {8.4 compatible formatting of doubles} \
+test util-16.1.17.141 {8.4 compatible formatting of doubles} precision \
{expr 1e141} \
1e+141
-test util-16.1.17.142 {8.4 compatible formatting of doubles} \
+test util-16.1.17.142 {8.4 compatible formatting of doubles} precision \
{expr 1e142} \
1.0000000000000001e+142
-test util-16.1.17.143 {8.4 compatible formatting of doubles} \
+test util-16.1.17.143 {8.4 compatible formatting of doubles} precision \
{expr 1e143} \
1e+143
-test util-16.1.17.144 {8.4 compatible formatting of doubles} \
+test util-16.1.17.144 {8.4 compatible formatting of doubles} precision \
{expr 1e144} \
1e+144
-test util-16.1.17.145 {8.4 compatible formatting of doubles} \
+test util-16.1.17.145 {8.4 compatible formatting of doubles} precision \
{expr 1e145} \
9.9999999999999999e+144
-test util-16.1.17.146 {8.4 compatible formatting of doubles} \
+test util-16.1.17.146 {8.4 compatible formatting of doubles} precision \
{expr 1e146} \
9.9999999999999993e+145
-test util-16.1.17.147 {8.4 compatible formatting of doubles} \
+test util-16.1.17.147 {8.4 compatible formatting of doubles} precision \
{expr 1e147} \
9.9999999999999998e+146
-test util-16.1.17.148 {8.4 compatible formatting of doubles} \
+test util-16.1.17.148 {8.4 compatible formatting of doubles} precision \
{expr 1e148} \
1e+148
-test util-16.1.17.149 {8.4 compatible formatting of doubles} \
+test util-16.1.17.149 {8.4 compatible formatting of doubles} precision \
{expr 1e149} \
1e+149
-test util-16.1.17.150 {8.4 compatible formatting of doubles} \
+test util-16.1.17.150 {8.4 compatible formatting of doubles} precision \
{expr 1e150} \
9.9999999999999998e+149
-test util-16.1.17.151 {8.4 compatible formatting of doubles} \
+test util-16.1.17.151 {8.4 compatible formatting of doubles} precision \
{expr 1e151} \
1e+151
-test util-16.1.17.152 {8.4 compatible formatting of doubles} \
+test util-16.1.17.152 {8.4 compatible formatting of doubles} precision \
{expr 1e152} \
1e+152
-test util-16.1.17.153 {8.4 compatible formatting of doubles} \
+test util-16.1.17.153 {8.4 compatible formatting of doubles} precision \
{expr 1e153} \
1e+153
-test util-16.1.17.154 {8.4 compatible formatting of doubles} \
+test util-16.1.17.154 {8.4 compatible formatting of doubles} precision \
{expr 1e154} \
1e+154
-test util-16.1.17.155 {8.4 compatible formatting of doubles} \
+test util-16.1.17.155 {8.4 compatible formatting of doubles} precision \
{expr 1e155} \
1e+155
-test util-16.1.17.156 {8.4 compatible formatting of doubles} \
+test util-16.1.17.156 {8.4 compatible formatting of doubles} precision \
{expr 1e156} \
9.9999999999999998e+155
-test util-16.1.17.157 {8.4 compatible formatting of doubles} \
+test util-16.1.17.157 {8.4 compatible formatting of doubles} precision \
{expr 1e157} \
9.9999999999999998e+156
-test util-16.1.17.158 {8.4 compatible formatting of doubles} \
+test util-16.1.17.158 {8.4 compatible formatting of doubles} precision \
{expr 1e158} \
9.9999999999999995e+157
-test util-16.1.17.159 {8.4 compatible formatting of doubles} \
+test util-16.1.17.159 {8.4 compatible formatting of doubles} precision \
{expr 1e159} \
9.9999999999999993e+158
-test util-16.1.17.160 {8.4 compatible formatting of doubles} \
+test util-16.1.17.160 {8.4 compatible formatting of doubles} precision \
{expr 1e160} \
1e+160
-test util-16.1.17.161 {8.4 compatible formatting of doubles} \
+test util-16.1.17.161 {8.4 compatible formatting of doubles} precision \
{expr 1e161} \
1e+161
-test util-16.1.17.162 {8.4 compatible formatting of doubles} \
+test util-16.1.17.162 {8.4 compatible formatting of doubles} precision \
{expr 1e162} \
9.9999999999999994e+161
-test util-16.1.17.163 {8.4 compatible formatting of doubles} \
+test util-16.1.17.163 {8.4 compatible formatting of doubles} precision \
{expr 1e163} \
9.9999999999999994e+162
-test util-16.1.17.164 {8.4 compatible formatting of doubles} \
+test util-16.1.17.164 {8.4 compatible formatting of doubles} precision \
{expr 1e164} \
1e+164
-test util-16.1.17.165 {8.4 compatible formatting of doubles} \
+test util-16.1.17.165 {8.4 compatible formatting of doubles} precision \
{expr 1e165} \
9.999999999999999e+164
-test util-16.1.17.166 {8.4 compatible formatting of doubles} \
+test util-16.1.17.166 {8.4 compatible formatting of doubles} precision \
{expr 1e166} \
9.9999999999999994e+165
-test util-16.1.17.167 {8.4 compatible formatting of doubles} \
+test util-16.1.17.167 {8.4 compatible formatting of doubles} precision \
{expr 1e167} \
1e+167
-test util-16.1.17.168 {8.4 compatible formatting of doubles} \
+test util-16.1.17.168 {8.4 compatible formatting of doubles} precision \
{expr 1e168} \
9.9999999999999993e+167
-test util-16.1.17.169 {8.4 compatible formatting of doubles} \
+test util-16.1.17.169 {8.4 compatible formatting of doubles} precision \
{expr 1e169} \
9.9999999999999993e+168
-test util-16.1.17.170 {8.4 compatible formatting of doubles} \
+test util-16.1.17.170 {8.4 compatible formatting of doubles} precision \
{expr 1e170} \
1e+170
-test util-16.1.17.171 {8.4 compatible formatting of doubles} \
+test util-16.1.17.171 {8.4 compatible formatting of doubles} precision \
{expr 1e171} \
9.9999999999999995e+170
-test util-16.1.17.172 {8.4 compatible formatting of doubles} \
+test util-16.1.17.172 {8.4 compatible formatting of doubles} precision \
{expr 1e172} \
1.0000000000000001e+172
-test util-16.1.17.173 {8.4 compatible formatting of doubles} \
+test util-16.1.17.173 {8.4 compatible formatting of doubles} precision \
{expr 1e173} \
1e+173
-test util-16.1.17.174 {8.4 compatible formatting of doubles} \
+test util-16.1.17.174 {8.4 compatible formatting of doubles} precision \
{expr 1e174} \
1.0000000000000001e+174
-test util-16.1.17.175 {8.4 compatible formatting of doubles} \
+test util-16.1.17.175 {8.4 compatible formatting of doubles} precision \
{expr 1e175} \
9.9999999999999994e+174
-test util-16.1.17.176 {8.4 compatible formatting of doubles} \
+test util-16.1.17.176 {8.4 compatible formatting of doubles} precision \
{expr 1e176} \
1e+176
-test util-16.1.17.177 {8.4 compatible formatting of doubles} \
+test util-16.1.17.177 {8.4 compatible formatting of doubles} precision \
{expr 1e177} \
1e+177
-test util-16.1.17.178 {8.4 compatible formatting of doubles} \
+test util-16.1.17.178 {8.4 compatible formatting of doubles} precision \
{expr 1e178} \
1.0000000000000001e+178
-test util-16.1.17.179 {8.4 compatible formatting of doubles} \
+test util-16.1.17.179 {8.4 compatible formatting of doubles} precision \
{expr 1e179} \
9.9999999999999998e+178
-test util-16.1.17.180 {8.4 compatible formatting of doubles} \
+test util-16.1.17.180 {8.4 compatible formatting of doubles} precision \
{expr 1e180} \
1e+180
-test util-16.1.17.181 {8.4 compatible formatting of doubles} \
+test util-16.1.17.181 {8.4 compatible formatting of doubles} precision \
{expr 1e181} \
9.9999999999999992e+180
-test util-16.1.17.182 {8.4 compatible formatting of doubles} \
+test util-16.1.17.182 {8.4 compatible formatting of doubles} precision \
{expr 1e182} \
1.0000000000000001e+182
-test util-16.1.17.183 {8.4 compatible formatting of doubles} \
+test util-16.1.17.183 {8.4 compatible formatting of doubles} precision \
{expr 1e183} \
9.9999999999999995e+182
-test util-16.1.17.184 {8.4 compatible formatting of doubles} \
+test util-16.1.17.184 {8.4 compatible formatting of doubles} precision \
{expr 1e184} \
1e+184
-test util-16.1.17.185 {8.4 compatible formatting of doubles} \
+test util-16.1.17.185 {8.4 compatible formatting of doubles} precision \
{expr 1e185} \
9.9999999999999998e+184
-test util-16.1.17.186 {8.4 compatible formatting of doubles} \
+test util-16.1.17.186 {8.4 compatible formatting of doubles} precision \
{expr 1e186} \
9.9999999999999998e+185
-test util-16.1.17.187 {8.4 compatible formatting of doubles} \
+test util-16.1.17.187 {8.4 compatible formatting of doubles} precision \
{expr 1e187} \
9.9999999999999991e+186
-test util-16.1.17.188 {8.4 compatible formatting of doubles} \
+test util-16.1.17.188 {8.4 compatible formatting of doubles} precision \
{expr 1e188} \
1e+188
-test util-16.1.17.189 {8.4 compatible formatting of doubles} \
+test util-16.1.17.189 {8.4 compatible formatting of doubles} precision \
{expr 1e189} \
1e+189
-test util-16.1.17.190 {8.4 compatible formatting of doubles} \
+test util-16.1.17.190 {8.4 compatible formatting of doubles} precision \
{expr 1e190} \
1.0000000000000001e+190
-test util-16.1.17.191 {8.4 compatible formatting of doubles} \
+test util-16.1.17.191 {8.4 compatible formatting of doubles} precision \
{expr 1e191} \
1.0000000000000001e+191
-test util-16.1.17.192 {8.4 compatible formatting of doubles} \
+test util-16.1.17.192 {8.4 compatible formatting of doubles} precision \
{expr 1e192} \
1e+192
-test util-16.1.17.193 {8.4 compatible formatting of doubles} \
+test util-16.1.17.193 {8.4 compatible formatting of doubles} precision \
{expr 1e193} \
1.0000000000000001e+193
-test util-16.1.17.194 {8.4 compatible formatting of doubles} \
+test util-16.1.17.194 {8.4 compatible formatting of doubles} precision \
{expr 1e194} \
9.9999999999999994e+193
-test util-16.1.17.195 {8.4 compatible formatting of doubles} \
+test util-16.1.17.195 {8.4 compatible formatting of doubles} precision \
{expr 1e195} \
9.9999999999999998e+194
-test util-16.1.17.196 {8.4 compatible formatting of doubles} \
+test util-16.1.17.196 {8.4 compatible formatting of doubles} precision \
{expr 1e196} \
9.9999999999999995e+195
-test util-16.1.17.197 {8.4 compatible formatting of doubles} \
+test util-16.1.17.197 {8.4 compatible formatting of doubles} precision \
{expr 1e197} \
9.9999999999999995e+196
-test util-16.1.17.198 {8.4 compatible formatting of doubles} \
+test util-16.1.17.198 {8.4 compatible formatting of doubles} precision \
{expr 1e198} \
1e+198
-test util-16.1.17.199 {8.4 compatible formatting of doubles} \
+test util-16.1.17.199 {8.4 compatible formatting of doubles} precision \
{expr 1e199} \
1.0000000000000001e+199
-test util-16.1.17.200 {8.4 compatible formatting of doubles} \
+test util-16.1.17.200 {8.4 compatible formatting of doubles} precision \
{expr 1e200} \
9.9999999999999997e+199
-test util-16.1.17.201 {8.4 compatible formatting of doubles} \
+test util-16.1.17.201 {8.4 compatible formatting of doubles} precision \
{expr 1e201} \
1e+201
-test util-16.1.17.202 {8.4 compatible formatting of doubles} \
+test util-16.1.17.202 {8.4 compatible formatting of doubles} precision \
{expr 1e202} \
9.999999999999999e+201
-test util-16.1.17.203 {8.4 compatible formatting of doubles} \
+test util-16.1.17.203 {8.4 compatible formatting of doubles} precision \
{expr 1e203} \
9.9999999999999999e+202
-test util-16.1.17.204 {8.4 compatible formatting of doubles} \
+test util-16.1.17.204 {8.4 compatible formatting of doubles} precision \
{expr 1e204} \
9.9999999999999999e+203
-test util-16.1.17.205 {8.4 compatible formatting of doubles} \
+test util-16.1.17.205 {8.4 compatible formatting of doubles} precision \
{expr 1e205} \
1e+205
-test util-16.1.17.206 {8.4 compatible formatting of doubles} \
+test util-16.1.17.206 {8.4 compatible formatting of doubles} precision \
{expr 1e206} \
1e+206
-test util-16.1.17.207 {8.4 compatible formatting of doubles} \
+test util-16.1.17.207 {8.4 compatible formatting of doubles} precision \
{expr 1e207} \
1e+207
-test util-16.1.17.208 {8.4 compatible formatting of doubles} \
+test util-16.1.17.208 {8.4 compatible formatting of doubles} precision \
{expr 1e208} \
9.9999999999999998e+207
-test util-16.1.17.209 {8.4 compatible formatting of doubles} \
+test util-16.1.17.209 {8.4 compatible formatting of doubles} precision \
{expr 1e209} \
1.0000000000000001e+209
-test util-16.1.17.210 {8.4 compatible formatting of doubles} \
+test util-16.1.17.210 {8.4 compatible formatting of doubles} precision \
{expr 1e210} \
9.9999999999999993e+209
-test util-16.1.17.211 {8.4 compatible formatting of doubles} \
+test util-16.1.17.211 {8.4 compatible formatting of doubles} precision \
{expr 1e211} \
9.9999999999999996e+210
-test util-16.1.17.212 {8.4 compatible formatting of doubles} \
+test util-16.1.17.212 {8.4 compatible formatting of doubles} precision \
{expr 1e212} \
9.9999999999999991e+211
-test util-16.1.17.213 {8.4 compatible formatting of doubles} \
+test util-16.1.17.213 {8.4 compatible formatting of doubles} precision \
{expr 1e213} \
9.9999999999999998e+212
-test util-16.1.17.214 {8.4 compatible formatting of doubles} \
+test util-16.1.17.214 {8.4 compatible formatting of doubles} precision \
{expr 1e214} \
9.9999999999999995e+213
-test util-16.1.17.215 {8.4 compatible formatting of doubles} \
+test util-16.1.17.215 {8.4 compatible formatting of doubles} precision \
{expr 1e215} \
9.9999999999999991e+214
-test util-16.1.17.216 {8.4 compatible formatting of doubles} \
+test util-16.1.17.216 {8.4 compatible formatting of doubles} precision \
{expr 1e216} \
1e+216
-test util-16.1.17.217 {8.4 compatible formatting of doubles} \
+test util-16.1.17.217 {8.4 compatible formatting of doubles} precision \
{expr 1e217} \
9.9999999999999996e+216
-test util-16.1.17.218 {8.4 compatible formatting of doubles} \
+test util-16.1.17.218 {8.4 compatible formatting of doubles} precision \
{expr 1e218} \
1.0000000000000001e+218
-test util-16.1.17.219 {8.4 compatible formatting of doubles} \
+test util-16.1.17.219 {8.4 compatible formatting of doubles} precision \
{expr 1e219} \
9.9999999999999997e+218
-test util-16.1.17.220 {8.4 compatible formatting of doubles} \
+test util-16.1.17.220 {8.4 compatible formatting of doubles} precision \
{expr 1e220} \
1e+220
-test util-16.1.17.221 {8.4 compatible formatting of doubles} \
+test util-16.1.17.221 {8.4 compatible formatting of doubles} precision \
{expr 1e221} \
1e+221
-test util-16.1.17.222 {8.4 compatible formatting of doubles} \
+test util-16.1.17.222 {8.4 compatible formatting of doubles} precision \
{expr 1e222} \
1e+222
-test util-16.1.17.223 {8.4 compatible formatting of doubles} \
+test util-16.1.17.223 {8.4 compatible formatting of doubles} precision \
{expr 1e223} \
1e+223
-test util-16.1.17.224 {8.4 compatible formatting of doubles} \
+test util-16.1.17.224 {8.4 compatible formatting of doubles} precision \
{expr 1e224} \
9.9999999999999997e+223
-test util-16.1.17.225 {8.4 compatible formatting of doubles} \
+test util-16.1.17.225 {8.4 compatible formatting of doubles} precision \
{expr 1e225} \
9.9999999999999993e+224
-test util-16.1.17.226 {8.4 compatible formatting of doubles} \
+test util-16.1.17.226 {8.4 compatible formatting of doubles} precision \
{expr 1e226} \
9.9999999999999996e+225
-test util-16.1.17.227 {8.4 compatible formatting of doubles} \
+test util-16.1.17.227 {8.4 compatible formatting of doubles} precision \
{expr 1e227} \
1.0000000000000001e+227
-test util-16.1.17.228 {8.4 compatible formatting of doubles} \
+test util-16.1.17.228 {8.4 compatible formatting of doubles} precision \
{expr 1e228} \
9.9999999999999992e+227
-test util-16.1.17.229 {8.4 compatible formatting of doubles} \
+test util-16.1.17.229 {8.4 compatible formatting of doubles} precision \
{expr 1e229} \
9.9999999999999999e+228
-test util-16.1.17.230 {8.4 compatible formatting of doubles} \
+test util-16.1.17.230 {8.4 compatible formatting of doubles} precision \
{expr 1e230} \
1.0000000000000001e+230
-test util-16.1.17.231 {8.4 compatible formatting of doubles} \
+test util-16.1.17.231 {8.4 compatible formatting of doubles} precision \
{expr 1e231} \
1.0000000000000001e+231
-test util-16.1.17.232 {8.4 compatible formatting of doubles} \
+test util-16.1.17.232 {8.4 compatible formatting of doubles} precision \
{expr 1e232} \
1.0000000000000001e+232
-test util-16.1.17.233 {8.4 compatible formatting of doubles} \
+test util-16.1.17.233 {8.4 compatible formatting of doubles} precision \
{expr 1e233} \
9.9999999999999997e+232
-test util-16.1.17.234 {8.4 compatible formatting of doubles} \
+test util-16.1.17.234 {8.4 compatible formatting of doubles} precision \
{expr 1e234} \
1e+234
-test util-16.1.17.235 {8.4 compatible formatting of doubles} \
+test util-16.1.17.235 {8.4 compatible formatting of doubles} precision \
{expr 1e235} \
1.0000000000000001e+235
-test util-16.1.17.236 {8.4 compatible formatting of doubles} \
+test util-16.1.17.236 {8.4 compatible formatting of doubles} precision \
{expr 1e236} \
1.0000000000000001e+236
-test util-16.1.17.237 {8.4 compatible formatting of doubles} \
+test util-16.1.17.237 {8.4 compatible formatting of doubles} precision \
{expr 1e237} \
9.9999999999999994e+236
-test util-16.1.17.238 {8.4 compatible formatting of doubles} \
+test util-16.1.17.238 {8.4 compatible formatting of doubles} precision \
{expr 1e238} \
1e+238
-test util-16.1.17.239 {8.4 compatible formatting of doubles} \
+test util-16.1.17.239 {8.4 compatible formatting of doubles} precision \
{expr 1e239} \
9.9999999999999999e+238
-test util-16.1.17.240 {8.4 compatible formatting of doubles} \
+test util-16.1.17.240 {8.4 compatible formatting of doubles} precision \
{expr 1e240} \
1e+240
-test util-16.1.17.241 {8.4 compatible formatting of doubles} \
+test util-16.1.17.241 {8.4 compatible formatting of doubles} precision \
{expr 1e241} \
1.0000000000000001e+241
-test util-16.1.17.242 {8.4 compatible formatting of doubles} \
+test util-16.1.17.242 {8.4 compatible formatting of doubles} precision \
{expr 1e242} \
1.0000000000000001e+242
-test util-16.1.17.243 {8.4 compatible formatting of doubles} \
+test util-16.1.17.243 {8.4 compatible formatting of doubles} precision \
{expr 1e243} \
1.0000000000000001e+243
-test util-16.1.17.244 {8.4 compatible formatting of doubles} \
+test util-16.1.17.244 {8.4 compatible formatting of doubles} precision \
{expr 1e244} \
1.0000000000000001e+244
-test util-16.1.17.245 {8.4 compatible formatting of doubles} \
+test util-16.1.17.245 {8.4 compatible formatting of doubles} precision \
{expr 1e245} \
1e+245
-test util-16.1.17.246 {8.4 compatible formatting of doubles} \
+test util-16.1.17.246 {8.4 compatible formatting of doubles} precision \
{expr 1e246} \
1.0000000000000001e+246
-test util-16.1.17.247 {8.4 compatible formatting of doubles} \
+test util-16.1.17.247 {8.4 compatible formatting of doubles} precision \
{expr 1e247} \
9.9999999999999995e+246
-test util-16.1.17.248 {8.4 compatible formatting of doubles} \
+test util-16.1.17.248 {8.4 compatible formatting of doubles} precision \
{expr 1e248} \
1e+248
-test util-16.1.17.249 {8.4 compatible formatting of doubles} \
+test util-16.1.17.249 {8.4 compatible formatting of doubles} precision \
{expr 1e249} \
9.9999999999999992e+248
-test util-16.1.17.250 {8.4 compatible formatting of doubles} \
+test util-16.1.17.250 {8.4 compatible formatting of doubles} precision \
{expr 1e250} \
9.9999999999999992e+249
-test util-16.1.17.251 {8.4 compatible formatting of doubles} \
+test util-16.1.17.251 {8.4 compatible formatting of doubles} precision \
{expr 1e251} \
1e+251
-test util-16.1.17.252 {8.4 compatible formatting of doubles} \
+test util-16.1.17.252 {8.4 compatible formatting of doubles} precision \
{expr 1e252} \
1.0000000000000001e+252
-test util-16.1.17.253 {8.4 compatible formatting of doubles} \
+test util-16.1.17.253 {8.4 compatible formatting of doubles} precision \
{expr 1e253} \
9.9999999999999994e+252
-test util-16.1.17.254 {8.4 compatible formatting of doubles} \
+test util-16.1.17.254 {8.4 compatible formatting of doubles} precision \
{expr 1e254} \
9.9999999999999994e+253
-test util-16.1.17.255 {8.4 compatible formatting of doubles} \
+test util-16.1.17.255 {8.4 compatible formatting of doubles} precision \
{expr 1e255} \
9.9999999999999999e+254
-test util-16.1.17.256 {8.4 compatible formatting of doubles} \
+test util-16.1.17.256 {8.4 compatible formatting of doubles} precision \
{expr 1e256} \
1e+256
-test util-16.1.17.257 {8.4 compatible formatting of doubles} \
+test util-16.1.17.257 {8.4 compatible formatting of doubles} precision \
{expr 1e257} \
1e+257
-test util-16.1.17.258 {8.4 compatible formatting of doubles} \
+test util-16.1.17.258 {8.4 compatible formatting of doubles} precision \
{expr 1e258} \
1.0000000000000001e+258
-test util-16.1.17.259 {8.4 compatible formatting of doubles} \
+test util-16.1.17.259 {8.4 compatible formatting of doubles} precision \
{expr 1e259} \
9.9999999999999993e+258
-test util-16.1.17.260 {8.4 compatible formatting of doubles} \
+test util-16.1.17.260 {8.4 compatible formatting of doubles} precision \
{expr 1e260} \
1.0000000000000001e+260
-test util-16.1.17.261 {8.4 compatible formatting of doubles} \
+test util-16.1.17.261 {8.4 compatible formatting of doubles} precision \
{expr 1e261} \
9.9999999999999993e+260
-test util-16.1.17.262 {8.4 compatible formatting of doubles} \
+test util-16.1.17.262 {8.4 compatible formatting of doubles} precision \
{expr 1e262} \
1e+262
-test util-16.1.17.263 {8.4 compatible formatting of doubles} \
+test util-16.1.17.263 {8.4 compatible formatting of doubles} precision \
{expr 1e263} \
1e+263
-test util-16.1.17.264 {8.4 compatible formatting of doubles} \
+test util-16.1.17.264 {8.4 compatible formatting of doubles} precision \
{expr 1e264} \
1e+264
-test util-16.1.17.265 {8.4 compatible formatting of doubles} \
+test util-16.1.17.265 {8.4 compatible formatting of doubles} precision \
{expr 1e265} \
1.0000000000000001e+265
-test util-16.1.17.266 {8.4 compatible formatting of doubles} \
+test util-16.1.17.266 {8.4 compatible formatting of doubles} precision \
{expr 1e266} \
1e+266
-test util-16.1.17.267 {8.4 compatible formatting of doubles} \
+test util-16.1.17.267 {8.4 compatible formatting of doubles} precision \
{expr 1e267} \
9.9999999999999997e+266
-test util-16.1.17.268 {8.4 compatible formatting of doubles} \
+test util-16.1.17.268 {8.4 compatible formatting of doubles} precision \
{expr 1e268} \
9.9999999999999997e+267
-test util-16.1.17.269 {8.4 compatible formatting of doubles} \
+test util-16.1.17.269 {8.4 compatible formatting of doubles} precision \
{expr 1e269} \
1e+269
-test util-16.1.17.270 {8.4 compatible formatting of doubles} \
+test util-16.1.17.270 {8.4 compatible formatting of doubles} precision \
{expr 1e270} \
1e+270
-test util-16.1.17.271 {8.4 compatible formatting of doubles} \
+test util-16.1.17.271 {8.4 compatible formatting of doubles} precision \
{expr 1e271} \
9.9999999999999995e+270
-test util-16.1.17.272 {8.4 compatible formatting of doubles} \
+test util-16.1.17.272 {8.4 compatible formatting of doubles} precision \
{expr 1e272} \
1.0000000000000001e+272
-test util-16.1.17.273 {8.4 compatible formatting of doubles} \
+test util-16.1.17.273 {8.4 compatible formatting of doubles} precision \
{expr 1e273} \
9.9999999999999995e+272
-test util-16.1.17.274 {8.4 compatible formatting of doubles} \
+test util-16.1.17.274 {8.4 compatible formatting of doubles} precision \
{expr 1e274} \
9.9999999999999992e+273
-test util-16.1.17.275 {8.4 compatible formatting of doubles} \
+test util-16.1.17.275 {8.4 compatible formatting of doubles} precision \
{expr 1e275} \
9.9999999999999996e+274
-test util-16.1.17.276 {8.4 compatible formatting of doubles} \
+test util-16.1.17.276 {8.4 compatible formatting of doubles} precision \
{expr 1e276} \
1.0000000000000001e+276
-test util-16.1.17.277 {8.4 compatible formatting of doubles} \
+test util-16.1.17.277 {8.4 compatible formatting of doubles} precision \
{expr 1e277} \
1e+277
-test util-16.1.17.278 {8.4 compatible formatting of doubles} \
+test util-16.1.17.278 {8.4 compatible formatting of doubles} precision \
{expr 1e278} \
9.9999999999999996e+277
-test util-16.1.17.279 {8.4 compatible formatting of doubles} \
+test util-16.1.17.279 {8.4 compatible formatting of doubles} precision \
{expr 1e279} \
1.0000000000000001e+279
-test util-16.1.17.280 {8.4 compatible formatting of doubles} \
+test util-16.1.17.280 {8.4 compatible formatting of doubles} precision \
{expr 1e280} \
1e+280
-test util-16.1.17.281 {8.4 compatible formatting of doubles} \
+test util-16.1.17.281 {8.4 compatible formatting of doubles} precision \
{expr 1e281} \
1e+281
-test util-16.1.17.282 {8.4 compatible formatting of doubles} \
+test util-16.1.17.282 {8.4 compatible formatting of doubles} precision \
{expr 1e282} \
1e+282
-test util-16.1.17.283 {8.4 compatible formatting of doubles} \
+test util-16.1.17.283 {8.4 compatible formatting of doubles} precision \
{expr 1e283} \
9.9999999999999996e+282
-test util-16.1.17.284 {8.4 compatible formatting of doubles} \
+test util-16.1.17.284 {8.4 compatible formatting of doubles} precision \
{expr 1e284} \
1.0000000000000001e+284
-test util-16.1.17.285 {8.4 compatible formatting of doubles} \
+test util-16.1.17.285 {8.4 compatible formatting of doubles} precision \
{expr 1e285} \
9.9999999999999998e+284
-test util-16.1.17.286 {8.4 compatible formatting of doubles} \
+test util-16.1.17.286 {8.4 compatible formatting of doubles} precision \
{expr 1e286} \
1e+286
-test util-16.1.17.287 {8.4 compatible formatting of doubles} \
+test util-16.1.17.287 {8.4 compatible formatting of doubles} precision \
{expr 1e287} \
1.0000000000000001e+287
-test util-16.1.17.288 {8.4 compatible formatting of doubles} \
+test util-16.1.17.288 {8.4 compatible formatting of doubles} precision \
{expr 1e288} \
1e+288
-test util-16.1.17.289 {8.4 compatible formatting of doubles} \
+test util-16.1.17.289 {8.4 compatible formatting of doubles} precision \
{expr 1e289} \
1.0000000000000001e+289
-test util-16.1.17.290 {8.4 compatible formatting of doubles} \
+test util-16.1.17.290 {8.4 compatible formatting of doubles} precision \
{expr 1e290} \
1.0000000000000001e+290
-test util-16.1.17.291 {8.4 compatible formatting of doubles} \
+test util-16.1.17.291 {8.4 compatible formatting of doubles} precision \
{expr 1e291} \
9.9999999999999996e+290
-test util-16.1.17.292 {8.4 compatible formatting of doubles} \
+test util-16.1.17.292 {8.4 compatible formatting of doubles} precision \
{expr 1e292} \
1e+292
-test util-16.1.17.293 {8.4 compatible formatting of doubles} \
+test util-16.1.17.293 {8.4 compatible formatting of doubles} precision \
{expr 1e293} \
9.9999999999999992e+292
-test util-16.1.17.294 {8.4 compatible formatting of doubles} \
+test util-16.1.17.294 {8.4 compatible formatting of doubles} precision \
{expr 1e294} \
1.0000000000000001e+294
-test util-16.1.17.295 {8.4 compatible formatting of doubles} \
+test util-16.1.17.295 {8.4 compatible formatting of doubles} precision \
{expr 1e295} \
9.9999999999999998e+294
-test util-16.1.17.296 {8.4 compatible formatting of doubles} \
+test util-16.1.17.296 {8.4 compatible formatting of doubles} precision \
{expr 1e296} \
9.9999999999999998e+295
-test util-16.1.17.297 {8.4 compatible formatting of doubles} \
+test util-16.1.17.297 {8.4 compatible formatting of doubles} precision \
{expr 1e297} \
1e+297
-test util-16.1.17.298 {8.4 compatible formatting of doubles} \
+test util-16.1.17.298 {8.4 compatible formatting of doubles} precision \
{expr 1e298} \
9.9999999999999996e+297
-test util-16.1.17.299 {8.4 compatible formatting of doubles} \
+test util-16.1.17.299 {8.4 compatible formatting of doubles} precision \
{expr 1e299} \
1.0000000000000001e+299
-test util-16.1.17.300 {8.4 compatible formatting of doubles} \
+test util-16.1.17.300 {8.4 compatible formatting of doubles} precision \
{expr 1e300} \
1.0000000000000001e+300
-test util-16.1.17.301 {8.4 compatible formatting of doubles} \
+test util-16.1.17.301 {8.4 compatible formatting of doubles} precision \
{expr 1e301} \
1.0000000000000001e+301
-test util-16.1.17.302 {8.4 compatible formatting of doubles} \
+test util-16.1.17.302 {8.4 compatible formatting of doubles} precision \
{expr 1e302} \
1.0000000000000001e+302
-test util-16.1.17.303 {8.4 compatible formatting of doubles} \
+test util-16.1.17.303 {8.4 compatible formatting of doubles} precision \
{expr 1e303} \
1e+303
-test util-16.1.17.304 {8.4 compatible formatting of doubles} \
+test util-16.1.17.304 {8.4 compatible formatting of doubles} precision \
{expr 1e304} \
9.9999999999999994e+303
-test util-16.1.17.305 {8.4 compatible formatting of doubles} \
+test util-16.1.17.305 {8.4 compatible formatting of doubles} precision \
{expr 1e305} \
9.9999999999999994e+304
-test util-16.1.17.306 {8.4 compatible formatting of doubles} \
+test util-16.1.17.306 {8.4 compatible formatting of doubles} precision \
{expr 1e306} \
1e+306
-test util-16.1.17.307 {8.4 compatible formatting of doubles} \
+test util-16.1.17.307 {8.4 compatible formatting of doubles} precision \
{expr 1e307} \
9.9999999999999999e+306
@@ -4127,7 +4129,9 @@ test util-18.12 {Tcl_ObjPrintf} {testprint} {
testprint "%I64d %Id" 65537
} {65537 65537}
-set ::tcl_precision $saved_precision
+if {[catch {set ::tcl_precision $saved_precision}]} {
+ unset ::tcl_precision
+}
# cleanup
::tcltest::cleanupTests
diff --git a/tools/tcltk-man2html-utils.tcl b/tools/tcltk-man2html-utils.tcl
index b69e601..5a4550b 100644
--- a/tools/tcltk-man2html-utils.tcl
+++ b/tools/tcltk-man2html-utils.tcl
@@ -149,6 +149,7 @@ proc process-text {text} {
{\(em} "&#8212;" \
{\(en} "&#8211;" \
{\(fm} "&#8242;" \
+ {\(mc} "&#181;" \
{\(mu} "&#215;" \
{\(mi} "&#8722;" \
{\(->} "<font size=\"+1\">&#8594;</font>" \
diff --git a/tools/tcltk-man2html.tcl b/tools/tcltk-man2html.tcl
index b0c2d8f..e4cf3e9 100755
--- a/tools/tcltk-man2html.tcl
+++ b/tools/tcltk-man2html.tcl
@@ -31,6 +31,38 @@ set ::CSSFILE "docs.css"
##
source [file join [file dirname [info script]] tcltk-man2html-utils.tcl]
+proc findversion {top name useversion} {
+ set upper [string toupper $name]
+ foreach top1 [list $top $top/..] sub {{} generic} {
+ foreach dirname [
+ glob -nocomplain -tails -type d -directory $top1 *] {
+
+ set tclh [join [list $top1 $dirname {*}$sub $name.h] /]
+ if {[file exists $tclh]} {
+ set chan [open $tclh]
+ set data [read $chan]
+ close $chan
+ # backslash isn't required in front of quote, but it keeps syntax
+ # highlighting straight in some editors
+ if {[regexp -lineanchor \
+ [string map [list @name@ $upper] \
+ {^#define\s+@name@_VERSION\s+\"([^.])+\.([^.\"]+)}] \
+ $data -> major minor]} {
+ # to do
+ # use glob matching instead of string matching or add
+ # brace handling to [string matcch]
+ if {$useversion eq {} || [string match $useversion $major.$minor]} {
+ set top [file dirname [file dirname $tclh]]
+ set prefix [file dirname $top]
+ return [list $prefix [file tail $top] $major $minor]
+ }
+ }
+ }
+ }
+ }
+ return
+}
+
proc parse_command_line {} {
global argv Version
@@ -44,7 +76,9 @@ proc parse_command_line {} {
set tcldir {}
set webdir ../html
set build_tcl 0
+ set opt_build_tcl 0
set build_tk 0
+ set opt_build_tk 0
set verbose 0
# Default search version is a glob pattern
set useversion {{,[8-9].[0-9]{,[.ab][0-9]{,[0-9]}}}}
@@ -93,10 +127,12 @@ proc parse_command_line {} {
--tcl {
set build_tcl 1
+ set opt_build_tcl 1
}
--tk {
set build_tk 1
+ set opt_build_tk 1
}
--verbose=* {
@@ -117,20 +153,19 @@ proc parse_command_line {} {
if {$build_tcl} {
# Find Tcl.
- set tcldir [lindex [lsort [glob -nocomplain -tails -type d \
- -directory $tcltkdir tcl$useversion]] end]
- if {$tcldir eq ""} {
+ lassign [findversion $tcltkdir tcl $useversion] tcltkdir tcldir major minor
+ if {$tcldir eq {} && $opt_build_tcl} {
puts stderr "tcltk-man-html: couldn't find Tcl below $tcltkdir"
exit 1
}
- puts "using Tcl source directory $tcldir"
+ puts "using Tcl source directory $tcltkdir $tcldir"
}
+
if {$build_tk} {
# Find Tk.
- set tkdir [lindex [lsort [glob -nocomplain -tails -type d \
- -directory $tcltkdir tk$useversion]] end]
- if {$tkdir eq ""} {
+ lassign [findversion $tcltkdir tk $useversion] tcltkdir tkdir major minor
+ if {$tkdir eq {} && $opt_build_tk} {
puts stderr "tcltk-man-html: couldn't find Tk below $tcltkdir"
exit 1
}
@@ -143,7 +178,7 @@ proc parse_command_line {} {
global overall_title
set overall_title ""
if {$build_tcl} {
- append overall_title "[capitalize $tcldir]"
+ append overall_title "Tcl $major.$minor"
}
if {$build_tcl && $build_tk} {
append overall_title "/"
diff --git a/tools/uniParse.tcl b/tools/uniParse.tcl
index c712e62..561c28e 100644
--- a/tools/uniParse.tcl
+++ b/tools/uniParse.tcl
@@ -212,7 +212,7 @@ static const unsigned short pageMap\[\] = {"
puts $f $line
set lastpage [expr {[lindex $line end] >> $shift}]
puts stdout "lastpage: $lastpage"
- puts $f "#if TCL_UTF_MAX > 3"
+ puts $f "#if TCL_UTF_MAX > 3 || TCL_MAJOR_VERSION > 8 || TCL_MINOR_VERSION > 6"
set line " ,"
}
append line [lindex $pMap $i]
@@ -242,7 +242,7 @@ static const unsigned char groupMap\[\] = {"
set lastj [expr {[llength $page] - 1}]
if {$i == ($lastpage + 1)} {
puts $f [string trimright $line " \t,"]
- puts $f "#if TCL_UTF_MAX > 3"
+ puts $f "#if TCL_UTF_MAX > 3 || TCL_MAJOR_VERSION > 8 || TCL_MINOR_VERSION > 6"
set line " ,"
}
for {set j 0} {$j <= $lastj} {incr j} {
@@ -342,7 +342,7 @@ static const int groups\[\] = {"
puts $f $line
puts -nonewline $f "};
-#if TCL_UTF_MAX > 3
+#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])
#else
# define UNICODE_OUT_OF_RANGE(ch) (((ch) & 0x1f0000) != 0)
@@ -401,7 +401,7 @@ enum {
* Unicode character tables.
*/
-#if TCL_UTF_MAX > 3
+#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))\]\])
#else
# define GetUniCharInfo(ch) (groups\[groupMap\[pageMap\[((ch) & 0xffff) >> OFFSET_BITS\] | ((ch) & ((1 << OFFSET_BITS)-1))\]\])
diff --git a/unix/Makefile.in b/unix/Makefile.in
index d769f03..74bee41 100644
--- a/unix/Makefile.in
+++ b/unix/Makefile.in
@@ -319,14 +319,14 @@ GENERIC_OBJS = regcomp.o regexec.o regfree.o regerror.o tclAlloc.o \
OO_OBJS = tclOO.o tclOOBasic.o tclOOCall.o tclOODefineCmds.o tclOOInfo.o \
tclOOMethod.o tclOOStubInit.o
-TOMMATH_OBJS = bncore.o bn_reverse.o bn_fast_s_mp_mul_digs.o \
+TOMMATH_OBJS = bn_reverse.o bn_fast_s_mp_mul_digs.o \
bn_fast_s_mp_sqr.o bn_mp_add.o bn_mp_and.o \
bn_mp_add_d.o bn_mp_clamp.o bn_mp_clear.o bn_mp_clear_multi.o \
bn_mp_cmp.o bn_mp_cmp_d.o bn_mp_cmp_mag.o \
bn_mp_cnt_lsb.o bn_mp_copy.o \
bn_mp_count_bits.o bn_mp_div.o bn_mp_div_d.o bn_mp_div_2.o \
- bn_mp_div_2d.o bn_mp_div_3.o \
- bn_mp_exch.o bn_mp_expt_d.o bn_mp_expt_d_ex.o bn_mp_get_int.o \
+ bn_mp_div_2d.o bn_mp_div_3.o bn_mp_exch.o \
+ bn_mp_expt_d.o bn_mp_expt_d_ex.o bn_mp_get_bit.o bn_mp_get_int.o \
bn_mp_get_long.o bn_mp_get_long_long.o bn_mp_grow.o bn_mp_init.o \
bn_mp_init_copy.o bn_mp_init_multi.o bn_mp_init_set.o \
bn_mp_init_set_int.o bn_mp_init_size.o bn_mp_karatsuba_mul.o \
@@ -490,7 +490,6 @@ STUB_SRCS = \
$(GENERIC_DIR)/tclOOStubLib.c
TOMMATH_SRCS = \
- $(TOMMATH_DIR)/bncore.c \
$(TOMMATH_DIR)/bn_reverse.c \
$(TOMMATH_DIR)/bn_fast_s_mp_mul_digs.c \
$(TOMMATH_DIR)/bn_fast_s_mp_sqr.c \
@@ -1460,9 +1459,6 @@ tclThreadTest.o: $(GENERIC_DIR)/tclThreadTest.c
tclTomMathInterface.o: $(GENERIC_DIR)/tclTomMathInterface.c $(MATHHDRS)
$(CC) -c $(CC_SWITCHES) $(GENERIC_DIR)/tclTomMathInterface.c
-bncore.o: $(TOMMATH_DIR)/bncore.c $(MATHHDRS)
- $(CC) -c $(CC_SWITCHES) $(TOMMATH_DIR)/bncore.c
-
bn_reverse.o: $(TOMMATH_DIR)/bn_reverse.c $(MATHHDRS)
$(CC) -c $(CC_SWITCHES) $(TOMMATH_DIR)/bn_reverse.c
@@ -1532,6 +1528,9 @@ bn_mp_expt_d.o: $(TOMMATH_DIR)/bn_mp_expt_d.c $(MATHHDRS)
bn_mp_expt_d_ex.o: $(TOMMATH_DIR)/bn_mp_expt_d_ex.c $(MATHHDRS)
$(CC) -c $(CC_SWITCHES) $(TOMMATH_DIR)/bn_mp_expt_d_ex.c
+bn_mp_get_bit.o: $(TOMMATH_DIR)/bn_mp_get_bit.c $(MATHHDRS)
+ $(CC) -c $(CC_SWITCHES) $(TOMMATH_DIR)/bn_mp_get_bit.c
+
bn_mp_get_int.o: $(TOMMATH_DIR)/bn_mp_get_int.c $(MATHHDRS)
$(CC) -c $(CC_SWITCHES) $(TOMMATH_DIR)/bn_mp_get_int.c
@@ -2292,13 +2291,10 @@ html-tk: ${NATIVE_TCLSH}
$(BUILD_HTML) --tk
@EXTRA_BUILD_HTML@
-# You'd better have these programs or you will have problems creating Makefile
-# from Makefile.in in the first place...
-HTML_VERSION = `basename $(TOP_DIR) | sed s/tcl//`
BUILD_HTML = \
@${NATIVE_TCLSH} $(TOOL_DIR)/tcltk-man2html.tcl \
- --useversion=$(HTML_VERSION) --htmldir="$(HTML_INSTALL_DIR)" \
- --srcdir=$(TOP_DIR)/.. $(BUILD_HTML_FLAGS)
+ --tcl --useversion=$(MAJOR_VERSION).$(MINOR_VERSION) --htmldir="$(HTML_INSTALL_DIR)" \
+ --srcdir=$(TOP_DIR) $(BUILD_HTML_FLAGS)
#--------------------------------------------------------------------------
# The list of all the targets that do not correspond to real files. This stops
diff --git a/unix/tclUnixChan.c b/unix/tclUnixChan.c
index 435579a..673e4cd 100644
--- a/unix/tclUnixChan.c
+++ b/unix/tclUnixChan.c
@@ -654,17 +654,15 @@ TtySetOptionProc(
*/
if ((len > 1) && (strncmp(optionName, "-xchar", len) == 0)) {
- Tcl_DString ds;
-
if (Tcl_SplitList(interp, value, &argc, &argv) == TCL_ERROR) {
return TCL_ERROR;
} else if (argc != 2) {
+ badXchar:
if (interp) {
Tcl_SetObjResult(interp, Tcl_NewStringObj(
"bad value for -xchar: should be a list of"
- " two elements", -1));
- Tcl_SetErrorCode(interp, "TCL", "OPERATION", "FCONFIGURE",
- "VALUE", NULL);
+ " two elements with each a single 8-bit character", -1));
+ Tcl_SetErrorCode(interp, "TCL", "VALUE", "XCHAR", NULL);
}
ckfree(argv);
return TCL_ERROR;
@@ -672,13 +670,23 @@ TtySetOptionProc(
tcgetattr(fsPtr->fd, &iostate);
- Tcl_UtfToExternalDString(NULL, argv[0], -1, &ds);
- iostate.c_cc[VSTART] = *(const cc_t *) Tcl_DStringValue(&ds);
- TclDStringClear(&ds);
+ iostate.c_cc[VSTART] = argv[0][0];
+ iostate.c_cc[VSTOP] = argv[1][0];
+ if (argv[0][0] & 0x80 || argv[1][0] & 0x80) {
+ Tcl_UniChar character = 0;
+ int charLen;
- Tcl_UtfToExternalDString(NULL, argv[1], -1, &ds);
- iostate.c_cc[VSTOP] = *(const cc_t *) Tcl_DStringValue(&ds);
- Tcl_DStringFree(&ds);
+ charLen = Tcl_UtfToUniChar(argv[0], &character);
+ if ((character > 0xFF) || argv[0][charLen]) {
+ goto badXchar;
+ }
+ iostate.c_cc[VSTART] = character;
+ charLen = Tcl_UtfToUniChar(argv[1], &character);
+ if ((character > 0xFF) || argv[1][charLen]) {
+ goto badXchar;
+ }
+ iostate.c_cc[VSTOP] = character;
+ }
ckfree(argv);
tcsetattr(fsPtr->fd, TCSADRAIN, &iostate);
diff --git a/unix/tclUnixFCmd.c b/unix/tclUnixFCmd.c
index 7205085..e963589 100644
--- a/unix/tclUnixFCmd.c
+++ b/unix/tclUnixFCmd.c
@@ -1499,11 +1499,11 @@ SetGroupAttribute(
Tcl_Obj *fileName, /* The name of the file (UTF-8). */
Tcl_Obj *attributePtr) /* New group for file. */
{
- long gid;
+ Tcl_WideInt gid;
int result;
const char *native;
- if (Tcl_GetLongFromObj(NULL, attributePtr, &gid) != TCL_OK) {
+ if (Tcl_GetWideIntFromObj(NULL, attributePtr, &gid) != TCL_OK) {
Tcl_DString ds;
struct group *groupPtr = NULL;
const char *string;
@@ -1565,11 +1565,11 @@ SetOwnerAttribute(
Tcl_Obj *fileName, /* The name of the file (UTF-8). */
Tcl_Obj *attributePtr) /* New owner for file. */
{
- long uid;
+ Tcl_WideInt uid;
int result;
const char *native;
- if (Tcl_GetLongFromObj(NULL, attributePtr, &uid) != TCL_OK) {
+ if (Tcl_GetWideIntFromObj(NULL, attributePtr, &uid) != TCL_OK) {
Tcl_DString ds;
struct passwd *pwPtr = NULL;
const char *string;
@@ -1631,7 +1631,7 @@ SetPermissionsAttribute(
Tcl_Obj *fileName, /* The name of the file (UTF-8). */
Tcl_Obj *attributePtr) /* The attribute to set. */
{
- long mode;
+ Tcl_WideInt mode;
mode_t newMode;
int result = TCL_ERROR;
const char *native;
@@ -1650,11 +1650,11 @@ SetPermissionsAttribute(
TclNewLiteralStringObj(modeObj, "0o");
Tcl_AppendToObj(modeObj, modeStringPtr+scanned+1, -1);
- result = Tcl_GetLongFromObj(NULL, modeObj, &mode);
+ result = Tcl_GetWideIntFromObj(NULL, modeObj, &mode);
Tcl_DecrRefCount(modeObj);
}
if (result == TCL_OK
- || Tcl_GetLongFromObj(NULL, attributePtr, &mode) == TCL_OK) {
+ || Tcl_GetWideIntFromObj(NULL, attributePtr, &mode) == TCL_OK) {
newMode = (mode_t) (mode & 0x00007FFF);
} else {
Tcl_StatBuf buf;
@@ -2340,8 +2340,8 @@ GetUnixFileAttributes(
return TCL_ERROR;
}
- *attributePtrPtr = Tcl_NewBooleanObj(
- fileAttributes & attributeArray[objIndex]);
+ *attributePtrPtr = Tcl_NewWideIntObj(
+ (fileAttributes & attributeArray[objIndex]) != 0);
return TCL_OK;
}
@@ -2440,7 +2440,7 @@ GetUnixFileAttributes(
return TCL_ERROR;
}
- *attributePtrPtr = Tcl_NewBooleanObj(statBuf.st_flags & UF_IMMUTABLE);
+ *attributePtrPtr = Tcl_NewWideIntObj((statBuf.st_flags & UF_IMMUTABLE) != 0);
return TCL_OK;
}
diff --git a/unix/tclUnixFile.c b/unix/tclUnixFile.c
index 8cb93b4..bf033d2 100644
--- a/unix/tclUnixFile.c
+++ b/unix/tclUnixFile.c
@@ -1117,7 +1117,7 @@ TclNativeCreateNativeRep(
}
Tcl_DecrRefCount(validPathPtr);
nativePathPtr = ckalloc(len);
- memcpy(nativePathPtr, Tcl_DStringValue(&ds), (size_t) len);
+ memcpy(nativePathPtr, Tcl_DStringValue(&ds), len);
Tcl_DStringFree(&ds);
return nativePathPtr;
diff --git a/unix/tclUnixSock.c b/unix/tclUnixSock.c
index bd54a2e..62e4756 100644
--- a/unix/tclUnixSock.c
+++ b/unix/tclUnixSock.c
@@ -241,7 +241,7 @@ InitializeHostName(
if (dot != NULL) {
char *node = ckalloc(dot - u.nodename + 1);
- memcpy(node, u.nodename, (size_t) (dot - u.nodename));
+ memcpy(node, u.nodename, dot - u.nodename);
node[dot - u.nodename] = '\0';
hp = TclpGetHostByName(node);
ckfree(node);
diff --git a/unix/tclUnixTime.c b/unix/tclUnixTime.c
index 6a73ac2..1d8b351 100644
--- a/unix/tclUnixTime.c
+++ b/unix/tclUnixTime.c
@@ -87,6 +87,32 @@ TclpGetSeconds(void)
/*
*----------------------------------------------------------------------
*
+ * TclpGetMicroseconds --
+ *
+ * This procedure returns the number of microseconds from the epoch.
+ * On most Unix systems the epoch is Midnight Jan 1, 1970 GMT.
+ *
+ * Results:
+ * Number of microseconds from the epoch.
+ *
+ * Side effects:
+ * None.
+ *
+ *----------------------------------------------------------------------
+ */
+
+Tcl_WideInt
+TclpGetMicroseconds(void)
+{
+ Tcl_Time time;
+
+ tclGetTimeProcPtr(&time, tclTimeClientData);
+ return ((Tcl_WideInt)time.sec)*1000000 + time.usec;
+}
+
+/*
+ *----------------------------------------------------------------------
+ *
* TclpGetClicks --
*
* This procedure returns a value that represents the highest resolution
@@ -219,6 +245,51 @@ TclpWideClicksToNanoseconds(
return nsec;
}
+
+/*
+ *----------------------------------------------------------------------
+ *
+ * TclpWideClickInMicrosec --
+ *
+ * This procedure return scale to convert click values from the
+ * TclpGetWideClicks native resolution to microsecond resolution
+ * and back.
+ *
+ * Results:
+ * 1 click in microseconds as double.
+ *
+ * Side effects:
+ * None.
+ *
+ *----------------------------------------------------------------------
+ */
+
+double
+TclpWideClickInMicrosec(void)
+{
+ if (tclGetTimeProcPtr != NativeGetTime) {
+ return 1.0;
+ } else {
+#ifdef MAC_OSX_TCL
+ static int initialized = 0;
+ static double scale = 0.0;
+
+ if (initialized) {
+ return scale;
+ } else {
+ mach_timebase_info_data_t tb;
+
+ mach_timebase_info(&tb);
+ /* value of tb.numer / tb.denom = 1 click in nanoseconds */
+ scale = ((double)tb.numer) / tb.denom / 1000;
+ initialized = 1;
+ return scale;
+ }
+#else
+#error Wide high-resolution clicks not implemented on this platform
+#endif
+ }
+}
#endif /* TCL_WIDE_CLICKS */
/*
diff --git a/win/Makefile.in b/win/Makefile.in
index f97582a..faf4b77 100644
--- a/win/Makefile.in
+++ b/win/Makefile.in
@@ -360,7 +360,6 @@ GENERIC_OBJS = \
tclZlib.$(OBJEXT)
TOMMATH_OBJS = \
- bncore.${OBJEXT} \
bn_reverse.${OBJEXT} \
bn_fast_s_mp_mul_digs.${OBJEXT} \
bn_fast_s_mp_sqr.${OBJEXT} \
@@ -384,6 +383,7 @@ TOMMATH_OBJS = \
bn_mp_exch.${OBJEXT} \
bn_mp_expt_d.${OBJEXT} \
bn_mp_expt_d_ex.${OBJEXT} \
+ bn_mp_get_bit.${OBJEXT} \
bn_mp_get_int.${OBJEXT} \
bn_mp_get_long.${OBJEXT} \
bn_mp_get_long_long.${OBJEXT} \
diff --git a/win/makefile.vc b/win/makefile.vc
index 66a9fdf..e159538 100644
--- a/win/makefile.vc
+++ b/win/makefile.vc
@@ -252,7 +252,6 @@ ZLIBOBJS = \
$(TMP_DIR)\zutil.obj
TOMMATHOBJS = \
- $(TMP_DIR)\bncore.obj \
$(TMP_DIR)\bn_reverse.obj \
$(TMP_DIR)\bn_fast_s_mp_mul_digs.obj \
$(TMP_DIR)\bn_fast_s_mp_sqr.obj \
@@ -276,6 +275,7 @@ TOMMATHOBJS = \
$(TMP_DIR)\bn_mp_exch.obj \
$(TMP_DIR)\bn_mp_expt_d.obj \
$(TMP_DIR)\bn_mp_expt_d_ex.obj \
+ $(TMP_DIR)\bn_mp_get_bit.obj \
$(TMP_DIR)\bn_mp_get_int.obj \
$(TMP_DIR)\bn_mp_get_long.obj \
$(TMP_DIR)\bn_mp_get_long_long.obj \
@@ -390,6 +390,9 @@ dlls: setup $(TCLREGLIB) $(TCLDDELIB)
all: setup $(TCLSH) $(TCLSTUBLIB) dlls pkgs
tcltest: setup $(TCLTEST) dlls
install: install-binaries install-libraries install-docs install-pkgs
+!if $(SYMBOLS)
+install: install-pdbs
+!endif
setup: default-setup
test: test-core test-pkgs
@@ -923,6 +926,11 @@ install-msgs:
@$(TCLSH_NATIVE) "$(ROOT:\=/)/tools/installData.tcl" \
"$(ROOT:\=/)/library/msgs" "$(SCRIPT_INSTALL_DIR)/msgs"
+install-pdbs:
+ @echo Installing debug symbols
+ @$(CPY) "$(OUT_DIR)\*.pdb" "$(BIN_INSTALL_DIR)\"
+# "emacs font-lock highlighting fix
+
#---------------------------------------------------------------------
# Clean up
#---------------------------------------------------------------------
diff --git a/win/nmakehlp.c b/win/nmakehlp.c
index 1655d48..c21de63 100644
--- a/win/nmakehlp.c
+++ b/win/nmakehlp.c
@@ -793,7 +793,7 @@ static int LocateDependencyHelper(const char *dir, const char *keypath)
static int LocateDependency(const char *keypath)
{
int i, ret;
- static char *paths[] = {"..", "..\\..", "..\\..\\.."};
+ static const char *paths[] = {"..", "..\\..", "..\\..\\.."};
for (i = 0; i < (sizeof(paths)/sizeof(paths[0])); ++i) {
ret = LocateDependencyHelper(paths[i], keypath);
diff --git a/win/rules.vc b/win/rules.vc
index fbcb235..1cd0b68 100644
--- a/win/rules.vc
+++ b/win/rules.vc
@@ -475,6 +475,21 @@ MACHINE = AMD64
MACHINE=$(ARCH)
!endif
+#---------------------------------------------------------------
+# The PLATFORM_IDENTIFY macro matches the values returned by
+# the Tcl platform::identify command
+!if "$(MACHINE)" == "AMD64"
+PLATFORM_IDENTIFY = win32-x86_64
+!else
+PLATFORM_IDENTIFY = win32-ix86
+!endif
+
+# The MULTIPLATFORM macro controls whether binary extensions are installed
+# in platform-specific directories. Intended to be set/used by extensions.
+!ifndef MULTIPLATFORM_INSTALL
+MULTIPLATFORM_INSTALL = 0
+!endif
+
#------------------------------------------------------------
# Figure out the *host* architecture by reading the registry
@@ -730,6 +745,8 @@ TCL_USE_STATIC_PACKAGES = 1
TCL_USE_STATIC_PACKAGES = 0
!endif
+# Yes, it's weird that the "symbols" option controls DEBUG and
+# the "pdbs" option controls SYMBOLS. That's historical.
!if [nmakehlp -f $(OPTS) "symbols"]
!message *** Doing symbols
DEBUG = 1
@@ -1205,8 +1222,13 @@ INCLUDE_INSTALL_DIR = $(_INSTALLDIR)\include
!else # extension other than Tk
PRJ_INSTALL_DIR = $(_INSTALLDIR)\$(PROJECT)$(DOTVERSION)
+!if $(MULTIPLATFORM_INSTALL)
+LIB_INSTALL_DIR = $(PRJ_INSTALL_DIR)\$(PLATFORM_IDENTIFY)
+BIN_INSTALL_DIR = $(PRJ_INSTALL_DIR)\$(PLATFORM_IDENTIFY)
+!else
LIB_INSTALL_DIR = $(PRJ_INSTALL_DIR)
BIN_INSTALL_DIR = $(PRJ_INSTALL_DIR)
+!endif
DOC_INSTALL_DIR = $(PRJ_INSTALL_DIR)
SCRIPT_INSTALL_DIR = $(PRJ_INSTALL_DIR)
DEMO_INSTALL_DIR = $(PRJ_INSTALL_DIR)\demos
@@ -1480,9 +1502,15 @@ DEFAULT_BUILD_TARGET = $(PROJECT)
default-target: $(DEFAULT_BUILD_TARGET)
+!if $(MULTIPLATFORM_INSTALL)
+default-pkgindex:
+ @echo package ifneeded $(PRJ_PACKAGE_TCLNAME) $(DOTVERSION) \
+ [list load [file join $$dir $(PLATFORM_IDENTIFY) $(PRJLIBNAME)]] > $(OUT_DIR)\pkgIndex.tcl
+!else
default-pkgindex:
@echo package ifneeded $(PRJ_PACKAGE_TCLNAME) $(DOTVERSION) \
[list load [file join $$dir $(PRJLIBNAME)]] > $(OUT_DIR)\pkgIndex.tcl
+!endif
default-pkgindex-tea:
@if exist $(ROOT)\pkgIndex.tcl.in nmakehlp -s << $(ROOT)\pkgIndex.tcl.in > $(OUT_DIR)\pkgIndex.tcl
@@ -1492,15 +1520,26 @@ default-pkgindex-tea:
@PKG_LIB_FILE@ $(PRJLIBNAME)
<<
-
default-install: default-install-binaries default-install-libraries
+!if $(SYMBOLS)
+default-install: default-install-pdbs
+!endif
+# Again to deal with historical brokenness, there is some confusion
+# in terminlogy. For extensions, the "install-binaries" was used to
+# locate target directory for *binary shared libraries* and thus
+# the appropriate macro is LIB_INSTALL_DIR since BIN_INSTALL_DIR is
+# for executables (exes). On the other hand the "install-libraries"
+# target is for *scripts* and should have been called "install-scripts".
default-install-binaries: $(PRJLIB)
- @echo Installing binaries to '$(SCRIPT_INSTALL_DIR)'
- @if not exist "$(SCRIPT_INSTALL_DIR)" mkdir "$(SCRIPT_INSTALL_DIR)"
- @$(CPY) $(PRJLIB) "$(SCRIPT_INSTALL_DIR)" >NUL
+ @echo Installing binaries to '$(LIB_INSTALL_DIR)'
+ @if not exist "$(LIB_INSTALL_DIR)" mkdir "$(LIB_INSTALL_DIR)"
+ @$(CPY) $(PRJLIB) "$(LIB_INSTALL_DIR)" >NUL
-default-install-libraries: $(OUT_DIR)\pkgIndex.tcl
+# Alias for default-install-scripts
+default-install-libraries: default-install-scripts
+
+default-install-scripts: $(OUT_DIR)\pkgIndex.tcl
@echo Installing libraries to '$(SCRIPT_INSTALL_DIR)'
@if exist $(LIBDIR) $(CPY) $(LIBDIR)\*.tcl "$(SCRIPT_INSTALL_DIR)"
@echo Installing package index in '$(SCRIPT_INSTALL_DIR)'
@@ -1511,6 +1550,11 @@ default-install-stubs:
@if not exist "$(SCRIPT_INSTALL_DIR)" mkdir "$(SCRIPT_INSTALL_DIR)"
@$(CPY) $(PRJSTUBLIB) "$(SCRIPT_INSTALL_DIR)" >NUL
+default-install-pdbs:
+ @echo Installing PDBs to '$(LIB_INSTALL_DIR)'
+ @if not exist "$(LIB_INSTALL_DIR)" mkdir "$(LIB_INSTALL_DIR)"
+ @$(CPY) "$(OUT_DIR)\*.pdb" "$(LIB_INSTALL_DIR)\"
+
default-install-docs-html:
@echo Installing documentation files to '$(DOC_INSTALL_DIR)'
@if not exist "$(DOC_INSTALL_DIR)" mkdir "$(DOC_INSTALL_DIR)"
diff --git a/win/tclWin32Dll.c b/win/tclWin32Dll.c
index ddfa0d6..36205e1 100644
--- a/win/tclWin32Dll.c
+++ b/win/tclWin32Dll.c
@@ -46,8 +46,8 @@ BOOL APIENTRY DllMain(HINSTANCE hInst, DWORD reason,
*/
typedef struct MountPointMap {
- TCHAR *volumeName; /* Native wide string volume name. */
- TCHAR driveLetter; /* Drive letter corresponding to the volume
+ WCHAR *volumeName; /* Native wide string volume name. */
+ WCHAR driveLetter; /* Drive letter corresponding to the volume
* name. */
struct MountPointMap *nextPtr;
/* Pointer to next structure in list, or
@@ -286,11 +286,11 @@ TclWinEncodingsCleanup(void)
char
TclWinDriveLetterForVolMountPoint(
- const TCHAR *mountPoint)
+ const WCHAR *mountPoint)
{
MountPointMap *dlIter, *dlPtr2;
- TCHAR Target[55]; /* Target of mount at mount point */
- TCHAR drive[4] = TEXT("A:\\");
+ WCHAR Target[55]; /* Target of mount at mount point */
+ WCHAR drive[4] = TEXT("A:\\");
/*
* Detect the volume mounted there. Unfortunately, there is no simple way
@@ -301,14 +301,14 @@ TclWinDriveLetterForVolMountPoint(
Tcl_MutexLock(&mountPointMap);
dlIter = driveLetterLookup;
while (dlIter != NULL) {
- if (_tcscmp(dlIter->volumeName, mountPoint) == 0) {
+ if (wcscmp(dlIter->volumeName, mountPoint) == 0) {
/*
* We need to check whether this information is still valid, since
* either the user or various programs could have adjusted the
* mount points on the fly.
*/
- drive[0] = (TCHAR) dlIter->driveLetter;
+ drive[0] = (WCHAR) dlIter->driveLetter;
/*
* Try to read the volume mount point and see where it points.
@@ -316,7 +316,7 @@ TclWinDriveLetterForVolMountPoint(
if (GetVolumeNameForVolumeMountPoint(drive,
Target, 55) != 0) {
- if (_tcscmp(dlIter->volumeName, Target) == 0) {
+ if (wcscmp(dlIter->volumeName, Target) == 0) {
/*
* Nothing has changed.
*/
@@ -379,7 +379,7 @@ TclWinDriveLetterForVolMountPoint(
for (dlIter = driveLetterLookup; dlIter != NULL;
dlIter = dlIter->nextPtr) {
- if (_tcscmp(dlIter->volumeName, Target) == 0) {
+ if (wcscmp(dlIter->volumeName, Target) == 0) {
alreadyStored = 1;
break;
}
@@ -400,7 +400,7 @@ TclWinDriveLetterForVolMountPoint(
for (dlIter = driveLetterLookup; dlIter != NULL;
dlIter = dlIter->nextPtr) {
- if (_tcscmp(dlIter->volumeName, mountPoint) == 0) {
+ if (wcscmp(dlIter->volumeName, mountPoint) == 0) {
Tcl_MutexUnlock(&mountPointMap);
return (char) dlIter->driveLetter;
}
@@ -447,7 +447,7 @@ TclWinDriveLetterForVolMountPoint(
* nativeBuffer <- UtfToExternal(encoding, utfBuffer);
* Tcl_FreeEncoding(encoding);
*
- * By convention, in Windows a TCHAR is a Unicode character. If you plan
+ * By convention, in Windows a WCHAR is a Unicode character. If you plan
* on targeting a Unicode interface when running on Windows, these
* functions should be used. If you plan on targetting a "char" oriented
* function on Windows, use Tcl_UtfToExternal() with an encoding of NULL.
@@ -463,7 +463,7 @@ TclWinDriveLetterForVolMountPoint(
*---------------------------------------------------------------------------
*/
-TCHAR *
+WCHAR *
Tcl_WinUtfToTChar(
const char *string, /* Source string in UTF-8. */
int len, /* Source string length in bytes, or -1 for
@@ -471,119 +471,31 @@ Tcl_WinUtfToTChar(
Tcl_DString *dsPtr) /* Uninitialized or free DString in which the
* converted string is stored. */
{
-#if TCL_UTF_MAX > 4
- Tcl_UniChar ch = 0;
- TCHAR *w, *wString;
- const char *p, *end;
- int oldLength;
-#endif
-
Tcl_DStringInit(dsPtr);
if (!string) {
return NULL;
}
-#if TCL_UTF_MAX > 4
-
- if (len < 0) {
- len = strlen(string);
- }
-
- /*
- * Unicode string length in Tcl_UniChars will be <= UTF-8 string length in
- * bytes.
- */
-
- oldLength = Tcl_DStringLength(dsPtr);
-
- Tcl_DStringSetLength(dsPtr,
- oldLength + (int) ((len + 1) * sizeof(TCHAR)));
- wString = (TCHAR *) (Tcl_DStringValue(dsPtr) + oldLength);
-
- w = wString;
- p = string;
- end = string + len - 4;
- while (p < end) {
- p += TclUtfToUniChar(p, &ch);
- if (ch > 0xFFFF) {
- *w++ = (wchar_t) (0xD800 + ((ch -= 0x10000) >> 10));
- *w++ = (wchar_t) (0xDC00 | (ch & 0x3FF));
- } else {
- *w++ = ch;
- }
- }
- end += 4;
- while (p < end) {
- if (Tcl_UtfCharComplete(p, end-p)) {
- p += TclUtfToUniChar(p, &ch);
- } else {
- ch = UCHAR(*p++);
- }
- if (ch > 0xFFFF) {
- *w++ = (wchar_t) (0xD800 + ((ch -= 0x10000) >> 10));
- *w++ = (wchar_t) (0xDC00 | (ch & 0x3FF));
- } else {
- *w++ = ch;
- }
- }
- *w = '\0';
- Tcl_DStringSetLength(dsPtr,
- oldLength + ((char *) w - (char *) wString));
-
- return wString;
-#else
- return Tcl_UtfToUniCharDString(string, len, dsPtr);
-#endif
+ return TclUtfToWCharDString(string, len, dsPtr);
}
char *
Tcl_WinTCharToUtf(
- const TCHAR *string, /* Source string in Unicode. */
+ const WCHAR *string, /* Source string in Unicode. */
int len, /* Source string length in bytes, or -1 for
* platform-specific string length. */
Tcl_DString *dsPtr) /* Uninitialized or free DString in which the
* converted string is stored. */
{
-#if TCL_UTF_MAX > 4
- const TCHAR *w, *wEnd;
- char *p, *result;
- int oldLength, blen = 1;
-#endif
-
Tcl_DStringInit(dsPtr);
if (!string) {
return NULL;
}
if (len < 0) {
- len = wcslen((TCHAR *)string);
+ len = wcslen((WCHAR *)string);
} else {
len /= 2;
}
-#if TCL_UTF_MAX > 4
- oldLength = Tcl_DStringLength(dsPtr);
- Tcl_DStringSetLength(dsPtr, oldLength + (len + 1) * 4);
- result = Tcl_DStringValue(dsPtr) + oldLength;
-
- p = result;
- wEnd = (TCHAR *)string + len;
- for (w = (TCHAR *)string; w < wEnd; ) {
- if (!blen && ((*w & 0xFC00) != 0xDC00)) {
- /* Special case for handling upper surrogates. */
- p += Tcl_UniCharToUtf(-1, p);
- }
- blen = Tcl_UniCharToUtf(*w, p);
- p += blen;
- w++;
- }
- if (!blen) {
- /* Special case for handling upper surrogates. */
- p += Tcl_UniCharToUtf(-1, p);
- }
- Tcl_DStringSetLength(dsPtr, oldLength + (p - result));
-
- return result;
-#else
- return Tcl_UniCharToUtfDString((Tcl_UniChar *)string, len, dsPtr);
-#endif
+ return TclWCharToUtfDString((unsigned short *)string, len, dsPtr);
}
/*
diff --git a/win/tclWinChan.c b/win/tclWinChan.c
index 8c47be6..dcd8528 100644
--- a/win/tclWinChan.c
+++ b/win/tclWinChan.c
@@ -96,7 +96,7 @@ static void FileThreadActionProc(ClientData instanceData,
static int FileTruncateProc(ClientData instanceData,
Tcl_WideInt length);
static DWORD FileGetType(HANDLE handle);
-static int NativeIsComPort(const TCHAR *nativeName);
+static int NativeIsComPort(const WCHAR *nativeName);
/*
* This structure describes the channel type structure for file based IO.
@@ -849,7 +849,7 @@ TclpOpenFileChannel(
Tcl_Channel channel = 0;
int channelPermissions = 0;
DWORD accessMode = 0, createMode, shareMode, flags;
- const TCHAR *nativeName;
+ const WCHAR *nativeName;
HANDLE handle;
char channelName[16 + TCL_INTEGER_SPACE];
TclFile readFile = NULL, writeFile = NULL;
@@ -1557,7 +1557,7 @@ FileGetType(
static int
NativeIsComPort(
- const TCHAR *nativePath) /* Path of file to access, native encoding. */
+ const WCHAR *nativePath) /* Path of file to access, native encoding. */
{
const WCHAR *p = (const WCHAR *) nativePath;
int i, len = wcslen(p);
diff --git a/win/tclWinConsole.c b/win/tclWinConsole.c
index f8b67a3..5f23cca 100644
--- a/win/tclWinConsole.c
+++ b/win/tclWinConsole.c
@@ -660,11 +660,11 @@ ConsoleInputProc(
*/
if (bufSize < (infoPtr->bytesRead - infoPtr->offset)) {
- memcpy(buf, &infoPtr->buffer[infoPtr->offset], (size_t) bufSize);
+ memcpy(buf, &infoPtr->buffer[infoPtr->offset], bufSize);
bytesRead = bufSize;
infoPtr->offset += bufSize;
} else {
- memcpy(buf, &infoPtr->buffer[infoPtr->offset], (size_t) bufSize);
+ memcpy(buf, &infoPtr->buffer[infoPtr->offset], bufSize);
bytesRead = infoPtr->bytesRead - infoPtr->offset;
/*
@@ -771,7 +771,7 @@ ConsoleOutputProc(
infoPtr->writeBufLen = toWrite;
infoPtr->writeBuf = ckalloc(toWrite);
}
- memcpy(infoPtr->writeBuf, buf, (size_t) toWrite);
+ memcpy(infoPtr->writeBuf, buf, toWrite);
infoPtr->toWrite = toWrite;
ResetEvent(threadInfo->readyEvent);
TclPipeThreadSignal(&threadInfo->TI);
diff --git a/win/tclWinFCmd.c b/win/tclWinFCmd.c
index c3ced34..14bb252 100644
--- a/win/tclWinFCmd.c
+++ b/win/tclWinFCmd.c
@@ -71,7 +71,7 @@ const TclFileAttrProcs tclpFileAttrProcs[] = {
* Prototype for the TraverseWinTree callback function.
*/
-typedef int (TraversalProc)(const TCHAR *srcPtr, const TCHAR *dstPtr,
+typedef int (TraversalProc)(const WCHAR *srcPtr, const WCHAR *dstPtr,
int type, Tcl_DString *errorPtr);
/*
@@ -82,18 +82,18 @@ static void StatError(Tcl_Interp *interp, Tcl_Obj *fileName);
static int ConvertFileNameFormat(Tcl_Interp *interp,
int objIndex, Tcl_Obj *fileName, int longShort,
Tcl_Obj **attributePtrPtr);
-static int DoCopyFile(const TCHAR *srcPtr, const TCHAR *dstPtr);
-static int DoCreateDirectory(const TCHAR *pathPtr);
-static int DoRemoveJustDirectory(const TCHAR *nativeSrc,
+static int DoCopyFile(const WCHAR *srcPtr, const WCHAR *dstPtr);
+static int DoCreateDirectory(const WCHAR *pathPtr);
+static int DoRemoveJustDirectory(const WCHAR *nativeSrc,
int ignoreError, Tcl_DString *errorPtr);
static int DoRemoveDirectory(Tcl_DString *pathPtr, int recursive,
Tcl_DString *errorPtr);
-static int DoRenameFile(const TCHAR *nativeSrc,
- const TCHAR *dstPtr);
-static int TraversalCopy(const TCHAR *srcPtr, const TCHAR *dstPtr,
+static int DoRenameFile(const WCHAR *nativeSrc,
+ const WCHAR *dstPtr);
+static int TraversalCopy(const WCHAR *srcPtr, const WCHAR *dstPtr,
int type, Tcl_DString *errorPtr);
-static int TraversalDelete(const TCHAR *srcPtr,
- const TCHAR *dstPtr, int type,
+static int TraversalDelete(const WCHAR *srcPtr,
+ const WCHAR *dstPtr, int type,
Tcl_DString *errorPtr);
static int TraverseWinTree(TraversalProc *traverseProc,
Tcl_DString *sourcePtr, Tcl_DString *dstPtr,
@@ -151,9 +151,9 @@ TclpObjRenameFile(
static int
DoRenameFile(
- const TCHAR *nativeSrc, /* Pathname of file or dir to be renamed
+ const WCHAR *nativeSrc, /* Pathname of file or dir to be renamed
* (native). */
- const TCHAR *nativeDst) /* New pathname for file or directory
+ const WCHAR *nativeDst) /* New pathname for file or directory
* (native). */
{
#if defined(HAVE_NO_SEH) && !defined(_WIN64)
@@ -307,11 +307,11 @@ DoRenameFile(
if (errno == EACCES) {
decode:
if (srcAttr & FILE_ATTRIBUTE_DIRECTORY) {
- TCHAR *nativeSrcRest, *nativeDstRest;
+ WCHAR *nativeSrcRest, *nativeDstRest;
const char **srcArgv, **dstArgv;
int size, srcArgc, dstArgc;
- TCHAR nativeSrcPath[MAX_PATH];
- TCHAR nativeDstPath[MAX_PATH];
+ WCHAR nativeSrcPath[MAX_PATH];
+ WCHAR nativeDstPath[MAX_PATH];
Tcl_DString srcString, dstString;
const char *src, *dst;
@@ -445,20 +445,20 @@ DoRenameFile(
* back to old name.
*/
- TCHAR *nativeRest, *nativeTmp, *nativePrefix;
+ WCHAR *nativeRest, *nativeTmp, *nativePrefix;
int result, size;
- TCHAR tempBuf[MAX_PATH];
+ WCHAR tempBuf[MAX_PATH];
size = GetFullPathName(nativeDst, MAX_PATH,
tempBuf, &nativeRest);
if ((size == 0) || (size > MAX_PATH) || (nativeRest == NULL)) {
return TCL_ERROR;
}
- nativeTmp = (TCHAR *) tempBuf;
+ nativeTmp = (WCHAR *) tempBuf;
nativeRest[0] = L'\0';
result = TCL_ERROR;
- nativePrefix = (TCHAR *) L"tclr";
+ nativePrefix = (WCHAR *) L"tclr";
if (GetTempFileName(nativeTmp, nativePrefix,
0, tempBuf) != 0) {
/*
@@ -540,8 +540,8 @@ TclpObjCopyFile(
static int
DoCopyFile(
- const TCHAR *nativeSrc, /* Pathname of file to be copied (native). */
- const TCHAR *nativeDst) /* Pathname of file to copy to (native). */
+ const WCHAR *nativeSrc, /* Pathname of file to be copied (native). */
+ const WCHAR *nativeDst) /* Pathname of file to copy to (native). */
{
#if defined(HAVE_NO_SEH) && !defined(_WIN64)
TCLEXCEPTION_REGISTRATION registration;
@@ -749,7 +749,7 @@ TclpDeleteFile(
const void *nativePath) /* Pathname of file to be removed (native). */
{
DWORD attr;
- const TCHAR *path = nativePath;
+ const WCHAR *path = nativePath;
/*
* The DeleteFile API acts differently under Win95/98 and NT WRT NULL and
@@ -859,7 +859,7 @@ TclpObjCreateDirectory(
static int
DoCreateDirectory(
- const TCHAR *nativePath) /* Pathname of directory to create (native). */
+ const WCHAR *nativePath) /* Pathname of directory to create (native). */
{
if (CreateDirectory(nativePath, NULL) == 0) {
DWORD error = GetLastError();
@@ -1009,7 +1009,7 @@ TclpObjRemoveDirectory(
static int
DoRemoveJustDirectory(
- const TCHAR *nativePath, /* Pathname of directory to be removed
+ const WCHAR *nativePath, /* Pathname of directory to be removed
* (native). */
int ignoreError, /* If non-zero, don't initialize the errorPtr
* under some circumstances on return. */
@@ -1129,7 +1129,7 @@ DoRemoveDirectory(
* filled with UTF-8 name of file causing
* error. */
{
- int res = DoRemoveJustDirectory((const TCHAR *)Tcl_DStringValue(pathPtr), recursive,
+ int res = DoRemoveJustDirectory((const WCHAR *)Tcl_DStringValue(pathPtr), recursive,
errorPtr);
if ((res == TCL_ERROR) && (recursive != 0) && (Tcl_GetErrno() == EEXIST)) {
@@ -1180,7 +1180,7 @@ TraverseWinTree(
* error. */
{
DWORD sourceAttr;
- TCHAR *nativeSource, *nativeTarget, *nativeErrfile;
+ WCHAR *nativeSource, *nativeTarget, *nativeErrfile;
int result, found, sourceLen, targetLen = 0, oldSourceLen, oldTargetLen;
HANDLE handle;
WIN32_FIND_DATA data;
@@ -1189,8 +1189,8 @@ TraverseWinTree(
result = TCL_OK;
oldTargetLen = 0; /* lint. */
- nativeSource = (TCHAR *) Tcl_DStringValue(sourcePtr);
- nativeTarget = (TCHAR *)
+ nativeSource = (WCHAR *) Tcl_DStringValue(sourcePtr);
+ nativeTarget = (WCHAR *)
(targetPtr == NULL ? NULL : Tcl_DStringValue(targetPtr));
oldSourceLen = Tcl_DStringLength(sourcePtr);
@@ -1217,10 +1217,10 @@ TraverseWinTree(
return traverseProc(nativeSource, nativeTarget, DOTREE_F, errorPtr);
}
- Tcl_DStringAppend(sourcePtr, (char *) TEXT("\\*.*"), 4 * sizeof(TCHAR) + 1);
+ Tcl_DStringAppend(sourcePtr, (char *) L"\\*.*", 4 * sizeof(WCHAR) + 1);
Tcl_DStringSetLength(sourcePtr, Tcl_DStringLength(sourcePtr) - 1);
- nativeSource = (TCHAR *) Tcl_DStringValue(sourcePtr);
+ nativeSource = (WCHAR *) Tcl_DStringValue(sourcePtr);
handle = FindFirstFile(nativeSource, &data);
if (handle == INVALID_HANDLE_VALUE) {
/*
@@ -1241,24 +1241,24 @@ TraverseWinTree(
return result;
}
- sourceLen = oldSourceLen + sizeof(TCHAR);
- Tcl_DStringAppend(sourcePtr, (char *) TEXT("\\"), sizeof(TCHAR) + 1);
+ sourceLen = oldSourceLen + sizeof(WCHAR);
+ Tcl_DStringAppend(sourcePtr, (char *) L"\\", sizeof(WCHAR) + 1);
Tcl_DStringSetLength(sourcePtr, sourceLen);
if (targetPtr != NULL) {
oldTargetLen = Tcl_DStringLength(targetPtr);
targetLen = oldTargetLen;
- targetLen += sizeof(TCHAR);
- Tcl_DStringAppend(targetPtr, (char *) TEXT("\\"), sizeof(TCHAR) + 1);
+ targetLen += sizeof(WCHAR);
+ Tcl_DStringAppend(targetPtr, (char *) L"\\", sizeof(WCHAR) + 1);
Tcl_DStringSetLength(targetPtr, targetLen);
}
found = 1;
for (; found; found = FindNextFile(handle, &data)) {
- TCHAR *nativeName;
+ WCHAR *nativeName;
int len;
- TCHAR *wp = data.cFileName;
+ WCHAR *wp = data.cFileName;
if (*wp == '.') {
wp++;
if (*wp == '.') {
@@ -1268,8 +1268,8 @@ TraverseWinTree(
continue;
}
}
- nativeName = (TCHAR *) data.cFileName;
- len = _tcslen(data.cFileName) * sizeof(TCHAR);
+ nativeName = (WCHAR *) data.cFileName;
+ len = wcslen(data.cFileName) * sizeof(WCHAR);
/*
* Append name after slash, and recurse on the file.
@@ -1314,8 +1314,8 @@ TraverseWinTree(
* files in that directory.
*/
- result = traverseProc((const TCHAR *)Tcl_DStringValue(sourcePtr),
- (const TCHAR *)(targetPtr == NULL ? NULL : Tcl_DStringValue(targetPtr)),
+ result = traverseProc((const WCHAR *)Tcl_DStringValue(sourcePtr),
+ (const WCHAR *)(targetPtr == NULL ? NULL : Tcl_DStringValue(targetPtr)),
DOTREE_POSTD, errorPtr);
}
@@ -1350,8 +1350,8 @@ TraverseWinTree(
static int
TraversalCopy(
- const TCHAR *nativeSrc, /* Source pathname to copy. */
- const TCHAR *nativeDst, /* Destination pathname of copy. */
+ const WCHAR *nativeSrc, /* Source pathname to copy. */
+ const WCHAR *nativeDst, /* Destination pathname of copy. */
int type, /* Reason for call - see TraverseWinTree() */
Tcl_DString *errorPtr) /* If non-NULL, initialized DString filled
* with UTF-8 name of file causing error. */
@@ -1416,8 +1416,8 @@ TraversalCopy(
static int
TraversalDelete(
- const TCHAR *nativeSrc, /* Source pathname to delete. */
- const TCHAR *dstPtr, /* Not used. */
+ const WCHAR *nativeSrc, /* Source pathname to delete. */
+ const WCHAR *dstPtr, /* Not used. */
int type, /* Reason for call - see TraverseWinTree() */
Tcl_DString *errorPtr) /* If non-NULL, initialized DString filled
* with UTF-8 name of file causing error. */
@@ -1503,7 +1503,7 @@ GetWinFileAttributes(
Tcl_Obj **attributePtrPtr) /* A pointer to return the object with. */
{
DWORD result;
- const TCHAR *nativeName;
+ const WCHAR *nativeName;
int attr;
nativeName = Tcl_FSGetNativePath(fileName);
@@ -1524,8 +1524,8 @@ GetWinFileAttributes(
* We test for, and fix that case, here.
*/
- const char *str = TclGetString(fileName);
- size_t len = fileName->length;
+ int len;
+ const char *str = TclGetStringFromObj(fileName, &len);
if (len < 4) {
if (len == 0) {
@@ -1549,7 +1549,7 @@ GetWinFileAttributes(
}
}
- *attributePtrPtr = Tcl_NewBooleanObj(attr);
+ *attributePtrPtr = Tcl_NewWideIntObj(attr != 0);
return TCL_OK;
}
@@ -1610,11 +1610,12 @@ ConvertFileNameFormat(
for (i = 0; i < pathc; i++) {
Tcl_Obj *elt;
char *pathv;
+ int length;
Tcl_ListObjIndex(NULL, splitPath, i, &elt);
- pathv = TclGetString(elt);
- if ((pathv[0] == '/') || ((elt->length == 3) && (pathv[1] == ':'))
+ pathv = TclGetStringFromObj(elt, &length);
+ if ((pathv[0] == '/') || ((length == 3) && (pathv[1] == ':'))
|| (strcmp(pathv, ".") == 0) || (strcmp(pathv, "..") == 0)) {
/*
* Handle "/", "//machine/export", "c:/", "." or ".." by just
@@ -1635,7 +1636,7 @@ ConvertFileNameFormat(
Tcl_Obj *tempPath;
Tcl_DString ds;
Tcl_DString dsTemp;
- const TCHAR *nativeName;
+ const WCHAR *nativeName;
const char *tempString;
WIN32_FIND_DATA data;
HANDLE handle;
@@ -1649,8 +1650,8 @@ ConvertFileNameFormat(
* likely to lead to infinite loops.
*/
- tempString = TclGetString(tempPath);
- nativeName = Tcl_WinUtfToTChar(tempString, tempPath->length, &ds);
+ tempString = TclGetStringFromObj(tempPath, &length);
+ nativeName = Tcl_WinUtfToTChar(tempString, length, &ds);
Tcl_DecrRefCount(tempPath);
handle = FindFirstFile(nativeName, &data);
if (handle == INVALID_HANDLE_VALUE) {
@@ -1682,7 +1683,7 @@ ConvertFileNameFormat(
}
} else {
if (data.cAlternateFileName[0] == '\0') {
- nativeName = (TCHAR *) data.cFileName;
+ nativeName = (WCHAR *) data.cFileName;
}
}
@@ -1828,7 +1829,7 @@ SetWinFileAttributes(
{
DWORD fileAttributes, old;
int yesNo, result;
- const TCHAR *nativeName;
+ const WCHAR *nativeName;
nativeName = Tcl_FSGetNativePath(fileName);
fileAttributes = old = GetFileAttributes(nativeName);
diff --git a/win/tclWinFile.c b/win/tclWinFile.c
index 6582ee1..3524a16 100644
--- a/win/tclWinFile.c
+++ b/win/tclWinFile.c
@@ -156,27 +156,27 @@ static void FromCTime(time_t posixTime, FILETIME *fileTime);
* Declarations for local functions defined in this file:
*/
-static int NativeAccess(const TCHAR *path, int mode);
-static int NativeDev(const TCHAR *path);
-static int NativeStat(const TCHAR *path, Tcl_StatBuf *statPtr,
+static int NativeAccess(const WCHAR *path, int mode);
+static int NativeDev(const WCHAR *path);
+static int NativeStat(const WCHAR *path, Tcl_StatBuf *statPtr,
int checkLinks);
static unsigned short NativeStatMode(DWORD attr, int checkLinks,
int isExec);
-static int NativeIsExec(const TCHAR *path);
-static int NativeReadReparse(const TCHAR *LinkDirectory,
+static int NativeIsExec(const WCHAR *path);
+static int NativeReadReparse(const WCHAR *LinkDirectory,
REPARSE_DATA_BUFFER *buffer, DWORD desiredAccess);
-static int NativeWriteReparse(const TCHAR *LinkDirectory,
+static int NativeWriteReparse(const WCHAR *LinkDirectory,
REPARSE_DATA_BUFFER *buffer);
static int NativeMatchType(int isDrive, DWORD attr,
- const TCHAR *nativeName, Tcl_GlobTypeData *types);
+ const WCHAR *nativeName, Tcl_GlobTypeData *types);
static int WinIsDrive(const char *name, size_t nameLen);
static int WinIsReserved(const char *path);
-static Tcl_Obj * WinReadLink(const TCHAR *LinkSource);
-static Tcl_Obj * WinReadLinkDirectory(const TCHAR *LinkDirectory);
-static int WinLink(const TCHAR *LinkSource,
- const TCHAR *LinkTarget, int linkAction);
-static int WinSymLinkDirectory(const TCHAR *LinkDirectory,
- const TCHAR *LinkTarget);
+static Tcl_Obj * WinReadLink(const WCHAR *LinkSource);
+static Tcl_Obj * WinReadLinkDirectory(const WCHAR *LinkDirectory);
+static int WinLink(const WCHAR *LinkSource,
+ const WCHAR *LinkTarget, int linkAction);
+static int WinSymLinkDirectory(const WCHAR *LinkDirectory,
+ const WCHAR *LinkTarget);
MODULE_SCOPE TCL_NORETURN void tclWinDebugPanic(const char *format, ...);
/*
@@ -191,12 +191,12 @@ MODULE_SCOPE TCL_NORETURN void tclWinDebugPanic(const char *format, ...);
static int
WinLink(
- const TCHAR *linkSourcePath,
- const TCHAR *linkTargetPath,
+ const WCHAR *linkSourcePath,
+ const WCHAR *linkTargetPath,
int linkAction)
{
- TCHAR tempFileName[MAX_PATH];
- TCHAR *tempFilePart;
+ WCHAR tempFileName[MAX_PATH];
+ WCHAR *tempFilePart;
DWORD attr;
/*
@@ -306,10 +306,10 @@ WinLink(
static Tcl_Obj *
WinReadLink(
- const TCHAR *linkSourcePath)
+ const WCHAR *linkSourcePath)
{
- TCHAR tempFileName[MAX_PATH];
- TCHAR *tempFilePart;
+ WCHAR tempFileName[MAX_PATH];
+ WCHAR *tempFilePart;
DWORD attr;
/*
@@ -370,8 +370,8 @@ WinReadLink(
static int
WinSymLinkDirectory(
- const TCHAR *linkDirPath,
- const TCHAR *linkTargetPath)
+ const WCHAR *linkDirPath,
+ const WCHAR *linkTargetPath)
{
DUMMY_REPARSE_BUFFER dummy;
REPARSE_DATA_BUFFER *reparseBuffer = (REPARSE_DATA_BUFFER *) &dummy;
@@ -442,8 +442,8 @@ WinSymLinkDirectory(
int
TclWinSymLinkCopyDirectory(
- const TCHAR *linkOrigPath, /* Existing junction - reparse point */
- const TCHAR *linkCopyPath) /* Will become a duplicate junction */
+ const WCHAR *linkOrigPath, /* Existing junction - reparse point */
+ const WCHAR *linkCopyPath) /* Will become a duplicate junction */
{
DUMMY_REPARSE_BUFFER dummy;
REPARSE_DATA_BUFFER *reparseBuffer = (REPARSE_DATA_BUFFER *) &dummy;
@@ -473,7 +473,7 @@ TclWinSymLinkCopyDirectory(
int
TclWinSymLinkDelete(
- const TCHAR *linkOrigPath,
+ const WCHAR *linkOrigPath,
int linkOnly)
{
/*
@@ -538,7 +538,7 @@ TclWinSymLinkDelete(
static Tcl_Obj *
WinReadLinkDirectory(
- const TCHAR *linkDirPath)
+ const WCHAR *linkDirPath)
{
int attr, len, offset;
DUMMY_REPARSE_BUFFER dummy;
@@ -634,9 +634,9 @@ WinReadLinkDirectory(
}
}
- Tcl_WinTCharToUtf((const TCHAR *)
+ Tcl_WinTCharToUtf(
reparseBuffer->MountPointReparseBuffer.PathBuffer,
- (int) reparseBuffer->MountPointReparseBuffer
+ reparseBuffer->MountPointReparseBuffer
.SubstituteNameLength, &ds);
copy = Tcl_DStringValue(&ds)+offset;
@@ -673,7 +673,7 @@ WinReadLinkDirectory(
static int
NativeReadReparse(
- const TCHAR *linkDirPath, /* The junction to read */
+ const WCHAR *linkDirPath, /* The junction to read */
REPARSE_DATA_BUFFER *buffer,/* Pointer to buffer. Cannot be NULL */
DWORD desiredAccess)
{
@@ -729,7 +729,7 @@ NativeReadReparse(
static int
NativeWriteReparse(
- const TCHAR *linkDirPath,
+ const WCHAR *linkDirPath,
REPARSE_DATA_BUFFER *buffer)
{
HANDLE hFile;
@@ -913,7 +913,7 @@ TclpMatchInDirectory(
* May be NULL. In particular the directory
* flag is very important. */
{
- const TCHAR *native;
+ const WCHAR *native;
if (types != NULL && types->type == TCL_GLOB_TYPE_MOUNT) {
/*
@@ -931,9 +931,10 @@ TclpMatchInDirectory(
* Match a single file directly.
*/
+ int len;
DWORD attr;
WIN32_FILE_ATTRIBUTE_DATA data;
- const char *str = TclGetString(norm);
+ const char *str = TclGetStringFromObj(norm, &len);
native = Tcl_FSGetNativePath(pathPtr);
@@ -943,7 +944,7 @@ TclpMatchInDirectory(
}
attr = data.dwFileAttributes;
- if (NativeMatchType(WinIsDrive(str,norm->length), attr, native, types)) {
+ if (NativeMatchType(WinIsDrive(str,len), attr, native, types)) {
Tcl_ListObjAppendElement(interp, resultPtr, pathPtr);
}
}
@@ -954,7 +955,7 @@ TclpMatchInDirectory(
WIN32_FIND_DATA data;
const char *dirName; /* UTF-8 dir name, later with pattern
* appended. */
- size_t dirLength;
+ int dirLength;
int matchSpecialDots;
Tcl_DString ds; /* Native encoding of dir, also used
* temporarily for other things. */
@@ -993,8 +994,7 @@ TclpMatchInDirectory(
*/
Tcl_DStringInit(&dsOrig);
- dirName = TclGetString(fileNamePtr);
- dirLength = fileNamePtr->length;
+ dirName = TclGetStringFromObj(fileNamePtr, &dirLength);
Tcl_DStringAppend(&dsOrig, dirName, dirLength);
lastChar = dirName[dirLength -1];
@@ -1313,7 +1313,7 @@ NativeMatchType(
int isDrive, /* Is this a drive. */
DWORD attr, /* We already know the attributes for the
* file. */
- const TCHAR *nativeName, /* Native path to check. */
+ const WCHAR *nativeName, /* Native path to check. */
Tcl_GlobTypeData *types) /* Type description to match against. */
{
/*
@@ -1465,14 +1465,14 @@ TclpGetUserHome(
Tcl_DStringFree(&ds);
} else {
Tcl_DStringInit(&ds);
- wName = Tcl_UtfToUniCharDString(domain + 1, -1, &ds);
+ wName = TclUtfToWCharDString(domain + 1, -1, &ds);
rc = NetGetDCName(NULL, wName, (LPBYTE *) &wDomain);
Tcl_DStringFree(&ds);
nameLen = domain - name;
}
if (rc == 0) {
Tcl_DStringInit(&ds);
- wName = Tcl_UtfToUniCharDString(name, nameLen, &ds);
+ wName = TclUtfToWCharDString(name, nameLen, &ds);
while (NetUserGetInfo(wDomain, wName, 1, (LPBYTE *) &uiPtr) != 0) {
/*
* user does not exists - if domain was not specified,
@@ -1490,19 +1490,19 @@ TclpGetUserHome(
wHomeDir = uiPtr->usri1_home_dir;
if ((wHomeDir != NULL) && (wHomeDir[0] != L'\0')) {
size = lstrlenW(wHomeDir);
- Tcl_UniCharToUtfDString(wHomeDir, size, bufferPtr);
+ TclWCharToUtfDString(wHomeDir, size, bufferPtr);
} else {
/*
* User exists but has no home dir. Return
* "{GetProfilesDirectory}/<user>".
*/
GetProfilesDirectoryW(buf, &size);
- Tcl_UniCharToUtfDString(buf, size-1, bufferPtr);
+ TclWCharToUtfDString(buf, size-1, bufferPtr);
Tcl_DStringAppend(bufferPtr, "/", 1);
Tcl_DStringAppend(bufferPtr, name, nameLen);
}
result = Tcl_DStringValue(bufferPtr);
- /* be sure we returns normalized path */
+ /* be sure we return normalized path */
for (i = 0; i < size; ++i){
if (result[i] == '\\') result[i] = '/';
}
@@ -1562,7 +1562,7 @@ TclpGetUserHome(
static int
NativeAccess(
- const TCHAR *nativePath, /* Path of file to access, native encoding. */
+ const WCHAR *nativePath, /* Path of file to access, native encoding. */
int mode) /* Permission setting. */
{
DWORD attr;
@@ -1824,9 +1824,9 @@ NativeAccess(
static int
NativeIsExec(
- const TCHAR *path)
+ const WCHAR *path)
{
- int len = _tcslen(path);
+ int len = wcslen(path);
if (len < 5) {
return 0;
@@ -1837,11 +1837,11 @@ NativeIsExec(
}
path += len-3;
- if ((_tcsicmp(path, TEXT("exe")) == 0)
- || (_tcsicmp(path, TEXT("com")) == 0)
- || (_tcsicmp(path, TEXT("cmd")) == 0)
- || (_tcsicmp(path, TEXT("cmd")) == 0)
- || (_tcsicmp(path, TEXT("bat")) == 0)) {
+ if ((wcsicmp(path, L"exe") == 0)
+ || (wcsicmp(path, L"com") == 0)
+ || (wcsicmp(path, L"cmd") == 0)
+ || (wcsicmp(path, L"cmd") == 0)
+ || (wcsicmp(path, L"bat") == 0)) {
return 1;
}
return 0;
@@ -1868,7 +1868,7 @@ TclpObjChdir(
Tcl_Obj *pathPtr) /* Path to new working directory. */
{
int result;
- const TCHAR *nativePath;
+ const WCHAR *nativePath;
nativePath = Tcl_FSGetNativePath(pathPtr);
@@ -1912,7 +1912,7 @@ TclpGetCwd(
Tcl_DString *bufferPtr) /* Uninitialized or free DString filled with
* name of current directory. */
{
- TCHAR buffer[MAX_PATH];
+ WCHAR buffer[MAX_PATH];
char *p;
WCHAR *native;
@@ -1935,7 +1935,7 @@ TclpGetCwd(
&& (native[2] == '\\') && (native[3] == '\\')) {
native += 2;
}
- Tcl_WinTCharToUtf((TCHAR *) native, -1, bufferPtr);
+ Tcl_WinTCharToUtf(native, -1, bufferPtr);
/*
* Convert to forward slashes for easier use in scripts.
@@ -1990,7 +1990,7 @@ TclpObjStat(
static int
NativeStat(
- const TCHAR *nativePath, /* Path of file to stat */
+ const WCHAR *nativePath, /* Path of file to stat */
Tcl_StatBuf *statPtr, /* Filled with results of stat call. */
int checkLinks) /* If non-zero, behave like 'lstat' */
{
@@ -2131,12 +2131,12 @@ NativeStat(
static int
NativeDev(
- const TCHAR *nativePath) /* Full path of file to stat */
+ const WCHAR *nativePath) /* Full path of file to stat */
{
int dev;
Tcl_DString ds;
- TCHAR nativeFullPath[MAX_PATH];
- TCHAR *nativePart;
+ WCHAR nativeFullPath[MAX_PATH];
+ WCHAR *nativePart;
const char *fullPath;
GetFullPathName(nativePath, MAX_PATH, nativeFullPath, &nativePart);
@@ -2145,7 +2145,7 @@ NativeDev(
if ((fullPath[0] == '\\') && (fullPath[1] == '\\')) {
const char *p;
DWORD dw;
- const TCHAR *nativeVol;
+ const WCHAR *nativeVol;
Tcl_DString volString;
p = strchr(fullPath + 2, '\\');
@@ -2307,7 +2307,7 @@ ClientData
TclpGetNativeCwd(
ClientData clientData)
{
- TCHAR buffer[MAX_PATH];
+ WCHAR buffer[MAX_PATH];
if (GetCurrentDirectory(MAX_PATH, buffer) == 0) {
TclWinConvertError(GetLastError());
@@ -2315,7 +2315,7 @@ TclpGetNativeCwd(
}
if (clientData != NULL) {
- if (_tcscmp((const TCHAR*)clientData, buffer) == 0) {
+ if (wcscmp((const WCHAR*)clientData, buffer) == 0) {
return clientData;
}
}
@@ -2356,8 +2356,8 @@ TclpObjLink(
{
if (toPtr != NULL) {
int res;
- const TCHAR *LinkTarget;
- const TCHAR *LinkSource = Tcl_FSGetNativePath(pathPtr);
+ const WCHAR *LinkTarget;
+ const WCHAR *LinkSource = Tcl_FSGetNativePath(pathPtr);
Tcl_Obj *normalizedToPtr = Tcl_FSGetNormalizedPath(NULL, toPtr);
if (normalizedToPtr == NULL) {
@@ -2376,7 +2376,7 @@ TclpObjLink(
return NULL;
}
} else {
- const TCHAR *LinkSource = Tcl_FSGetNativePath(pathPtr);
+ const WCHAR *LinkSource = Tcl_FSGetNativePath(pathPtr);
if (LinkSource == NULL) {
return NULL;
@@ -2410,7 +2410,7 @@ TclpFilesystemPathType(
{
#define VOL_BUF_SIZE 32
int found;
- TCHAR volType[VOL_BUF_SIZE];
+ WCHAR volType[VOL_BUF_SIZE];
char *firstSeparator;
const char *path;
Tcl_Obj *normPath = Tcl_FSGetNormalizedPath(NULL, pathPtr);
@@ -2511,7 +2511,7 @@ TclpObjNormalizePath(
*/
WIN32_FILE_ATTRIBUTE_DATA data;
- const TCHAR *nativePath = Tcl_WinUtfToTChar(path,
+ const WCHAR *nativePath = Tcl_WinUtfToTChar(path,
currentPathEndPosition - path, &ds);
if (GetFileAttributesEx(nativePath,
@@ -2654,8 +2654,8 @@ TclpObjNormalizePath(
Tcl_DStringAppend(&dsNorm, ((const char *)nativePath)
+ Tcl_DStringLength(&ds)
- - (dotLen * sizeof(TCHAR)),
- (int)(dotLen * sizeof(TCHAR)));
+ - (dotLen * sizeof(WCHAR)),
+ dotLen * sizeof(WCHAR));
} else {
/*
* Normal path.
@@ -2713,10 +2713,10 @@ TclpObjNormalizePath(
if (1) {
WCHAR wpath[MAX_PATH];
- const TCHAR *nativePath =
+ const WCHAR *nativePath =
Tcl_WinUtfToTChar(path, lastValidPathEnd - path, &ds);
DWORD wpathlen = GetLongPathNameProc(nativePath,
- (TCHAR *) wpath, MAX_PATH);
+ (WCHAR *) wpath, MAX_PATH);
/*
* We have to make the drive letter uppercase.
@@ -2744,7 +2744,7 @@ TclpObjNormalizePath(
* native encoding, so we have to convert it to Utf.
*/
- Tcl_WinTCharToUtf((const TCHAR *) Tcl_DStringValue(&dsNorm),
+ Tcl_WinTCharToUtf((const WCHAR *) Tcl_DStringValue(&dsNorm),
Tcl_DStringLength(&dsNorm), &ds);
nextCheckpoint = Tcl_DStringLength(&ds);
if (*lastValidPathEnd != 0) {
@@ -2752,14 +2752,15 @@ TclpObjNormalizePath(
* Not the end of the string.
*/
+ int len;
char *path;
Tcl_Obj *tmpPathPtr;
tmpPathPtr = Tcl_NewStringObj(Tcl_DStringValue(&ds),
nextCheckpoint);
Tcl_AppendToObj(tmpPathPtr, lastValidPathEnd, -1);
- path = TclGetString(tmpPathPtr);
- Tcl_SetStringObj(pathPtr, path, tmpPathPtr->length);
+ path = TclGetStringFromObj(tmpPathPtr, &len);
+ Tcl_SetStringObj(pathPtr, path, len);
Tcl_DecrRefCount(tmpPathPtr);
} else {
/*
@@ -2842,8 +2843,8 @@ TclWinVolumeRelativeNormalize(
* also on drive C.
*/
- const char *drive = TclGetString(useThisCwd);
- size_t cwdLen = useThisCwd->length;
+ int cwdLen;
+ const char *drive = TclGetStringFromObj(useThisCwd, &cwdLen);
char drive_cur = path[0];
if (drive_cur >= 'a') {
@@ -2919,7 +2920,7 @@ TclpNativeToNormalized(
int len;
char *copy, *p;
- Tcl_WinTCharToUtf((const TCHAR *) clientData, -1, &ds);
+ Tcl_WinTCharToUtf((const WCHAR *) clientData, -1, &ds);
copy = Tcl_DStringValue(&ds);
len = Tcl_DStringLength(&ds);
@@ -2978,7 +2979,7 @@ TclNativeCreateNativeRep(
WCHAR *nativePathPtr = NULL;
const char *str;
Tcl_Obj *validPathPtr;
- size_t len;
+ int len;
WCHAR *wp;
if (TclFSCwdIsNative()) {
@@ -3006,10 +3007,9 @@ TclNativeCreateNativeRep(
Tcl_IncrRefCount(validPathPtr);
}
- str = Tcl_GetString(validPathPtr);
- len = validPathPtr->length;
+ str = Tcl_GetStringFromObj(validPathPtr, &len);
- if (strlen(str)!=(unsigned int)len) {
+ if (strlen(str)!=(size_t)len) {
/* String contains NUL-bytes. This is invalid. */
goto done;
}
@@ -3112,7 +3112,7 @@ TclNativeDupInternalRep(
return NULL;
}
- len = sizeof(TCHAR) * (_tcslen((const TCHAR *) clientData) + 1);
+ len = sizeof(WCHAR) * (wcslen((const WCHAR *) clientData) + 1);
copy = ckalloc(len);
memcpy(copy, clientData, len);
@@ -3143,7 +3143,7 @@ TclpUtime(
{
int res = 0;
HANDLE fileHandle;
- const TCHAR *native;
+ const WCHAR *native;
DWORD attr = 0;
DWORD flags = FILE_ATTRIBUTE_NORMAL;
FILETIME lastAccessTime, lastModTime;
@@ -3194,7 +3194,7 @@ int
TclWinFileOwned(
Tcl_Obj *pathPtr) /* File whose ownership is to be checked */
{
- const TCHAR *native;
+ const WCHAR *native;
PSID ownerSid = NULL;
PSECURITY_DESCRIPTOR secd = NULL;
HANDLE token;
diff --git a/win/tclWinInit.c b/win/tclWinInit.c
index 2ce19ce..f4c6e06 100644
--- a/win/tclWinInit.c
+++ b/win/tclWinInit.c
@@ -155,7 +155,7 @@ TclpInitPlatform(void)
/*
* Fill available functions depending on windows version
*/
- handle = GetModuleHandle(TEXT("KERNEL32"));
+ handle = GetModuleHandle(L"KERNEL32");
tclWinProcs.cancelSynchronousIo =
(BOOL (WINAPI *)(HANDLE)) GetProcAddress(handle,
"CancelSynchronousIo");
@@ -188,6 +188,7 @@ TclpInitLibraryPath(
Tcl_Obj *pathPtr;
char installLib[LIBRARY_SIZE];
const char *bytes;
+ int length;
pathPtr = Tcl_NewObj();
@@ -223,10 +224,10 @@ TclpInitLibraryPath(
TclGetProcessGlobalValue(&sourceLibraryDir));
*encodingPtr = NULL;
- bytes = TclGetString(pathPtr);
- *lengthPtr = pathPtr->length;
- *valuePtr = ckalloc(*lengthPtr + 1);
- memcpy(*valuePtr, bytes, *lengthPtr + 1);
+ bytes = TclGetStringFromObj(pathPtr, &length);
+ *lengthPtr = length++;
+ *valuePtr = ckalloc(length);
+ memcpy(*valuePtr, bytes, length);
Tcl_DecrRefCount(pathPtr);
}
@@ -269,7 +270,7 @@ AppendEnvironment(
for (shortlib = (char *) &lib[strlen(lib)-1]; shortlib>lib ; shortlib--) {
if (*shortlib == '/') {
- if ((unsigned)(shortlib - lib) == strlen(lib) - 1) {
+ if ((size_t)(shortlib - lib) == strlen(lib) - 1) {
Tcl_Panic("last character in lib cannot be '/'");
}
shortlib++;
@@ -468,14 +469,14 @@ TclpGetUserName(
Tcl_DStringInit(bufferPtr);
if (TclGetEnv("USERNAME", bufferPtr) == NULL) {
- TCHAR szUserName[UNLEN+1];
+ WCHAR szUserName[UNLEN+1];
DWORD cchUserNameLen = UNLEN;
if (!GetUserName(szUserName, &cchUserNameLen)) {
return NULL;
}
cchUserNameLen--;
- cchUserNameLen *= sizeof(TCHAR);
+ cchUserNameLen *= sizeof(WCHAR);
Tcl_WinTCharToUtf(szUserName, cchUserNameLen, bufferPtr);
}
return Tcl_DStringValue(bufferPtr);
@@ -516,7 +517,7 @@ TclpSetVariables(
TclGetProcessGlobalValue(&defaultLibraryDir), TCL_GLOBAL_ONLY);
if (!osInfoInitialized) {
- HMODULE handle = GetModuleHandle(TEXT("NTDLL"));
+ HMODULE handle = GetModuleHandle(L"NTDLL");
int(__stdcall *getversion)(void *) =
(int(__stdcall *)(void *)) GetProcAddress(handle, "RtlGetVersion");
osInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFOW);
@@ -637,7 +638,7 @@ TclpFindVariable(
length = strlen(name);
nameUpper = ckalloc(length + 1);
- memcpy(nameUpper, name, (size_t) length+1);
+ memcpy(nameUpper, name, length+1);
Tcl_UtfToUpper(nameUpper);
Tcl_DStringInit(&envString);
diff --git a/win/tclWinInt.h b/win/tclWinInt.h
index 63835bf..ba07d0e 100644
--- a/win/tclWinInt.h
+++ b/win/tclWinInt.h
@@ -46,7 +46,7 @@ MODULE_SCOPE TclWinProcs tclWinProcs;
*/
MODULE_SCOPE char TclWinDriveLetterForVolMountPoint(
- const TCHAR *mountPoint);
+ const WCHAR *mountPoint);
MODULE_SCOPE void TclWinEncodingsCleanup();
MODULE_SCOPE void TclWinInit(HINSTANCE hInst);
MODULE_SCOPE TclFile TclWinMakeFile(HANDLE handle);
@@ -56,7 +56,7 @@ MODULE_SCOPE Tcl_Channel TclWinOpenFileChannel(HANDLE handle, char *channelName,
int permissions, int appendMode);
MODULE_SCOPE Tcl_Channel TclWinOpenSerialChannel(HANDLE handle,
char *channelName, int permissions);
-MODULE_SCOPE HANDLE TclWinSerialOpen(HANDLE handle, const TCHAR *name,
+MODULE_SCOPE HANDLE TclWinSerialOpen(HANDLE handle, const WCHAR *name,
DWORD access);
MODULE_SCOPE int TclWinSymLinkCopyDirectory(const TCHAR *LinkOriginal,
const TCHAR *LinkCopy);
diff --git a/win/tclWinPipe.c b/win/tclWinPipe.c
index 597d5df..ee1e9ba 100644
--- a/win/tclWinPipe.c
+++ b/win/tclWinPipe.c
@@ -191,7 +191,7 @@ static DWORD WINAPI PipeReaderThread(LPVOID arg);
static void PipeSetupProc(ClientData clientData, int flags);
static void PipeWatchProc(ClientData instanceData, int mask);
static DWORD WINAPI PipeWriterThread(LPVOID arg);
-static int TempFileName(TCHAR name[MAX_PATH]);
+static int TempFileName(WCHAR name[MAX_PATH]);
static int WaitForRead(PipeInfo *infoPtr, int blocking);
static void PipeThreadActionProc(ClientData instanceData,
int action);
@@ -463,10 +463,10 @@ TclWinMakeFile(
static int
TempFileName(
- TCHAR name[MAX_PATH]) /* Buffer in which name for temporary file
+ WCHAR name[MAX_PATH]) /* Buffer in which name for temporary file
* gets stored. */
{
- const TCHAR *prefix = TEXT("TCL");
+ const WCHAR *prefix = L"TCL";
if (GetTempPath(MAX_PATH, name) != 0) {
if (GetTempFileName(name, prefix, 0, name) != 0) {
return 1;
@@ -533,7 +533,7 @@ TclpOpenFile(
HANDLE handle;
DWORD accessMode, createMode, shareMode, flags;
Tcl_DString ds;
- const TCHAR *nativePath;
+ const WCHAR *nativePath;
/*
* Map the access bits to the NT access mode.
@@ -650,7 +650,7 @@ TclFile
TclpCreateTempFile(
const char *contents) /* String to write into temp file, or NULL. */
{
- TCHAR name[MAX_PATH];
+ WCHAR name[MAX_PATH];
const char *native;
Tcl_DString dstring;
HANDLE handle;
@@ -744,7 +744,7 @@ TclpCreateTempFile(
Tcl_Obj *
TclpTempFileName(void)
{
- TCHAR fileName[MAX_PATH];
+ WCHAR fileName[MAX_PATH];
if (TempFileName(fileName) == 0) {
return NULL;
@@ -936,7 +936,7 @@ TclpCreateProcess(
* process. */
{
int result, applType, createFlags;
- Tcl_DString cmdLine; /* Complete command line (TCHAR). */
+ Tcl_DString cmdLine; /* Complete command line (WCHAR). */
STARTUPINFO startInfo;
PROCESS_INFORMATION procInfo;
SECURITY_ATTRIBUTES secAtts;
@@ -1048,7 +1048,7 @@ TclpCreateProcess(
* sink.
*/
- startInfo.hStdOutput = CreateFile(TEXT("NUL:"), GENERIC_WRITE, 0,
+ startInfo.hStdOutput = CreateFile(L"NUL:", GENERIC_WRITE, 0,
&secAtts, OPEN_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL);
} else {
DuplicateHandle(hProcess, outputHandle, hProcess,
@@ -1068,7 +1068,7 @@ TclpCreateProcess(
* sink.
*/
- startInfo.hStdError = CreateFile(TEXT("NUL:"), GENERIC_WRITE, 0,
+ startInfo.hStdError = CreateFile(L"NUL:", GENERIC_WRITE, 0,
&secAtts, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
} else {
DuplicateHandle(hProcess, errorHandle, hProcess, &startInfo.hStdError,
@@ -1134,7 +1134,7 @@ TclpCreateProcess(
BuildCommandLine(execPath, argc, argv, &cmdLine);
- if (CreateProcess(NULL, (TCHAR *) Tcl_DStringValue(&cmdLine),
+ if (CreateProcess(NULL, (WCHAR *) Tcl_DStringValue(&cmdLine),
NULL, NULL, TRUE, (DWORD) createFlags, NULL, NULL, &startInfo,
&procInfo) == 0) {
TclWinConvertError(GetLastError());
@@ -1260,14 +1260,14 @@ ApplicationType(
{
int applType, i, nameLen, found;
HANDLE hFile;
- TCHAR *rest;
+ WCHAR *rest;
char *ext;
char buf[2];
DWORD attr, read;
IMAGE_DOS_HEADER header;
Tcl_DString nameBuf, ds;
- const TCHAR *nativeName;
- TCHAR nativeFullPath[MAX_PATH];
+ const WCHAR *nativeName;
+ WCHAR nativeFullPath[MAX_PATH];
static const char extensions[][5] = {"", ".com", ".exe", ".bat", ".cmd"};
/*
@@ -1512,7 +1512,7 @@ BuildCommandLine(
int argc, /* Number of arguments. */
const char **argv, /* Argument strings in UTF. */
Tcl_DString *linePtr) /* Initialized Tcl_DString that receives the
- * command line (TCHAR). */
+ * command line (WCHAR). */
{
const char *arg, *start, *special, *bspos;
int quote = 0, i;
@@ -1554,16 +1554,13 @@ BuildCommandLine(
if (arg[0] == '\0') {
quote = CL_QUOTE;
} else {
- int count;
- Tcl_UniChar ch;
for (start = arg;
*start != '\0' &&
(quote & (CL_ESCAPE|CL_QUOTE)) != (CL_ESCAPE|CL_QUOTE);
- start += count
+ start++
) {
- count = Tcl_UtfToUniChar(start, &ch);
- if (count > 1) continue;
- if (Tcl_UniCharIsSpace(ch)) {
+ if (*start & 0x80) continue;
+ if (TclIsSpaceProc(*start)) {
quote |= CL_QUOTE; /* quote only */
if (bspos) { /* if backslash found - escape & quote */
quote |= CL_ESCAPE;
@@ -2217,7 +2214,7 @@ PipeOutputProc(
infoPtr->writeBufLen = toWrite;
infoPtr->writeBuf = ckalloc(toWrite);
}
- memcpy(infoPtr->writeBuf, buf, (size_t) toWrite);
+ memcpy(infoPtr->writeBuf, buf, toWrite);
infoPtr->toWrite = toWrite;
ResetEvent(infoPtr->writable);
TclPipeThreadSignal(&infoPtr->writeTI);
@@ -3104,7 +3101,7 @@ TclpOpenTemporaryFile(
Tcl_Obj *extensionObj,
Tcl_Obj *resultingNameObj)
{
- TCHAR name[MAX_PATH];
+ WCHAR name[MAX_PATH];
char *namePtr;
HANDLE handle;
DWORD flags = FILE_ATTRIBUTE_TEMPORARY;
@@ -3120,17 +3117,17 @@ TclpOpenTemporaryFile(
if (length == 0) {
goto gotError;
}
- namePtr += length * sizeof(TCHAR);
+ namePtr += length * sizeof(WCHAR);
if (basenameObj) {
- const char *string = Tcl_GetString(basenameObj);
+ const char *string = TclGetStringFromObj(basenameObj, &length);
- Tcl_WinUtfToTChar(string, basenameObj->length, &buf);
+ Tcl_WinUtfToTChar(string, length, &buf);
memcpy(namePtr, Tcl_DStringValue(&buf), Tcl_DStringLength(&buf));
namePtr += Tcl_DStringLength(&buf);
Tcl_DStringFree(&buf);
} else {
- const TCHAR *baseStr = TEXT("TCL");
- int length = 3 * sizeof(TCHAR);
+ const WCHAR *baseStr = L"TCL";
+ length = 3 * sizeof(WCHAR);
memcpy(namePtr, baseStr, length);
namePtr += length;
diff --git a/win/tclWinPort.h b/win/tclWinPort.h
index 21344ec..8606511 100644
--- a/win/tclWinPort.h
+++ b/win/tclWinPort.h
@@ -52,15 +52,6 @@ typedef DWORD_PTR * PDWORD_PTR;
# include <wspiapi.h>
#endif
-#ifdef CHECK_UNICODE_CALLS
-# define _UNICODE
-# define UNICODE
-# define __TCHAR_DEFINED
- typedef float *_TCHAR;
-# define _TCHAR_DEFINED
- typedef float *TCHAR;
-#endif /* CHECK_UNICODE_CALLS */
-
/*
* Pull in the typedef of TCHAR for windows.
*/
diff --git a/win/tclWinSerial.c b/win/tclWinSerial.c
index 8ee426b..2a2c445 100644
--- a/win/tclWinSerial.c
+++ b/win/tclWinSerial.c
@@ -1368,7 +1368,7 @@ SerialWriterThread(
HANDLE
TclWinSerialOpen(
HANDLE handle,
- const TCHAR *name,
+ const WCHAR *name,
DWORD access)
{
SerialInit();
@@ -1595,7 +1595,7 @@ SerialSetOptionProc(
BOOL result, flag;
size_t len, vlen;
Tcl_DString ds;
- const TCHAR *native;
+ const WCHAR *native;
int argc;
const char **argv;
@@ -1718,7 +1718,7 @@ SerialSetOptionProc(
if (interp != NULL) {
Tcl_SetObjResult(interp, Tcl_NewStringObj(
"bad value for -xchar: should be a list of"
- " two elements with each a single character", -1));
+ " two elements with each a single 8-bit character", -1));
Tcl_SetErrorCode(interp, "TCL", "VALUE", "XCHAR", NULL);
}
ckfree(argv);
@@ -1742,12 +1742,12 @@ SerialSetOptionProc(
int charLen;
charLen = Tcl_UtfToUniChar(argv[0], &character);
- if (argv[0][charLen]) {
+ if ((character > 0xFF) || argv[0][charLen]) {
goto badXchar;
}
dcb.XonChar = (char) character;
charLen = Tcl_UtfToUniChar(argv[1], &character);
- if (argv[1][charLen]) {
+ if ((character > 0xFF) || argv[1][charLen]) {
goto badXchar;
}
dcb.XoffChar = (char) character;
@@ -2077,7 +2077,7 @@ SerialGetOptionProc(
Tcl_DStringStartSublist(dsPtr);
}
if (len==0 || (len>1 && strncmp(optionName, "-xchar", len) == 0)) {
- char buf[4];
+ char buf[TCL_UTF_MAX];
valid = 1;
if (!GetCommState(infoPtr->handle, &dcb)) {
@@ -2088,9 +2088,9 @@ SerialGetOptionProc(
}
return TCL_ERROR;
}
- sprintf(buf, "%c", dcb.XonChar);
+ buf[Tcl_UniCharToUtf(UCHAR(dcb.XonChar), buf)] = '\0';
Tcl_DStringAppendElement(dsPtr, buf);
- sprintf(buf, "%c", dcb.XoffChar);
+ buf[Tcl_UniCharToUtf(UCHAR(dcb.XoffChar), buf)] = '\0';
Tcl_DStringAppendElement(dsPtr, buf);
}
if (len == 0) {
diff --git a/win/tclWinSock.c b/win/tclWinSock.c
index f872163..d52edc3 100644
--- a/win/tclWinSock.c
+++ b/win/tclWinSock.c
@@ -82,7 +82,7 @@
*/
static int initialized = 0;
-static const TCHAR className[] = TEXT("TclSocket");
+static const WCHAR className[] = L"TclSocket";
TCL_DECLARE_MUTEX(socketMutex)
/*
@@ -363,7 +363,7 @@ InitializeHostName(
unsigned int *lengthPtr,
Tcl_Encoding *encodingPtr)
{
- TCHAR tbuf[MAX_COMPUTERNAME_LENGTH + 1];
+ WCHAR tbuf[MAX_COMPUTERNAME_LENGTH + 1];
DWORD length = MAX_COMPUTERNAME_LENGTH + 1;
Tcl_DString ds;
diff --git a/win/tclWinTime.c b/win/tclWinTime.c
index dd603d1..bfebbe6 100644
--- a/win/tclWinTime.c
+++ b/win/tclWinTime.c
@@ -53,6 +53,7 @@ typedef struct {
* initialized. */
int perfCounterAvailable; /* Flag == 1 if the hardware has a performance
* counter. */
+ DWORD calibrationInterv; /* Calibration interval in seconds (start 1 sec) */
HANDLE calibrationThread; /* Handle to the thread that keeps the virtual
* clock calibrated. */
HANDLE readyEvent; /* System event used to trigger the requesting
@@ -63,7 +64,6 @@ typedef struct {
LARGE_INTEGER nominalFreq; /* Nominal frequency of the system performance
* counter, that is, the value returned from
* QueryPerformanceFrequency. */
-
/*
* The following values are used for calculating virtual time. Virtual
* time is always equal to:
@@ -76,6 +76,8 @@ typedef struct {
ULARGE_INTEGER fileTimeLastCall;
LARGE_INTEGER perfCounterLastCall;
LARGE_INTEGER curCounterFreq;
+ LARGE_INTEGER posixEpoch; /* Posix epoch expressed as 100-ns ticks since
+ * the windows epoch. */
/*
* Data used in developing the estimate of performance counter frequency
@@ -92,6 +94,7 @@ static TimeInfo timeInfo = {
{ NULL, 0, 0, NULL, NULL, 0 },
0,
0,
+ 1,
(HANDLE) NULL,
(HANDLE) NULL,
(HANDLE) NULL,
@@ -100,11 +103,13 @@ static TimeInfo timeInfo = {
(ULARGE_INTEGER) (DWORDLONG) 0,
(LARGE_INTEGER) (Tcl_WideInt) 0,
(LARGE_INTEGER) (Tcl_WideInt) 0,
+ (LARGE_INTEGER) (Tcl_WideInt) 0,
#else
- 0,
- 0,
- 0,
- 0,
+ {0, 0},
+ {0, 0},
+ {0, 0},
+ {0, 0},
+ {0, 0},
#endif
{ 0 },
{ 0 },
@@ -112,6 +117,17 @@ static TimeInfo timeInfo = {
};
/*
+ * Scale to convert wide click values from the TclpGetWideClicks native
+ * resolution to microsecond resolution and back.
+ */
+static struct {
+ int initialized; /* 1 if initialized, 0 otherwise */
+ int perfCounter; /* 1 if performance counter usable for wide clicks */
+ double microsecsScale; /* Denominator scale between clock / microsecs */
+} wideClick = {0, 0.0};
+
+
+/*
* Declarations for functions defined later in this file.
*/
@@ -127,6 +143,7 @@ static Tcl_WideInt AccumulateSample(Tcl_WideInt perfCounter,
Tcl_WideUInt fileTime);
static void NativeScaleTime(Tcl_Time* timebuf,
ClientData clientData);
+static Tcl_WideInt NativeGetMicroseconds(void);
static void NativeGetTime(Tcl_Time* timebuf,
ClientData clientData);
@@ -158,10 +175,19 @@ ClientData tclTimeClientData = NULL;
unsigned long
TclpGetSeconds(void)
{
- Tcl_Time t;
+ Tcl_WideInt usecSincePosixEpoch;
+
+ /* Try to use high resolution timer */
+ if ( tclGetTimeProcPtr == NativeGetTime
+ && (usecSincePosixEpoch = NativeGetMicroseconds())
+ ) {
+ return usecSincePosixEpoch / 1000000;
+ } else {
+ Tcl_Time t;
- tclGetTimeProcPtr(&t, tclTimeClientData); /* Tcl_GetTime inlined. */
- return t.sec;
+ tclGetTimeProcPtr(&t, tclTimeClientData); /* Tcl_GetTime inlined. */
+ return t.sec;
+ }
}
/*
@@ -186,19 +212,147 @@ TclpGetSeconds(void)
unsigned long
TclpGetClicks(void)
{
- /*
- * Use the Tcl_GetTime abstraction to get the time in microseconds, as
- * nearly as we can, and return it.
- */
+ Tcl_WideInt usecSincePosixEpoch;
+
+ /* Try to use high resolution timer */
+ if ( tclGetTimeProcPtr == NativeGetTime
+ && (usecSincePosixEpoch = NativeGetMicroseconds())
+ ) {
+ return (unsigned long)usecSincePosixEpoch;
+ } else {
+ /*
+ * Use the Tcl_GetTime abstraction to get the time in microseconds, as
+ * nearly as we can, and return it.
+ */
- Tcl_Time now; /* Current Tcl time */
- unsigned long retval; /* Value to return */
+ Tcl_Time now; /* Current Tcl time */
- tclGetTimeProcPtr(&now, tclTimeClientData); /* Tcl_GetTime inlined */
+ tclGetTimeProcPtr(&now, tclTimeClientData); /* Tcl_GetTime inlined */
+ return (unsigned long)(now.sec * 1000000) + now.usec;
+ }
+}
+
+/*
+ *----------------------------------------------------------------------
+ *
+ * TclpGetWideClicks --
+ *
+ * This procedure returns a WideInt value that represents the highest
+ * resolution clock in microseconds available on the system.
+ *
+ * Results:
+ * Number of microseconds (from some start time).
+ *
+ * Side effects:
+ * This should be used for time-delta resp. for measurement purposes
+ * only, because on some platforms can return microseconds from some
+ * start time (not from the epoch).
+ *
+ *----------------------------------------------------------------------
+ */
+
+Tcl_WideInt
+TclpGetWideClicks(void)
+{
+ LARGE_INTEGER curCounter;
+
+ if (!wideClick.initialized) {
+ LARGE_INTEGER perfCounterFreq;
+
+ /*
+ * The frequency of the performance counter is fixed at system boot and
+ * is consistent across all processors. Therefore, the frequency need
+ * only be queried upon application initialization.
+ */
+ if (QueryPerformanceFrequency(&perfCounterFreq)) {
+ wideClick.perfCounter = 1;
+ wideClick.microsecsScale = 1000000.0 / perfCounterFreq.QuadPart;
+ } else {
+ /* fallback using microseconds */
+ wideClick.perfCounter = 0;
+ wideClick.microsecsScale = 1;
+ }
- retval = (now.sec * 1000000) + now.usec;
- return retval;
+ wideClick.initialized = 1;
+ }
+ if (wideClick.perfCounter) {
+ if (QueryPerformanceCounter(&curCounter)) {
+ return (Tcl_WideInt)curCounter.QuadPart;
+ }
+ /* fallback using microseconds */
+ wideClick.perfCounter = 0;
+ wideClick.microsecsScale = 1;
+ return TclpGetMicroseconds();
+ } else {
+ return TclpGetMicroseconds();
+ }
+}
+
+/*
+ *----------------------------------------------------------------------
+ *
+ * TclpWideClickInMicrosec --
+ *
+ * This procedure return scale to convert wide click values from the
+ * TclpGetWideClicks native resolution to microsecond resolution
+ * and back.
+ *
+ * Results:
+ * 1 click in microseconds as double.
+ *
+ * Side effects:
+ * None.
+ *
+ *----------------------------------------------------------------------
+ */
+double
+TclpWideClickInMicrosec(void)
+{
+ if (!wideClick.initialized) {
+ (void)TclpGetWideClicks(); /* initialize */
+ }
+ return wideClick.microsecsScale;
+}
+
+/*
+ *----------------------------------------------------------------------
+ *
+ * TclpGetMicroseconds --
+ *
+ * This procedure returns a WideInt value that represents the highest
+ * resolution clock in microseconds available on the system.
+ *
+ * Results:
+ * Number of microseconds (from the epoch).
+ *
+ * Side effects:
+ * None.
+ *
+ *----------------------------------------------------------------------
+ */
+
+Tcl_WideInt
+TclpGetMicroseconds(void)
+{
+ Tcl_WideInt usecSincePosixEpoch;
+
+ /* Try to use high resolution timer */
+ if ( tclGetTimeProcPtr == NativeGetTime
+ && (usecSincePosixEpoch = NativeGetMicroseconds())
+ ) {
+ return usecSincePosixEpoch;
+ } else {
+ /*
+ * Use the Tcl_GetTime abstraction to get the time in microseconds, as
+ * nearly as we can, and return it.
+ */
+
+ Tcl_Time now;
+
+ tclGetTimeProcPtr(&now, tclTimeClientData); /* Tcl_GetTime inlined */
+ return (((Tcl_WideInt)now.sec) * 1000000) + now.usec;
+ }
}
/*
@@ -227,7 +381,17 @@ void
Tcl_GetTime(
Tcl_Time *timePtr) /* Location to store time information. */
{
- tclGetTimeProcPtr(timePtr, tclTimeClientData);
+ Tcl_WideInt usecSincePosixEpoch;
+
+ /* Try to use high resolution timer */
+ if ( tclGetTimeProcPtr == NativeGetTime
+ && (usecSincePosixEpoch = NativeGetMicroseconds())
+ ) {
+ timePtr->sec = (long) (usecSincePosixEpoch / 1000000);
+ timePtr->usec = (unsigned long) (usecSincePosixEpoch % 1000000);
+ } else {
+ tclGetTimeProcPtr(timePtr, tclTimeClientData);
+ }
}
/*
@@ -260,13 +424,14 @@ NativeScaleTime(
/*
*----------------------------------------------------------------------
*
- * NativeGetTime --
+ * NativeGetMicroseconds --
*
- * TIP #233: Gets the current system time in seconds and microseconds
- * since the beginning of the epoch: 00:00 UCT, January 1, 1970.
+ * Gets the current system time in microseconds since the beginning
+ * of the epoch: 00:00 UCT, January 1, 1970.
*
* Results:
- * Returns the current time in timePtr.
+ * Returns the wide integer with number of microseconds from the epoch, or
+ * 0 if high resolution timer is not available.
*
* Side effects:
* On the first call, initializes a set of static variables to keep track
@@ -279,13 +444,20 @@ NativeScaleTime(
*----------------------------------------------------------------------
*/
-static void
-NativeGetTime(
- Tcl_Time *timePtr,
- ClientData clientData)
-{
- struct _timeb t;
+static inline Tcl_WideInt
+NativeCalc100NsTicks(
+ ULONGLONG fileTimeLastCall,
+ LONGLONG perfCounterLastCall,
+ LONGLONG curCounterFreq,
+ LONGLONG curCounter
+) {
+ return fileTimeLastCall +
+ ((curCounter - perfCounterLastCall) * 10000000 / curCounterFreq);
+}
+static Tcl_WideInt
+NativeGetMicroseconds(void)
+{
/*
* Initialize static storage on the first trip through.
*
@@ -296,6 +468,10 @@ NativeGetTime(
if (!timeInfo.initialized) {
TclpInitLock();
if (!timeInfo.initialized) {
+
+ timeInfo.posixEpoch.LowPart = 0xD53E8000;
+ timeInfo.posixEpoch.HighPart = 0x019DB1DE;
+
timeInfo.perfCounterAvailable =
QueryPerformanceFrequency(&timeInfo.nominalFreq);
@@ -400,22 +576,12 @@ NativeGetTime(
* time.
*/
- ULARGE_INTEGER fileTimeLastCall;
- LARGE_INTEGER perfCounterLastCall, curCounterFreq;
+ ULONGLONG fileTimeLastCall;
+ LONGLONG perfCounterLastCall, curCounterFreq;
/* Copy with current data of calibration cycle */
LARGE_INTEGER curCounter;
/* Current performance counter. */
- Tcl_WideInt curFileTime;/* Current estimated time, expressed as 100-ns
- * ticks since the Windows epoch. */
- static LARGE_INTEGER posixEpoch;
- /* Posix epoch expressed as 100-ns ticks since
- * the windows epoch. */
- Tcl_WideInt usecSincePosixEpoch;
- /* Current microseconds since Posix epoch. */
-
- posixEpoch.LowPart = 0xD53E8000;
- posixEpoch.HighPart = 0x019DB1DE;
QueryPerformanceCounter(&curCounter);
@@ -424,21 +590,18 @@ NativeGetTime(
*/
EnterCriticalSection(&timeInfo.cs);
- fileTimeLastCall.QuadPart = timeInfo.fileTimeLastCall.QuadPart;
- perfCounterLastCall.QuadPart = timeInfo.perfCounterLastCall.QuadPart;
- curCounterFreq.QuadPart = timeInfo.curCounterFreq.QuadPart;
+ fileTimeLastCall = timeInfo.fileTimeLastCall.QuadPart;
+ perfCounterLastCall = timeInfo.perfCounterLastCall.QuadPart;
+ curCounterFreq = timeInfo.curCounterFreq.QuadPart;
LeaveCriticalSection(&timeInfo.cs);
/*
* If calibration cycle occurred after we get curCounter
*/
- if (curCounter.QuadPart <= perfCounterLastCall.QuadPart) {
- usecSincePosixEpoch =
- (fileTimeLastCall.QuadPart - posixEpoch.QuadPart) / 10;
- timePtr->sec = (long) (usecSincePosixEpoch / 1000000);
- timePtr->usec = (unsigned long) (usecSincePosixEpoch % 1000000);
- return;
+ if (curCounter.QuadPart <= perfCounterLastCall) {
+ /* Calibrated file-time is saved from posix in 100-ns ticks */
+ return fileTimeLastCall / 10;
}
/*
@@ -451,27 +614,62 @@ NativeGetTime(
* loop should recover.
*/
- if (curCounter.QuadPart - perfCounterLastCall.QuadPart <
- 11 * curCounterFreq.QuadPart / 10
+ if (curCounter.QuadPart - perfCounterLastCall <
+ 11 * curCounterFreq * timeInfo.calibrationInterv / 10
) {
- curFileTime = fileTimeLastCall.QuadPart +
- ((curCounter.QuadPart - perfCounterLastCall.QuadPart)
- * 10000000 / curCounterFreq.QuadPart);
-
- usecSincePosixEpoch = (curFileTime - posixEpoch.QuadPart) / 10;
- timePtr->sec = (long) (usecSincePosixEpoch / 1000000);
- timePtr->usec = (unsigned long) (usecSincePosixEpoch % 1000000);
- return;
+ /* Calibrated file-time is saved from posix in 100-ns ticks */
+ return NativeCalc100NsTicks(fileTimeLastCall,
+ perfCounterLastCall, curCounterFreq, curCounter.QuadPart) / 10;
}
}
/*
- * High resolution timer is not available. Just use ftime.
+ * High resolution timer is not available.
*/
+ return 0;
+}
+
+/*
+ *----------------------------------------------------------------------
+ *
+ * NativeGetTime --
+ *
+ * TIP #233: Gets the current system time in seconds and microseconds
+ * since the beginning of the epoch: 00:00 UCT, January 1, 1970.
+ *
+ * Results:
+ * Returns the current time in timePtr.
+ *
+ * Side effects:
+ * See NativeGetMicroseconds for more information.
+ *
+ *----------------------------------------------------------------------
+ */
+
+static void
+NativeGetTime(
+ Tcl_Time *timePtr,
+ ClientData clientData)
+{
+ Tcl_WideInt usecSincePosixEpoch;
- _ftime(&t);
- timePtr->sec = (long)t.time;
- timePtr->usec = t.millitm * 1000;
+ /*
+ * Try to use high resolution timer.
+ */
+ if ( (usecSincePosixEpoch = NativeGetMicroseconds()) ) {
+ timePtr->sec = (long) (usecSincePosixEpoch / 1000000);
+ timePtr->usec = (unsigned long) (usecSincePosixEpoch % 1000000);
+ } else {
+ /*
+ * High resolution timer is not available. Just use ftime.
+ */
+
+ struct _timeb t;
+
+ _ftime(&t);
+ timePtr->sec = (long)t.time;
+ timePtr->usec = t.millitm * 1000;
+ }
}
/*
@@ -492,6 +690,8 @@ NativeGetTime(
*----------------------------------------------------------------------
*/
+void TclWinResetTimerResolution(void);
+
static void
StopCalibration(
ClientData unused) /* Client data is unused */
@@ -782,6 +982,8 @@ CalibrationThread(
QueryPerformanceFrequency(&timeInfo.curCounterFreq);
timeInfo.fileTimeLastCall.LowPart = curFileTime.dwLowDateTime;
timeInfo.fileTimeLastCall.HighPart = curFileTime.dwHighDateTime;
+ /* Calibrated file-time will be saved from posix in 100-ns ticks */
+ timeInfo.fileTimeLastCall.QuadPart -= timeInfo.posixEpoch.QuadPart;
ResetCounterSamples(timeInfo.fileTimeLastCall.QuadPart,
timeInfo.perfCounterLastCall.QuadPart,
@@ -841,6 +1043,7 @@ UpdateTimeEachSecond(void)
/* Current value returned from
* QueryPerformanceCounter. */
FILETIME curSysTime; /* Current system time. */
+ static LARGE_INTEGER lastFileTime; /* File time of the previous calibration */
LARGE_INTEGER curFileTime; /* File time at the time this callback was
* scheduled. */
Tcl_WideInt estFreq; /* Estimated perf counter frequency. */
@@ -852,15 +1055,24 @@ UpdateTimeEachSecond(void)
* step over 1 second. */
/*
- * Sample performance counter and system time.
+ * Sample performance counter and system time (from posix epoch).
*/
- QueryPerformanceCounter(&curPerfCounter);
GetSystemTimeAsFileTime(&curSysTime);
curFileTime.LowPart = curSysTime.dwLowDateTime;
curFileTime.HighPart = curSysTime.dwHighDateTime;
+ curFileTime.QuadPart -= timeInfo.posixEpoch.QuadPart;
+ /* If calibration still not needed (check for possible time switch) */
+ if ( curFileTime.QuadPart > lastFileTime.QuadPart
+ && curFileTime.QuadPart < lastFileTime.QuadPart +
+ (timeInfo.calibrationInterv * 10000000)
+ ) {
+ /* again in next one second */
+ return;
+ }
+ QueryPerformanceCounter(&curPerfCounter);
- EnterCriticalSection(&timeInfo.cs);
+ lastFileTime.QuadPart = curFileTime.QuadPart;
/*
* We devide by timeInfo.curCounterFreq.QuadPart in several places. That
@@ -872,7 +1084,6 @@ UpdateTimeEachSecond(void)
*/
if (timeInfo.curCounterFreq.QuadPart == 0){
- LeaveCriticalSection(&timeInfo.cs);
timeInfo.perfCounterAvailable = 0;
return;
}
@@ -911,12 +1122,9 @@ UpdateTimeEachSecond(void)
* is estFreq * 20000000 / (vt1 - vt0)
*/
- vt0 = 10000000 * (curPerfCounter.QuadPart
- - timeInfo.perfCounterLastCall.QuadPart)
- / timeInfo.curCounterFreq.QuadPart
- + timeInfo.fileTimeLastCall.QuadPart;
- vt1 = 20000000 + curFileTime.QuadPart;
-
+ vt0 = NativeCalc100NsTicks(timeInfo.fileTimeLastCall.QuadPart,
+ timeInfo.perfCounterLastCall.QuadPart, timeInfo.curCounterFreq.QuadPart,
+ curPerfCounter.QuadPart);
/*
* If we've gotten more than a second away from system time, then drifting
* the clock is going to be pretty hopeless. Just let it jump. Otherwise,
@@ -925,21 +1133,75 @@ UpdateTimeEachSecond(void)
tdiff = vt0 - curFileTime.QuadPart;
if (tdiff > 10000000 || tdiff < -10000000) {
- timeInfo.fileTimeLastCall.QuadPart = curFileTime.QuadPart;
- timeInfo.curCounterFreq.QuadPart = estFreq;
+ /* jump to current system time, use curent estimated frequency */
+ vt0 = curFileTime.QuadPart;
} else {
- driftFreq = estFreq * 20000000 / (vt1 - vt0);
+ /* calculate new frequency and estimate drift to the next second */
+ vt1 = 20000000 + curFileTime.QuadPart;
+ driftFreq = (estFreq * 20000000 / (vt1 - vt0));
+ /*
+ * Avoid too large drifts (only half of the current difference),
+ * that allows also be more accurate (aspire to the smallest tdiff),
+ * so then we can prolong calibration interval by tdiff < 100000
+ */
+ driftFreq = timeInfo.curCounterFreq.QuadPart +
+ (driftFreq - timeInfo.curCounterFreq.QuadPart) / 2;
+
+ /*
+ * Average between estimated, 2 current and 5 drifted frequencies,
+ * (do the soft drifting as possible)
+ */
+ estFreq = (estFreq + 2 * timeInfo.curCounterFreq.QuadPart + 5 * driftFreq) / 8;
+ }
- if (driftFreq > 1003*estFreq/1000) {
- driftFreq = 1003*estFreq/1000;
- } else if (driftFreq < 997*estFreq/1000) {
- driftFreq = 997*estFreq/1000;
+ /* Avoid too large discrepancy from nominal frequency */
+ if (estFreq > 1003*timeInfo.nominalFreq.QuadPart/1000) {
+ estFreq = 1003*timeInfo.nominalFreq.QuadPart/1000;
+ vt0 = curFileTime.QuadPart;
+ } else if (estFreq < 997*timeInfo.nominalFreq.QuadPart/1000) {
+ estFreq = 997*timeInfo.nominalFreq.QuadPart/1000;
+ vt0 = curFileTime.QuadPart;
+ } else if (vt0 != curFileTime.QuadPart) {
+ /*
+ * Be sure the clock ticks never backwards (avoid it by negative drifting)
+ * just compare native time (in 100-ns) before and hereafter using
+ * new calibrated values) and do a small adjustment (short time freeze)
+ */
+ LARGE_INTEGER newPerfCounter;
+ Tcl_WideInt nt0, nt1;
+
+ QueryPerformanceCounter(&newPerfCounter);
+ nt0 = NativeCalc100NsTicks(timeInfo.fileTimeLastCall.QuadPart,
+ timeInfo.perfCounterLastCall.QuadPart, timeInfo.curCounterFreq.QuadPart,
+ newPerfCounter.QuadPart);
+ nt1 = NativeCalc100NsTicks(vt0,
+ curPerfCounter.QuadPart, estFreq,
+ newPerfCounter.QuadPart);
+ if (nt0 > nt1) { /* drifted backwards, try to compensate with new base */
+ /* first adjust with a micro jump (short frozen time is acceptable) */
+ vt0 += nt0 - nt1;
+ /* if drift unavoidable (e. g. we had a time switch), then reset it */
+ vt1 = vt0 - curFileTime.QuadPart;
+ if (vt1 > 10000000 || vt1 < -10000000) {
+ /* larger jump resp. shift relative new file-time */
+ vt0 = curFileTime.QuadPart;
+ }
}
+ }
+
+ /* In lock commit new values to timeInfo (hold lock as short as possible) */
+ EnterCriticalSection(&timeInfo.cs);
- timeInfo.fileTimeLastCall.QuadPart = vt0;
- timeInfo.curCounterFreq.QuadPart = driftFreq;
+ /* grow calibration interval up to 10 seconds (if still precise enough) */
+ if (tdiff < -100000 || tdiff > 100000) {
+ /* too long drift - reset calibration interval to 1000 second */
+ timeInfo.calibrationInterv = 1;
+ } else if (timeInfo.calibrationInterv < 10) {
+ timeInfo.calibrationInterv++;
}
+ timeInfo.fileTimeLastCall.QuadPart = vt0;
+ timeInfo.curCounterFreq.QuadPart = estFreq;
timeInfo.perfCounterLastCall.QuadPart = curPerfCounter.QuadPart;
LeaveCriticalSection(&timeInfo.cs);