Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Comment: | Merge to feature branch |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | dkf-notifier-poll |
Files: | files | file ages | folders |
SHA1: |
8a0bf2664b860e07e262b93ad97e3b6c |
User & Date: | dkf 2011-08-02 09:12:36 |
2011-08-08
| ||
21:14 | Merge to feature branch check-in: 5f90ef1bc2 user: dkf tags: dkf-notifier-poll | |
2011-08-02
| ||
09:12 | Merge to feature branch check-in: 8a0bf2664b user: dkf tags: dkf-notifier-poll | |
09:07 | [Bug 3384007]: Fix some panic messages. check-in: 783c413131 user: dkf tags: trunk | |
2011-07-28
| ||
14:26 | Merge to feature branch check-in: cd522f12fc user: dkf tags: dkf-notifier-poll | |
Changes to ChangeLog.
1 2 3 4 5 6 7 | 2011-07-26 Donal K. Fellows <[email protected]> * generic/tclOO.c (initScript): Ensure that TclOO is properly found by all the various package mechanisms (by adding a dummy ifneeded script) and not just some of them. 2011-07-21 Jan Nijtmans <[email protected]> | > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 | 2011-08-02 Donal K. Fellows <[email protected]> * generic/tclObj.c (Tcl_DbIncrRefCount, Tcl_DbDecrRefCount) (Tcl_DbIsShared): [Bug 3384007]: Fix the panic messages so they share what should be shared and have the right number of spaces. 2011-08-01 Miguel Sofer <[email protected]> * generic/tclProc.c (TclProcCompileProc): [Bug 3383616]: Fix for leak of resolveInfo when recompiling procs. Thanks go to Gustaf Neumann for detecting the bug and providing the fix. 2011-08-01 Donal K. Fellows <[email protected]> * doc/tclvars.n (EXAMPLES): Added some examples of how some of the standard global variables can be used, following prompting by a request by Robert Hicks. * tools/tcltk-man2html.tcl (plus-pkgs): [Bug 3382474]: Added code to determine the version number of contributed packages from their directory names so that HTML documentation builds are less confusing. 2011-07-29 Donal K. Fellows <[email protected]> * tools/tcltk-man2html.tcl (ensemble_commands, remap_link_target): Small enhancements to improve cross-linking with contributed packages. * tools/tcltk-man2html-utils.tcl (insert-cross-references): Enhance to cope with contributed packages' C API. 2011-07-28 Reinhard Max <[email protected]> * unix/tcl.m4 (SC_TCL_IPV6): Fix AC_DEFINE invocation for NEED_FAKE_RFC2553. * unix/configure: autoconf-2.59 2011-07-28 Don Porter <[email protected]> * changes: Updates for 8.6b2 release. * library/tzdata/Asia/Anadyr: Update to Olson's tzdata2011h * library/tzdata/Asia/Irkutsk: * library/tzdata/Asia/Kamchatka: * library/tzdata/Asia/Krasnoyarsk: * library/tzdata/Asia/Magadan: * library/tzdata/Asia/Novokuznetsk: * library/tzdata/Asia/Novosibirsk: * library/tzdata/Asia/Omsk: * library/tzdata/Asia/Sakhalin: * library/tzdata/Asia/Vladivostok: * library/tzdata/Asia/Yakutsk: * library/tzdata/Asia/Yekaterinburg: * library/tzdata/Europe/Kaliningrad: * library/tzdata/Europe/Moscow: * library/tzdata/Europe/Samara: * library/tzdata/Europe/Volgograd: * library/tzdata/America/Kralendijk: (new) * library/tzdata/America/Lower_Princes: (new) 2011-07-26 Donal K. Fellows <[email protected]> * generic/tclOO.c (initScript): Ensure that TclOO is properly found by all the various package mechanisms (by adding a dummy ifneeded script) and not just some of them. 2011-07-21 Jan Nijtmans <[email protected]> |
︙ | ︙ |
Changes to changes.
︙ | ︙ | |||
7864 7865 7866 7867 7868 7869 7870 7871 7872 7873 7874 7875 7876 7877 7878 7879 7880 7881 7882 7883 7884 7885 7886 7887 7888 7889 7890 7891 | 2010-11-04 improved testing of sockets (max) 2010-11-05 (frq)[491789] setargv/unicode cmdline for MSVC (nijtmans) 2010-11-09 (bug fix)[3105999] fixed memleak in OO var resolver (fellows) 2010-11-15 (TIP 378)[3081184] improved TIP 280 performance (kupries) 2010-11-18 (bug fix)[3111059] leak in [namespace delete] w coroutines (sofer) 2010-11-28 [3120139,3105247] Tcl_PrintDouble improvements (kenny) 2010-11-29 (new cmd) [tcl::unsupported::inject] (ferrieux,sofer) 2010-11-30 (enhancement) Restore TclFormatInt for performance (hobbs) 2010-12-09 (new feature) [file] is now a [namespace ensemble] (fellows) 2010-12-12 (platform) OpenBSD build improvements (cassoff) 2010-12-17 (platform) Revisions to support rpm 4.4.2 (cassoff) 2010-12-30 (bug fix)[3142026] GrowEvaluationStack OBOE (harder,sofer) 2011-01-18 (bug fix)[3001438] [info frame -1] crash (mccormack,fellows) 2011-03-01 (performance)[3168398] optimize [interp cancel] (mistachkin) | > > > > > > | 7864 7865 7866 7867 7868 7869 7870 7871 7872 7873 7874 7875 7876 7877 7878 7879 7880 7881 7882 7883 7884 7885 7886 7887 7888 7889 7890 7891 7892 7893 7894 7895 7896 7897 | 2010-11-04 improved testing of sockets (max) 2010-11-05 (frq)[491789] setargv/unicode cmdline for MSVC (nijtmans) 2010-11-09 (bug fix)[3105999] fixed memleak in OO var resolver (fellows) 2010-11-15 (TIP 378)[3081184] improved TIP 280 performance (kupries) 2010-11-16 (platform) VS 2005 SP1 MSVC compiler (nijtmans) 2010-11-18 (bug fix)[3111059] leak in [namespace delete] w coroutines (sofer) 2010-11-28 [3120139,3105247] Tcl_PrintDouble improvements (kenny) 2010-11-29 (new cmd) [tcl::unsupported::inject] (ferrieux,sofer) 2010-11-30 (enhancement) Restore TclFormatInt for performance (hobbs) 2010-12-09 (new feature) [file] is now a [namespace ensemble] (fellows) 2010-12-19 (bug fix) [fcopy -size 1 -command] asynchronous (ferrieux) 2010-12-12 (platform) OpenBSD build improvements (cassoff) 2010-12-17 (platform) Revisions to support rpm 4.4.2 (cassoff) 2010-12-27 (bug fix) crash in [lsort] w multiple -index options (fellows) 2010-12-30 (bug fix)[3142026] GrowEvaluationStack OBOE (harder,sofer) 2011-01-18 (bug fix)[3001438] [info frame -1] crash (mccormack,fellows) 2011-03-01 (performance)[3168398] optimize [interp cancel] (mistachkin) |
︙ | ︙ | |||
7924 7925 7926 7927 7928 7929 7930 | 2011-05-05 (enhancement) dict->list w/o string rep generation (porter) 2011-05-10 (bug fix)[3173086] Crash parsing long lists (rogers,porter) 2011-05-24 (enhancement) msgcat internal improvements (fellows) => msgcat 1.4.4 | < < > > > > | | 7930 7931 7932 7933 7934 7935 7936 7937 7938 7939 7940 7941 7942 7943 7944 7945 7946 7947 7948 7949 7950 7951 7952 7953 7954 | 2011-05-05 (enhancement) dict->list w/o string rep generation (porter) 2011-05-10 (bug fix)[3173086] Crash parsing long lists (rogers,porter) 2011-05-24 (enhancement) msgcat internal improvements (fellows) => msgcat 1.4.4 2011-05-25 (TIP 381) [info object|class call] [self call] [nextto] (fellows) 2011-05-31 (bug fix)[3293874] let lists grow all the way to the limit (porter) 2011-06-02 (bug fix)[3185407] cmd resolution epoch flaw (nadkarni,fellows) 2011-06-13 (bug fix)[3315098] mem leak generating double string rep (neumann) 2011-06-22 (new feature) DEB_HOST_MULTIARCH support (kupries) => platform 1.0.10 2011-07-15 (bug fix)[3357771] Prevent circular refs in bytecode (porter) 2011-07-28 tzdata updated to Olson's tzdata2011h (porter) Many more Tcl built-in command errors now set an -errorcode. --- Released 8.6b2, August 3, 2011 --- See ChangeLog for details --- |
Changes to doc/tclvars.n.
︙ | ︙ | |||
481 482 483 484 485 486 487 488 489 490 491 492 493 494 | hold the version number for this version of Tcl in the form \fIx.y\fR. Changes to \fIx\fR represent major changes with probable incompatibilities and changes to \fIy\fR represent small enhancements and bug fixes that retain backward compatibility. The value of this variable is returned by the \fBinfo tclversion\fR command. .SH "OTHER GLOBAL VARIABLES" The following variables are only guaranteed to exist in \fBtclsh\fR and \fBwish\fR executables; the Tcl library does not define them itself but many Tcl environments do. .TP 6 \fBargc\fR . The number of arguments to \fBtclsh\fR or \fBwish\fR. | > | 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 | hold the version number for this version of Tcl in the form \fIx.y\fR. Changes to \fIx\fR represent major changes with probable incompatibilities and changes to \fIy\fR represent small enhancements and bug fixes that retain backward compatibility. The value of this variable is returned by the \fBinfo tclversion\fR command. .SH "OTHER GLOBAL VARIABLES" .PP The following variables are only guaranteed to exist in \fBtclsh\fR and \fBwish\fR executables; the Tcl library does not define them itself but many Tcl environments do. .TP 6 \fBargc\fR . The number of arguments to \fBtclsh\fR or \fBwish\fR. |
︙ | ︙ | |||
504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 | was invoked. .TP 6 \fBtcl_interactive\fR . Contains 1 if \fBtclsh\fR or \fBwish\fR is running interactively (no script was specified and standard input is a terminal-like device), 0 otherwise. .SH "SEE ALSO" eval(n), library(n), tclsh(1), tkvars(n), wish(1) .SH KEYWORDS arithmetic, bytecode, compiler, error, environment, POSIX, precision, subprocess, user, variables '\" Local Variables: '\" mode: nroff '\" End: | > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 | was invoked. .TP 6 \fBtcl_interactive\fR . Contains 1 if \fBtclsh\fR or \fBwish\fR is running interactively (no script was specified and standard input is a terminal-like device), 0 otherwise. .SH EXAMPLES .PP To add a directory to the collection of locations searched by \fBpackage require\fR, e.g., because of some application-specific packages that are used, the \fBauto_path\fR variable needs to be updated: .PP .CS lappend ::\fBauto_path\fR [file join [pwd] "theLibDir"] .CE .PP A simple though not very robust way to handle command line arguments of the form .QW "\-foo 1 \-bar 2" is to load them into an array having first loaded in the default settings: .CS array set arguments {-foo 0 -bar 0 -grill 0} array set arguments $::\fBargv\fR puts "foo is $arguments(-foo)" puts "bar is $arguments(-bar)" puts "grill is $arguments(-grill)" .CE .PP The \fBargv0\fR global variable can be used (in conjunction with the \fBinfo script\fR command) to determine whether the current script is being executed as the main script or loaded as a library. This is useful because it allows a single script to be used as both a library and a demonstration of that library: .PP .CS if {$::\fBargv0\fR eq [info script]} { # running as: tclsh example.tcl } else { package provide Example 1.0 } .CE .SH "SEE ALSO" eval(n), library(n), tclsh(1), tkvars(n), wish(1) .SH KEYWORDS arithmetic, bytecode, compiler, error, environment, POSIX, precision, subprocess, user, variables '\" Local Variables: '\" mode: nroff '\" End: |
Changes to generic/tclObj.c.
︙ | ︙ | |||
3709 3710 3711 3712 3713 3714 3715 | /* * Check to make sure that the Tcl_Obj was allocated by the current * thread. Don't do this check when shutting down since thread local * storage can be finalized before the last Tcl_Obj is freed. */ if (!TclInExit()) { | > | < < | | < | | | 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 | /* * Check to make sure that the Tcl_Obj was allocated by the current * thread. Don't do this check when shutting down since thread local * storage can be finalized before the last Tcl_Obj is freed. */ if (!TclInExit()) { ThreadSpecificData *tsdPtr = TCL_TSD_INIT(&dataKey); Tcl_HashTable *tablePtr = tsdPtr->objThreadMap; Tcl_HashEntry *hPtr; if (!tablePtr) { Tcl_Panic("object table not initialized"); } hPtr = Tcl_FindHashEntry(tablePtr, objPtr); if (!hPtr) { Tcl_Panic("Trying to %s of Tcl_Obj allocated in another thread", "incr ref count"); } } # endif /* TCL_THREADS */ #endif /* TCL_MEM_DEBUG */ ++(objPtr)->refCount; } /* *---------------------------------------------------------------------- * * Tcl_DbDecrRefCount -- |
︙ | ︙ | |||
3774 3775 3776 3777 3778 3779 3780 | /* * Check to make sure that the Tcl_Obj was allocated by the current * thread. Don't do this check when shutting down since thread local * storage can be finalized before the last Tcl_Obj is freed. */ if (!TclInExit()) { | > | < < | | < | | > | 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 | /* * Check to make sure that the Tcl_Obj was allocated by the current * thread. Don't do this check when shutting down since thread local * storage can be finalized before the last Tcl_Obj is freed. */ if (!TclInExit()) { ThreadSpecificData *tsdPtr = TCL_TSD_INIT(&dataKey); Tcl_HashTable *tablePtr = tsdPtr->objThreadMap; Tcl_HashEntry *hPtr; if (!tablePtr) { Tcl_Panic("object table not initialized"); } hPtr = Tcl_FindHashEntry(tablePtr, objPtr); if (!hPtr) { Tcl_Panic("Trying to %s of Tcl_Obj allocated in another thread", "decr ref count"); } /* * If the Tcl_Obj is going to be deleted, remove the entry. */ if ((objPtr->refCount - 1) <= 0) { ObjData *objData = Tcl_GetHashValue(hPtr); if (objData != NULL) { ckfree(objData); } Tcl_DeleteHashEntry(hPtr); } } # endif /* TCL_THREADS */ #endif /* TCL_MEM_DEBUG */ if (--(objPtr)->refCount <= 0) { TclFreeObj(objPtr); } } /* *---------------------------------------------------------------------- |
︙ | ︙ | |||
3854 3855 3856 3857 3858 3859 3860 | /* * Check to make sure that the Tcl_Obj was allocated by the current * thread. Don't do this check when shutting down since thread local * storage can be finalized before the last Tcl_Obj is freed. */ if (!TclInExit()) { | > | | < | | < | | | | 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 | /* * Check to make sure that the Tcl_Obj was allocated by the current * thread. Don't do this check when shutting down since thread local * storage can be finalized before the last Tcl_Obj is freed. */ if (!TclInExit()) { ThreadSpecificData *tsdPtr = TCL_TSD_INIT(&dataKey); Tcl_HashTable *tablePtr = tsdPtr->objThreadMap; Tcl_HashEntry *hPtr; if (!tablePtr) { Tcl_Panic("object table not initialized"); } hPtr = Tcl_FindHashEntry(tablePtr, objPtr); if (!hPtr) { Tcl_Panic("Trying to %s of Tcl_Obj allocated in another thread", "check shared status"); } } # endif /* TCL_THREADS */ #endif /* TCL_MEM_DEBUG */ #ifdef TCL_COMPILE_STATS Tcl_MutexLock(&tclObjMutex); if ((objPtr)->refCount <= 1) { tclObjsShared[1]++; } else if ((objPtr)->refCount < TCL_MAX_SHARED_OBJ_STATS) { tclObjsShared[(objPtr)->refCount]++; } else { tclObjsShared[0]++; } Tcl_MutexUnlock(&tclObjMutex); #endif /* TCL_COMPILE_STATS */ return ((objPtr)->refCount > 1); } /* *---------------------------------------------------------------------- * |
︙ | ︙ |
Changes to generic/tclProc.c.
︙ | ︙ | |||
2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 | procPtr->firstLocalPtr = NULL; } procPtr->lastLocalPtr = lastPtr; while (clPtr) { CompiledLocal *toFree = clPtr; clPtr = clPtr->nextPtr; ckfree(toFree); } procPtr->numCompiledLocals = procPtr->numArgs; } TclPushStackFrame(interp, &framePtr, (Tcl_Namespace *) nsPtr, /* isProcCallFrame */ 0); | > > > > > > > | 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 | procPtr->firstLocalPtr = NULL; } procPtr->lastLocalPtr = lastPtr; while (clPtr) { CompiledLocal *toFree = clPtr; clPtr = clPtr->nextPtr; if (toFree->resolveInfo) { if (toFree->resolveInfo->deleteProc) { toFree->resolveInfo->deleteProc(toFree->resolveInfo); } else { ckfree(toFree->resolveInfo); } } ckfree(toFree); } procPtr->numCompiledLocals = procPtr->numArgs; } TclPushStackFrame(interp, &framePtr, (Tcl_Namespace *) nsPtr, /* isProcCallFrame */ 0); |
︙ | ︙ |
Added library/tzdata/America/Kralendijk.
> > > > > | 1 2 3 4 5 | # created by tools/tclZIC.tcl - do not edit if {![info exists TZData(America/Curacao)]} { LoadTimeZoneFile America/Curacao } set TZData(:America/Kralendijk) $TZData(:America/Curacao) |
Added library/tzdata/America/Lower_Princes.
> > > > > | 1 2 3 4 5 | # created by tools/tclZIC.tcl - do not edit if {![info exists TZData(America/Curacao)]} { LoadTimeZoneFile America/Curacao } set TZData(:America/Lower_Princes) $TZData(:America/Curacao) |
Changes to library/tzdata/Asia/Anadyr.
︙ | ︙ | |||
64 65 66 67 68 69 70 | {1206799200 46800 1 ANAST} {1224943200 43200 0 ANAT} {1238248800 46800 1 ANAST} {1256392800 43200 0 ANAT} {1269698400 39600 0 ANAMMTT} {1269702000 43200 1 ANAST} {1288450800 39600 0 ANAT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 64 65 66 67 68 69 70 71 72 | {1206799200 46800 1 ANAST} {1224943200 43200 0 ANAT} {1238248800 46800 1 ANAST} {1256392800 43200 0 ANAT} {1269698400 39600 0 ANAMMTT} {1269702000 43200 1 ANAST} {1288450800 39600 0 ANAT} {1301151600 43200 0 ANAT} } |
Changes to library/tzdata/Asia/Irkutsk.
︙ | ︙ | |||
63 64 65 66 67 68 69 | {1193508000 28800 0 IRKT} {1206813600 32400 1 IRKST} {1224957600 28800 0 IRKT} {1238263200 32400 1 IRKST} {1256407200 28800 0 IRKT} {1269712800 32400 1 IRKST} {1288461600 28800 0 IRKT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 63 64 65 66 67 68 69 70 71 | {1193508000 28800 0 IRKT} {1206813600 32400 1 IRKST} {1224957600 28800 0 IRKT} {1238263200 32400 1 IRKST} {1256407200 28800 0 IRKT} {1269712800 32400 1 IRKST} {1288461600 28800 0 IRKT} {1301162400 32400 0 IRKT} } |
Changes to library/tzdata/Asia/Kamchatka.
︙ | ︙ | |||
63 64 65 66 67 68 69 | {1206799200 46800 1 PETST} {1224943200 43200 0 PETT} {1238248800 46800 1 PETST} {1256392800 43200 0 PETT} {1269698400 39600 0 PETMMTT} {1269702000 43200 1 PETST} {1288450800 39600 0 PETT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 63 64 65 66 67 68 69 70 71 | {1206799200 46800 1 PETST} {1224943200 43200 0 PETT} {1238248800 46800 1 PETST} {1256392800 43200 0 PETT} {1269698400 39600 0 PETMMTT} {1269702000 43200 1 PETST} {1288450800 39600 0 PETT} {1301151600 43200 0 PETT} } |
Changes to library/tzdata/Asia/Krasnoyarsk.
︙ | ︙ | |||
62 63 64 65 66 67 68 | {1193511600 25200 0 KRAT} {1206817200 28800 1 KRAST} {1224961200 25200 0 KRAT} {1238266800 28800 1 KRAST} {1256410800 25200 0 KRAT} {1269716400 28800 1 KRAST} {1288465200 25200 0 KRAT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 62 63 64 65 66 67 68 69 70 | {1193511600 25200 0 KRAT} {1206817200 28800 1 KRAST} {1224961200 25200 0 KRAT} {1238266800 28800 1 KRAST} {1256410800 25200 0 KRAT} {1269716400 28800 1 KRAST} {1288465200 25200 0 KRAT} {1301166000 28800 0 KRAT} } |
Changes to library/tzdata/Asia/Magadan.
︙ | ︙ | |||
62 63 64 65 66 67 68 | {1193497200 39600 0 MAGT} {1206802800 43200 1 MAGST} {1224946800 39600 0 MAGT} {1238252400 43200 1 MAGST} {1256396400 39600 0 MAGT} {1269702000 43200 1 MAGST} {1288450800 39600 0 MAGT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 62 63 64 65 66 67 68 69 70 | {1193497200 39600 0 MAGT} {1206802800 43200 1 MAGST} {1224946800 39600 0 MAGT} {1238252400 43200 1 MAGST} {1256396400 39600 0 MAGT} {1269702000 43200 1 MAGST} {1288450800 39600 0 MAGT} {1301151600 43200 0 MAGT} } |
Changes to library/tzdata/Asia/Novokuznetsk.
︙ | ︙ | |||
63 64 65 66 67 68 69 | {1206817200 28800 1 KRAST} {1224961200 25200 0 KRAT} {1238266800 28800 1 KRAST} {1256410800 25200 0 KRAT} {1269716400 21600 0 NOVMMTT} {1269720000 25200 1 NOVST} {1288468800 21600 0 NOVT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 63 64 65 66 67 68 69 70 71 | {1206817200 28800 1 KRAST} {1224961200 25200 0 KRAT} {1238266800 28800 1 KRAST} {1256410800 25200 0 KRAT} {1269716400 21600 0 NOVMMTT} {1269720000 25200 1 NOVST} {1288468800 21600 0 NOVT} {1301169600 25200 0 NOVT} } |
Changes to library/tzdata/Asia/Novosibirsk.
︙ | ︙ | |||
63 64 65 66 67 68 69 | {1193515200 21600 0 NOVT} {1206820800 25200 1 NOVST} {1224964800 21600 0 NOVT} {1238270400 25200 1 NOVST} {1256414400 21600 0 NOVT} {1269720000 25200 1 NOVST} {1288468800 21600 0 NOVT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 63 64 65 66 67 68 69 70 71 | {1193515200 21600 0 NOVT} {1206820800 25200 1 NOVST} {1224964800 21600 0 NOVT} {1238270400 25200 1 NOVST} {1256414400 21600 0 NOVT} {1269720000 25200 1 NOVST} {1288468800 21600 0 NOVT} {1301169600 25200 0 NOVT} } |
Changes to library/tzdata/Asia/Omsk.
︙ | ︙ | |||
62 63 64 65 66 67 68 | {1193515200 21600 0 OMST} {1206820800 25200 1 OMSST} {1224964800 21600 0 OMST} {1238270400 25200 1 OMSST} {1256414400 21600 0 OMST} {1269720000 25200 1 OMSST} {1288468800 21600 0 OMST} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 62 63 64 65 66 67 68 69 70 | {1193515200 21600 0 OMST} {1206820800 25200 1 OMSST} {1224964800 21600 0 OMST} {1238270400 25200 1 OMSST} {1256414400 21600 0 OMST} {1269720000 25200 1 OMSST} {1288468800 21600 0 OMST} {1301169600 25200 0 OMST} } |
Changes to library/tzdata/Asia/Sakhalin.
︙ | ︙ | |||
64 65 66 67 68 69 70 | {1193500800 36000 0 SAKT} {1206806400 39600 1 SAKST} {1224950400 36000 0 SAKT} {1238256000 39600 1 SAKST} {1256400000 36000 0 SAKT} {1269705600 39600 1 SAKST} {1288454400 36000 0 SAKT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 64 65 66 67 68 69 70 71 72 | {1193500800 36000 0 SAKT} {1206806400 39600 1 SAKST} {1224950400 36000 0 SAKT} {1238256000 39600 1 SAKST} {1256400000 36000 0 SAKT} {1269705600 39600 1 SAKST} {1288454400 36000 0 SAKT} {1301155200 39600 0 SAKT} } |
Changes to library/tzdata/Asia/Vladivostok.
︙ | ︙ | |||
62 63 64 65 66 67 68 | {1193500800 36000 0 VLAT} {1206806400 39600 1 VLAST} {1224950400 36000 0 VLAT} {1238256000 39600 1 VLAST} {1256400000 36000 0 VLAT} {1269705600 39600 1 VLAST} {1288454400 36000 0 VLAT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 62 63 64 65 66 67 68 69 70 | {1193500800 36000 0 VLAT} {1206806400 39600 1 VLAST} {1224950400 36000 0 VLAT} {1238256000 39600 1 VLAST} {1256400000 36000 0 VLAT} {1269705600 39600 1 VLAST} {1288454400 36000 0 VLAT} {1301155200 39600 0 VLAT} } |
Changes to library/tzdata/Asia/Yakutsk.
︙ | ︙ | |||
62 63 64 65 66 67 68 | {1193504400 32400 0 YAKT} {1206810000 36000 1 YAKST} {1224954000 32400 0 YAKT} {1238259600 36000 1 YAKST} {1256403600 32400 0 YAKT} {1269709200 36000 1 YAKST} {1288458000 32400 0 YAKT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 62 63 64 65 66 67 68 69 70 | {1193504400 32400 0 YAKT} {1206810000 36000 1 YAKST} {1224954000 32400 0 YAKT} {1238259600 36000 1 YAKST} {1256403600 32400 0 YAKT} {1269709200 36000 1 YAKST} {1288458000 32400 0 YAKT} {1301158800 36000 0 YAKT} } |
Changes to library/tzdata/Asia/Yekaterinburg.
︙ | ︙ | |||
62 63 64 65 66 67 68 | {1193518800 18000 0 YEKT} {1206824400 21600 1 YEKST} {1224968400 18000 0 YEKT} {1238274000 21600 1 YEKST} {1256418000 18000 0 YEKT} {1269723600 21600 1 YEKST} {1288472400 18000 0 YEKT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 62 63 64 65 66 67 68 69 70 | {1193518800 18000 0 YEKT} {1206824400 21600 1 YEKST} {1224968400 18000 0 YEKT} {1238274000 21600 1 YEKST} {1256418000 18000 0 YEKT} {1269723600 21600 1 YEKST} {1288472400 18000 0 YEKT} {1301173200 21600 0 YEKT} } |
Changes to library/tzdata/Europe/Kaliningrad.
︙ | ︙ | |||
76 77 78 79 80 81 82 | {1193529600 7200 0 EET} {1206835200 10800 1 EEST} {1224979200 7200 0 EET} {1238284800 10800 1 EEST} {1256428800 7200 0 EET} {1269734400 10800 1 EEST} {1288483200 7200 0 EET} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 76 77 78 79 80 81 82 83 84 | {1193529600 7200 0 EET} {1206835200 10800 1 EEST} {1224979200 7200 0 EET} {1238284800 10800 1 EEST} {1256428800 7200 0 EET} {1269734400 10800 1 EEST} {1288483200 7200 0 EET} {1301184000 10800 0 EET} } |
Changes to library/tzdata/Europe/Moscow.
︙ | ︙ | |||
75 76 77 78 79 80 81 | {1193526000 10800 0 MSK} {1206831600 14400 1 MSD} {1224975600 10800 0 MSK} {1238281200 14400 1 MSD} {1256425200 10800 0 MSK} {1269730800 14400 1 MSD} {1288479600 10800 0 MSK} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 75 76 77 78 79 80 81 82 83 | {1193526000 10800 0 MSK} {1206831600 14400 1 MSD} {1224975600 10800 0 MSK} {1238281200 14400 1 MSD} {1256425200 10800 0 MSK} {1269730800 14400 1 MSD} {1288479600 10800 0 MSK} {1301180400 14400 0 MSK} } |
Changes to library/tzdata/Europe/Samara.
︙ | ︙ | |||
65 66 67 68 69 70 71 | {1206828000 18000 1 SAMST} {1224972000 14400 0 SAMT} {1238277600 18000 1 SAMST} {1256421600 14400 0 SAMT} {1269727200 10800 0 SAMMMTT} {1269730800 14400 1 SAMST} {1288479600 10800 0 SAMT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 65 66 67 68 69 70 71 72 73 | {1206828000 18000 1 SAMST} {1224972000 14400 0 SAMT} {1238277600 18000 1 SAMST} {1256421600 14400 0 SAMT} {1269727200 10800 0 SAMMMTT} {1269730800 14400 1 SAMST} {1288479600 10800 0 SAMT} {1301180400 14400 0 SAMT} } |
Changes to library/tzdata/Europe/Volgograd.
︙ | ︙ | |||
62 63 64 65 66 67 68 | {1193526000 10800 0 VOLT} {1206831600 14400 1 VOLST} {1224975600 10800 0 VOLT} {1238281200 14400 1 VOLST} {1256425200 10800 0 VOLT} {1269730800 14400 1 VOLST} {1288479600 10800 0 VOLT} | | < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < | 62 63 64 65 66 67 68 69 70 | {1193526000 10800 0 VOLT} {1206831600 14400 1 VOLST} {1224975600 10800 0 VOLT} {1238281200 14400 1 VOLST} {1256425200 10800 0 VOLT} {1269730800 14400 1 VOLST} {1288479600 10800 0 VOLT} {1301180400 14400 0 VOLT} } |
Changes to tests/encoding.test.
1 | # This file contains a collection of tests for tclEncoding.c | | | | | < > | | < > > > > < | | | > > < | | > | > < | | > | > < | | < < > > > > > < | | > | > < | | | | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 | # This file contains a collection of tests for tclEncoding.c # Sourcing this file into Tcl runs the tests and generates output for errors. # No output means no errors were found. # # Copyright (c) 1997 Sun Microsystems, Inc. # Copyright (c) 1998-1999 by Scriptics Corporation. # # See the file "license.terms" for information on usage and redistribution of # this file, and for a DISCLAIMER OF ALL WARRANTIES. package require tcltest 2 namespace eval ::tcl::test::encoding { variable x namespace import -force ::tcltest::* proc toutf {args} { variable x lappend x "toutf $args" } proc fromutf {args} { variable x lappend x "fromutf $args" } proc runtests {} { variable x # Some tests require the testencoding command testConstraint testencoding [llength [info commands testencoding]] testConstraint exec [llength [info commands exec]] testConstraint testgetdefenc [llength [info commands testgetdefenc]] # TclInitEncodingSubsystem is tested by the rest of this file # TclFinalizeEncodingSubsystem is not currently tested test encoding-1.1 {Tcl_GetEncoding: system encoding} -setup { set old [encoding system] } -constraints {testencoding} -body { testencoding create foo [namespace origin toutf] [namespace origin fromutf] encoding system foo set x {} encoding convertto abcd return $x } -cleanup { encoding system $old testencoding delete foo } -result {{fromutf }} test encoding-1.2 {Tcl_GetEncoding: existing encoding} {testencoding} { testencoding create foo [namespace origin toutf] [namespace origin fromutf] set x {} encoding convertto foo abcd testencoding delete foo return $x } {{fromutf }} test encoding-1.3 {Tcl_GetEncoding: load encoding} { list [encoding convertto jis0208 \u4e4e] \ [encoding convertfrom jis0208 8C] } "8C \u4e4e" test encoding-2.1 {Tcl_FreeEncoding: refcount == 0} { encoding convertto jis0208 \u4e4e } {8C} test encoding-2.2 {Tcl_FreeEncoding: refcount != 0} -setup { set system [encoding system] set path [encoding dirs] } -constraints {testencoding} -body { encoding system shiftjis ;# incr ref count encoding dirs [list [pwd]] set x [encoding convertto shiftjis \u4e4e] ;# old one found encoding system identity llength shiftjis ;# Shimmer away any cache of Tcl_Encoding lappend x [catch {encoding convertto shiftjis \u4e4e} msg] $msg } -cleanup { encoding system identity encoding dirs $path encoding system $system } -result "\u008c\u00c1 1 {unknown encoding \"shiftjis\"}" test encoding-3.1 {Tcl_GetEncodingName, NULL} -setup { set old [encoding system] } -body { encoding system shiftjis encoding system } -cleanup { encoding system $old } -result {shiftjis} test encoding-3.2 {Tcl_GetEncodingName, non-null} -setup { set old [fconfigure stdout -encoding] } -body { fconfigure stdout -encoding jis0208 fconfigure stdout -encoding } -cleanup { fconfigure stdout -encoding $old } -result {jis0208} test encoding-4.1 {Tcl_GetEncodingNames} -constraints {testencoding} -setup { cd [makeDirectory tmp] makeDirectory [file join tmp encoding] set path [encoding dirs] encoding dirs {} catch {unset encodings} catch {unset x} } -body { foreach encoding [encoding names] { set encodings($encoding) 1 } makeFile {} [file join tmp encoding junk.enc] makeFile {} [file join tmp encoding junk2.enc] encoding dirs [list [file join [pwd] encoding]] foreach encoding [encoding names] { if {![info exists encodings($encoding)]} { lappend x $encoding } } lsort $x } -cleanup { encoding dirs $path cd [workingDirectory] removeFile [file join tmp encoding junk2.enc] removeFile [file join tmp encoding junk.enc] removeDirectory [file join tmp encoding] removeDirectory tmp } -result {junk junk2} test encoding-5.1 {Tcl_SetSystemEncoding} -setup { set old [encoding system] } -body { encoding system jis0208 encoding convertto \u4e4e } -cleanup { encoding system identity encoding system $old } -result {8C} test encoding-5.2 {Tcl_SetSystemEncoding: test ref count} { set old [encoding system] encoding system $old string compare $old [encoding system] } {0} test encoding-6.1 {Tcl_CreateEncoding: new} {testencoding} { testencoding create foo [namespace code {toutf 1}] \ [namespace code {fromutf 2}] set x {} encoding convertfrom foo abcd encoding convertto foo abcd testencoding delete foo return $x } {{toutf 1} {fromutf 2}} test encoding-6.2 {Tcl_CreateEncoding: replace encoding} {testencoding} { testencoding create foo [namespace code {toutf a}] \ [namespace code {fromutf b}] set x {} encoding convertfrom foo abcd encoding convertto foo abcd testencoding delete foo return $x } {{toutf a} {fromutf b}} test encoding-7.1 {Tcl_ExternalToUtfDString: small buffer} { encoding convertfrom jis0208 8c8c8c8c } "\u543e\u543e\u543e\u543e" test encoding-7.2 {Tcl_UtfToExternalDString: big buffer} { set a 8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C8C |
︙ | ︙ | |||
169 170 171 172 173 174 175 | puts -nonewline $f "ab\x8c\xc1g" close $f set f [open [file join [temporaryDirectory] dummy] r] fconfigure $f -translation binary -encoding shiftjis set x [read $f] close $f file delete [file join [temporaryDirectory] dummy] | | | 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 | puts -nonewline $f "ab\x8c\xc1g" close $f set f [open [file join [temporaryDirectory] dummy] r] fconfigure $f -translation binary -encoding shiftjis set x [read $f] close $f file delete [file join [temporaryDirectory] dummy] return $x } "ab\u4e4eg" test encoding-9.1 {Tcl_UtfToExternalDString: small buffer} { encoding convertto jis0208 "\u543e\u543e\u543e\u543e" } {8c8c8c8c} test encoding-9.2 {Tcl_UtfToExternalDString: big buffer} { set a \u4e4e\u4e4e\u4e4e\u4e4e\u4e4e\u4e4e\u4e4e\u4e4e |
︙ | ︙ | |||
197 198 199 200 201 202 203 | puts -nonewline $f "ab\u4e4eg" close $f set f [open [file join [temporaryDirectory] dummy] r] fconfigure $f -translation binary -encoding iso8859-1 set x [read $f] close $f file delete [file join [temporaryDirectory] dummy] | | | 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 | puts -nonewline $f "ab\u4e4eg" close $f set f [open [file join [temporaryDirectory] dummy] r] fconfigure $f -translation binary -encoding iso8859-1 set x [read $f] close $f file delete [file join [temporaryDirectory] dummy] return $x } "ab\x8c\xc1g" proc viewable {str} { set res "" foreach c [split $str {}] { if {[string is print $c] && [string is ascii $c]} { append res $c |
︙ | ︙ | |||
238 239 240 241 242 243 244 | } "\u4e4e" test encoding-11.5 {LoadEncodingFile: escape file} { viewable [encoding convertto iso2022 \u4e4e] } [viewable "\x1b\$B8C\x1b(B"] test encoding-11.5.1 {LoadEncodingFile: escape file} { viewable [encoding convertto iso2022-jp \u4e4e] } [viewable "\x1b\$B8C\x1b(B"] | | > | > < | | 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 | } "\u4e4e" test encoding-11.5 {LoadEncodingFile: escape file} { viewable [encoding convertto iso2022 \u4e4e] } [viewable "\x1b\$B8C\x1b(B"] test encoding-11.5.1 {LoadEncodingFile: escape file} { viewable [encoding convertto iso2022-jp \u4e4e] } [viewable "\x1b\$B8C\x1b(B"] test encoding-11.6 {LoadEncodingFile: invalid file} -constraints {testencoding} -setup { set system [encoding system] set path [encoding dirs] encoding system identity } -body { cd [temporaryDirectory] encoding dirs [file join tmp encoding] makeDirectory tmp makeDirectory [file join tmp encoding] set f [open [file join tmp encoding splat.enc] w] fconfigure $f -translation binary puts $f "abcdefghijklmnop" close $f encoding convertto splat \u4e4e } -returnCodes error -cleanup { file delete [file join [temporaryDirectory] tmp encoding splat.enc] removeDirectory [file join tmp encoding] removeDirectory tmp cd [workingDirectory] encoding dirs $path encoding system $system } -result {invalid encoding file "splat"} # OpenEncodingFile is fully tested by the rest of the tests in this file. test encoding-12.1 {LoadTableEncoding: normal encoding} { set x [encoding convertto iso8859-3 \u120] append x [encoding convertto iso8859-3 \ud5] append x [encoding convertfrom iso8859-3 \xd5] |
︙ | ︙ | |||
296 297 298 299 300 301 302 | test encoding-14.1 {BinaryProc} { encoding convertto identity \x12\x34\x56\xff\x69 } "\x12\x34\x56\xc3\xbf\x69" test encoding-15.1 {UtfToUtfProc} { encoding convertto utf-8 \xa3 } "\xc2\xa3" | < < | 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 | test encoding-14.1 {BinaryProc} { encoding convertto identity \x12\x34\x56\xff\x69 } "\x12\x34\x56\xc3\xbf\x69" test encoding-15.1 {UtfToUtfProc} { encoding convertto utf-8 \xa3 } "\xc2\xa3" test encoding-15.2 {UtfToUtfProc null character output} { set x \u0000 set y [encoding convertto utf-8 \u0000] set y [encoding convertfrom identity $y] binary scan $y H* z list [string bytelength $x] [string bytelength $y] $z } {2 1 00} test encoding-15.3 {UtfToUtfProc null character input} { set x [encoding convertfrom identity \x00] set y [encoding convertfrom utf-8 $x] binary scan [encoding convertto identity $y] H* z list [string bytelength $x] [string bytelength $y] $z } {1 2 c080} |
︙ | ︙ | |||
384 385 386 387 388 389 390 | } [list [string length $iso2022uniData] $iso2022uniData] test encoding-23.3 {iso2022-jp escape encoding test} { # read $fis <size> reads size in chars, not raw bytes. set fid [open iso2022.txt r] fconfigure $fid -encoding iso2022-jp set data [read $fid 50] close $fid | | > > > > > > > > > > > | | < < < < < < < < < | > | < < | < | < < < | < | | | 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 | } [list [string length $iso2022uniData] $iso2022uniData] test encoding-23.3 {iso2022-jp escape encoding test} { # read $fis <size> reads size in chars, not raw bytes. set fid [open iso2022.txt r] fconfigure $fid -encoding iso2022-jp set data [read $fid 50] close $fid return $data } [string range $iso2022uniData 0 49] ; # 0 .. 49 inclusive == 50 cd [workingDirectory] # Code to make the next few tests more intelligible; the code being tested # should be in the body of the test! proc runInSubprocess {contents {filename iso2022.tcl}} { set theFile [makeFile $contents $filename] try { exec [interpreter] $theFile } finally { removeFile $theFile } } test encoding-24.1 {EscapeFreeProc on open channels} exec { runInSubprocess { set f [open [file join [file dirname [info script]] iso2022.txt]] fconfigure $f -encoding iso2022-jp gets $f } } {} test encoding-24.2 {EscapeFreeProc on open channels} exec { # Bug #524674 output viewable [runInSubprocess { encoding system cp1252; # Bug #2891556 crash revelator fconfigure stdout -encoding iso2022-jp puts ab\u4e4e\u68d9g testfinexit }] } "ab\x1b\$B8C\x1b\$(DD%\x1b(Bg (ab\\u001b\$B8C\\u001b\$(DD%\\u001b(Bg)" test encoding-24.3 {EscapeFreeProc on open channels} {stdio} { # Bug #219314 - if we don't free escape encodings correctly on channel # closure, we go boom set file [makeFile { encoding system iso2022-jp set a "\u4e4e\u4e5e\u4e5f"; # 3 Japanese Kanji letters puts $a } iso2022.tcl] set f [open "|[list [interpreter] $file]"] fconfigure $f -encoding iso2022-jp |
︙ | ︙ | |||
465 466 467 468 469 470 471 | {4F21 4F53} {50 21 73 7E} {7421 7426} } { if {[llength $range] == 2} { # for adhoc range. simple {first last}. inclusive. | < | | < < < | 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 | {4F21 4F53} {50 21 73 7E} {7421 7426} } { if {[llength $range] == 2} { # for adhoc range. simple {first last}. inclusive. scan $range %x%x first last for {set i $first} {$i <= $last} {incr i} { set code $i uplevel 1 $command } } elseif {[llength $range] == 4} { # for uniform range. scan $range %x%x%x%x h0 l0 hend lend for {set hi $h0} {$hi <= $hend} {incr hi} { for {set lo $l0} {$lo <= $lend} {incr lo} { set code [expr {$hi << 8 | ($lo & 0xff)}] uplevel 1 $command } } } else { |
︙ | ︙ | |||
520 521 522 523 524 525 526 | # For more readable (easy to analyze) output. set code [lindex $la 0] binary scan [lindex $la 1] H* expected binary scan [lindex $lb 1] H* got lappend diff [list $code $expected $got] } | | | > < | < | < | > > | < < < < < | | | | | | | > > > > > | 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 | # For more readable (easy to analyze) output. set code [lindex $la 0] binary scan [lindex $la 1] H* expected binary scan [lindex $lb 1] H* got lappend diff [list $code $expected $got] } return $diff } # Create char tables. cd [temporaryDirectory] foreach enc {cp932 euc-jp iso2022-jp} { set f [open $enc.chars w] fconfigure $f -encoding binary foreach-jisx0208 code { puts $f [format "%04X %s" $code [gen-jisx0208-$enc $code]] } close $f } # shiftjis == cp932 for jisx0208. file copy -force cp932.chars shiftjis.chars set NUM 0 foreach from {cp932 shiftjis euc-jp iso2022-jp} { foreach to {cp932 shiftjis euc-jp iso2022-jp} { test encoding-25.[incr NUM] "jisx0208 $from => $to" -setup { cd [temporaryDirectory] } -body { set f [open $from.chars] fconfigure $f -encoding $from set out [open $from.$to.tcltestout w] fconfigure $out -encoding $to puts -nonewline $out [read $f] close $out close $f # then compare $to.chars <=> $from.to.tcltestout as binary. set fa [open $to.chars rb] set fb [open $from.$to.tcltestout rb] channel-diff $fa $fb # Difference should be empty. } -cleanup { close $fa close $fb } -result {} } } test encoding-26.0 {Tcl_GetDefaultEncodingDir} -constraints { testgetdefenc } -setup { set origDir [testgetdefenc] testsetdefenc slappy } -body { testgetdefenc } -cleanup { testsetdefenc $origDir } -result slappy file delete {*}[glob -directory [temporaryDirectory] *.chars *.tcltestout] # ===> Cut here <=== # EscapeFreeProc, GetTableEncoding, unilen are fully tested by the rest of # this file. } runtests } # cleanup namespace delete ::tcl::test::encoding ::tcltest::cleanupTests return # Local Variables: # mode: tcl # End: |
Changes to tools/tcltk-man2html-utils.tcl.
︙ | ︙ | |||
621 622 623 624 625 626 627 | ## build a cross-reference link if appropriate ## proc cross-reference {ref} { global manual remap_link_target global ensemble_commands exclude_refs_map exclude_when_followed_by_map set manname $manual(name) set mantail $manual(tail) | | | 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 | ## build a cross-reference link if appropriate ## proc cross-reference {ref} { global manual remap_link_target global ensemble_commands exclude_refs_map exclude_when_followed_by_map set manname $manual(name) set mantail $manual(tail) if {[string match "Tcl_*" $ref] || [string match "Tk_*" $ref] || [string match "Ttk_*" $ref] || [string match "Itcl_*" $ref] || [string match "Tdbc_*" $ref]} { regexp {^\w+} $ref lref ## ## apply a link remapping if available ## if {[info exists remap_link_target($lref)]} { set lref $remap_link_target($lref) } |
︙ | ︙ | |||
701 702 703 704 705 706 707 | puts stderr "multiple cross reference to $ref in $manref from $manual(wing-file)/$mantail" return $ref } ## ## exceptions, sigh, to the rule ## if {[info exists exclude_when_followed_by_map($mantail)]} { | | | 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 | puts stderr "multiple cross reference to $ref in $manref from $manual(wing-file)/$mantail" return $ref } ## ## exceptions, sigh, to the rule ## if {[info exists exclude_when_followed_by_map($mantail)]} { upvar 1 text tail set following_word [lindex [regexp -inline {\S+} $tail] 0] foreach {this that} $exclude_when_followed_by_map($mantail) { # only a ref if $this is not followed by $that if {$lref eq $this && [string match $that* $following_word]} { return $ref } } |
︙ | ︙ | |||
754 755 756 757 758 759 760 | ## find where each item lives - EXPENSIVE - and accumulate a list ## unset -nocomplain offsets foreach {name pattern} { anchor {<A } end-anchor {</A>} quote {``} end-quote {''} bold {<B>} end-bold {</B>} | | | | > > | 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 | ## find where each item lives - EXPENSIVE - and accumulate a list ## unset -nocomplain offsets foreach {name pattern} { anchor {<A } end-anchor {</A>} quote {``} end-quote {''} bold {<B>} end-bold {</B>} c.tcl {Tcl_} c.tk {Tk_} c.ttk {Ttk_} c.tdbc {Tdbc_} c.itcl {Itcl_} Tcl1 {Tcl manual entry} Tcl2 {Tcl overview manual entry} url {http://} } { set o [string first $pattern $text] if {[set offset($name) $o] >= 0} { set invert($o) $name |
︙ | ︙ | |||
804 805 806 807 808 809 810 | switch -exact -- $invert([lindex $offsets 1]) { end-quote { append result [string range $text 0 [expr {$offset(quote)-1}]] set body [string range $text [expr {$offset(quote)+2}] \ [expr {$offset(end-quote)-1}]] set text [string range $text[set text ""] \ [expr {$offset(end-quote)+2}] end] | < | < | < < < < < < < < < < < < < | | < < < < < | < < < < < < | < < < | < < | < < | 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 | switch -exact -- $invert([lindex $offsets 1]) { end-quote { append result [string range $text 0 [expr {$offset(quote)-1}]] set body [string range $text [expr {$offset(quote)+2}] \ [expr {$offset(end-quote)-1}]] set text [string range $text[set text ""] \ [expr {$offset(end-quote)+2}] end] append result `` [cross-reference $body] '' continue } bold - anchor { append result [string range $text \ 0 [expr {$offset(end-quote)+1}]] set text [string range $text[set text ""] \ [expr {$offset(end-quote)+2}] end] continue } } return [reference-error "Uncaught quote case" $text] } bold { if {$offset(end-bold) < 0} { return [append result $text] } if {[string match "c.*" $invert([lindex $offsets 1])]} { set offsets [lreplace $offsets 1 1] } switch -exact -- $invert([lindex $offsets 1]) { url - end-bold { append result \ [string range $text 0 [expr {$offset(bold)-1}]] set body [string range $text [expr {$offset(bold)+3}] \ [expr {$offset(end-bold)-1}]] set text [string range $text[set text ""] \ [expr {$offset(end-bold)+4}] end] regsub {http://[\w/.]+} $body {<A HREF="&">&</A>} body append result <B> [cross-reference $body] </B> continue } anchor { append result \ [string range $text 0 [expr {$offset(end-bold)+3}]] set text [string range $text[set text ""] \ [expr {$offset(end-bold)+4}] end] continue } default { return [reference-error "Uncaught bold case" $text] } } } c.tk - c.ttk - c.tcl - c.tdbc - c.itcl { append result [string range $text 0 \ [expr {[lindex $offsets 0]-1}]] regexp -indices -start [lindex $offsets 0] {\w+} $text range set body [string range $text {*}$range] set text [string range $text[set text ""] \ [expr {[lindex $range 1]+1}] end] append result [cross-reference $body] continue } Tcl1 - Tcl2 { set off [lindex $offsets 0] append result [string range $text 0 [expr {$off-1}]] set text [string range $text[set text ""] [expr {$off+3}] end] append result [cross-reference Tcl] continue } url { set off [lindex $offsets 0] append result [string range $text 0 [expr {$off-1}]] regexp -indices -start $off {http://[\w/.]+} $text range set url [string range $text {*}$range] append result "<A HREF=\"$url\">" $url "</A>" set text [string range $text[set text ""] \ [expr {[lindex $range 1]+1}] end] continue } end-anchor - end-bold - end-quote { return [reference-error "Out of place $invert([lindex $offsets 0])" $text] } } } } ## ## process formatting directives |
︙ | ︙ |
Changes to tools/tcltk-man2html.tcl.
︙ | ︙ | |||
762 763 764 765 766 767 768 | global build_tcl tcltkdir tcldir if {$type ni {n 3}} { error "unknown type \"$type\": must be 3 or n" } if {!$build_tcl} return set result {} foreach {dir name} $args { | | | > > > > > > > > | 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 | global build_tcl tcltkdir tcldir if {$type ni {n 3}} { error "unknown type \"$type\": must be 3 or n" } if {!$build_tcl} return set result {} foreach {dir name} $args { set globpat $tcltkdir/$tcldir/pkgs/$dir*/doc/*.$type if {![llength [glob -nocomplain $globpat]]} { # Fallback for manpages generated using doctools set globpat $tcltkdir/$tcldir/pkgs/$dir*/doc/man/*.$type if {![llength [glob -nocomplain $globpat]]} { continue } } regexp "pkgs/$dir(.*)/doc$" [glob $tcltkdir/$tcldir/pkgs/$dir*/doc] \ -> version switch $type { n { set title "$name Package Commands" if {$version ne ""} { append title ", version $version" } set dir [string totitle $dir]Cmd set desc \ "The additional commands provided by the $name package." } 3 { set title "$name Package Library" if {$version ne ""} { append title ", version $version" } set dir [string totitle $dir]Lib set desc \ "The additional C functions provided by the $name package." } } lappend result [list $globpat $title $dir $desc] } |
︙ | ︙ | |||
800 801 802 803 804 805 806 | set excluded_pages {case menubar pack-old} set forced_index_pages {GetDash} set process_first_patterns {*/ttk_widget.n */options.n} set ensemble_commands { after array binary chan clock dde dict encoding file history info interp memory namespace package registry self string trace update zlib clipboard console font grab grid image option pack place selection tk | | | 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 | set excluded_pages {case menubar pack-old} set forced_index_pages {GetDash} set process_first_patterns {*/ttk_widget.n */options.n} set ensemble_commands { after array binary chan clock dde dict encoding file history info interp memory namespace package registry self string trace update zlib clipboard console font grab grid image option pack place selection tk tkwait ttk::style winfo wm itcl::delete itcl::find itcl::is } array set remap_link_target { stdin Tcl_GetStdChannel stdout Tcl_GetStdChannel stderr Tcl_GetStdChannel style ttk::style {style map} ttk::style |
︙ | ︙ | |||
830 831 832 833 834 835 836 837 838 839 840 841 842 843 | Tcl_ObjType Tcl_RegisterObjType Tcl_OpenFileChannelProc Tcl_FSOpenFileChannel errorinfo env errorcode env tcl_pkgpath env Tcl_Command Tcl_CreateObjCommand Tcl_CmdProc Tcl_CreateObjCommand Tcl_Channel Tcl_OpenFileChannel Tcl_WideInt Tcl_NewIntObj Tcl_ChannelType Tcl_CreateChannel Tcl_DString Tcl_DStringInit Tcl_Namespace Tcl_AppendExportList Tcl_Object Tcl_NewObjectInstance Tcl_Class Tcl_GetObjectAsClass | > > | 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 | Tcl_ObjType Tcl_RegisterObjType Tcl_OpenFileChannelProc Tcl_FSOpenFileChannel errorinfo env errorcode env tcl_pkgpath env Tcl_Command Tcl_CreateObjCommand Tcl_CmdProc Tcl_CreateObjCommand Tcl_CmdDeleteProc Tcl_CreateObjCommand Tcl_ObjCmdProc Tcl_CreateObjCommand Tcl_Channel Tcl_OpenFileChannel Tcl_WideInt Tcl_NewIntObj Tcl_ChannelType Tcl_CreateChannel Tcl_DString Tcl_DStringInit Tcl_Namespace Tcl_AppendExportList Tcl_Object Tcl_NewObjectInstance Tcl_Class Tcl_GetObjectAsClass |
︙ | ︙ | |||
939 940 941 942 943 944 945 | } if {$build_tk} { append tcltkdesc "Tk" append cmdesc "Tk" append appdir "$tkdir" } | | | | 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 | } if {$build_tk} { append tcltkdesc "Tk" append cmdesc "Tk" append appdir "$tkdir" } # Get the list of packages to try, and what their human-readable names # are. Note that the package directory list should be version-less. try { set packageDirNameMap {} if {$build_tcl} { set f [open $tcltkdir/$tcldir/pkgs/package.list.txt] try { foreach line [split [read $f] \n] { if {[string trim $line] eq ""} continue |
︙ | ︙ |
Changes to unix/configure.
︙ | ︙ | |||
11570 11571 11572 11573 11574 11575 11576 | else NEED_FAKE_RFC2553=1 fi if test "x$NEED_FAKE_RFC2553" = "x1"; then | > | | 11570 11571 11572 11573 11574 11575 11576 11577 11578 11579 11580 11581 11582 11583 11584 11585 | else NEED_FAKE_RFC2553=1 fi if test "x$NEED_FAKE_RFC2553" = "x1"; then cat >>confdefs.h <<\_ACEOF #define NEED_FAKE_RFC2553 1 _ACEOF case " $LIBOBJS " in *" fake-rfc2553.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS fake-rfc2553.$ac_objext" ;; |
︙ | ︙ |
Changes to unix/tcl.m4.
︙ | ︙ | |||
3257 3258 3259 3260 3261 3262 3263 | struct sockaddr_storage],,[NEED_FAKE_RFC2553=1],[[ #include <sys/types.h> #include <sys/socket.h> #include <netinet/in.h> #include <netdb.h> ]]) if test "x$NEED_FAKE_RFC2553" = "x1"; then | | > | 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 | struct sockaddr_storage],,[NEED_FAKE_RFC2553=1],[[ #include <sys/types.h> #include <sys/socket.h> #include <netinet/in.h> #include <netdb.h> ]]) if test "x$NEED_FAKE_RFC2553" = "x1"; then AC_DEFINE([NEED_FAKE_RFC2553], 1, [Use compat implementation of getaddrinfo() and friends]) AC_LIBOBJ([fake-rfc2553]) AC_CHECK_FUNC(strlcpy) fi ]) # Local Variables: # mode: autoconf # End: |