Compare commits

..
Author SHA1 Message Date
dkf 4907489189 merge core-8-branch 2021-04-17 12:43:15 +00:00
dkf 2a03516c32 Cleaning up bytecode issuing. 2021-04-17 12:42:42 +00:00
jan.nijtmans 8f67ae04ad Merge 8.6 2021-04-16 13:16:25 +00:00
jan.nijtmans baa813085d Document Tcl_GetMemoryInfo() and Tcl_MainEx()/Tcl_MainExW(). Backported from [063d44b0beea237e] (Thanks, Harald!) 2021-04-16 13:14:55 +00:00
jan.nijtmans e06feb86b1 Document Tcl_GetMemoryInfo(). Backported from [063d44b0beea237e] (Thanks, Harald!) 2021-04-16 12:58:47 +00:00
jan.nijtmans 3ec8472d74 Revert [e59df7e9a3]: after a better look, the original code respected the expectation better and doesn't force appendObjPtr to Unicode, so it was actually better 2021-04-15 12:43:36 +00:00
jan.nijtmans 8a0a2779c2 Merge 8.6 2021-04-15 09:09:19 +00:00
jan.nijtmans 1c6fae0193 Fix [85d1fa7d07]: Duplicate file extension check in [file executable] on Windows 2021-04-15 09:08:23 +00:00
jan.nijtmans 871fc208e1 Fix [85d1fa7d07]: Duplicate file extension check in [file executable] on Windows. It looks like checking for "ps1" is a mistake. 2021-04-15 09:06:13 +00:00
jan.nijtmans 374f5c6e1a Restore expectation of callers to Tcl_AppendObjToObj that the appendObj never shimmers 2021-04-15 06:37:56 +00:00
dgp fc702f65d2 merge 8.6 2021-04-14 19:19:44 +00:00
jan.nijtmans 60169c7187 Restore expectation for Tcl_AppendObjToObj() 2021-04-14 19:15:52 +00:00
dgp 9cb33ddcc5 merge 8.5; adapt fix for 8.6 2021-04-14 18:58:54 +00:00
dgp c942ef369b [26649439c7] EIAS bug in [concat] 2021-04-14 18:39:12 +00:00
dgp bf055cc0d8 Bug fix 2021-04-14 18:37:35 +00:00
dgp 32a76688f6 Test demonstrating bug [26649439c7]. 2021-04-14 18:23:07 +00:00
jan.nijtmans ccfe3f47fd Complete fix for [7f1162a867]. Re-enable compilation of "string cat" (TclCompileStringCatCmd), since it now works again. 2021-04-14 08:14:23 +00:00
pooryorick c993263332 Remove unnecessary reference counting. 2021-04-13 22:44:04 +00:00
dkf f37db46ffe More hacking on zipfs, now detecting another malformation case and fixing an error message.
Also has (ifdef'd out) API for reading ZIP file comments.
2021-04-13 15:57:40 +00:00
jan.nijtmans 28ddee7d18 Merge-mark 8.6. Missing/superflouous testConstraint 2021-04-13 13:48:53 +00:00
jan.nijtmans 0b6db319f0 Update to latest "rules.vc" 2021-04-13 13:44:33 +00:00
jan.nijtmans 845442b102 Merge 8.7 2021-04-13 11:51:58 +00:00
jan.nijtmans c89d776dce Fix testcase utf-1.18 2021-04-13 11:51:16 +00:00
jan.nijtmans 09b6123a09 Merge 8.6. More missing ::tcltest::loadTestedCommands 2021-04-13 10:16:31 +00:00
jan.nijtmans 06464aa3be Missing ::tcltest::loadTestedCommands 2021-04-13 10:01:37 +00:00
jan.nijtmans f23820c00b Missing ::tcltest::loadTestedCommands 2021-04-13 09:13:58 +00:00
jan.nijtmans 87508b74e0 missing constraint 2021-04-13 08:20:54 +00:00
jan.nijtmans 16ddac314c eol-spacing 2021-04-13 08:15:50 +00:00
jan.nijtmans 9f61e10cf9 Unbreak build 2021-04-13 08:05:45 +00:00
dkf 204c8e3e79 merge core-8-branch 2021-04-12 19:14:48 +00:00
dkf a396843006 Zero out memory allocated on stack 2021-04-12 19:12:29 +00:00
dkf eb6cd90a57 More bits and pieces 2021-04-12 19:10:27 +00:00
jan.nijtmans c614920819 Fix [f566e1c817]: macOS: -DTCL_NO_DEPRECATED 2021-04-12 15:33:08 +00:00
jan.nijtmans 051a1473cb Merge-mark 2021-04-12 10:06:11 +00:00
jan.nijtmans 571eeda5cf Merge 8.5 2021-04-12 10:05:31 +00:00
jan.nijtmans cf9fc355f8 Backport utf testcase tweaks from 8.7. No change for ucs-2 2021-04-12 10:04:46 +00:00
jan.nijtmans 7deb6f2082 Fix [7f1162a867]. Don't compile "string cat" any more, since there still is a bug in it, demonstrated by utf-1.18 testcase 2021-04-12 09:26:27 +00:00
jan.nijtmans b1e4f0fa23 Merge 8.7 2021-04-09 15:35:17 +00:00
jan.nijtmans c318d73bd3 Document that Tcl 8.7 no longer uses a (modified) CESU-8 as internal format, but a (modified) WTF-8. 2021-04-09 15:32:25 +00:00
jan.nijtmans 459073607d Fix TclStringCat() functions. This makes allmost all testcases pass, one left to go: utf-1.18 2021-04-09 13:01:19 +00:00
jan.nijtmans 0d7132ebb2 Rename macro to ISCONTINUATION() 2021-04-09 10:57:36 +00:00
jan.nijtmans 2e06c053b4 new macro ISCONTBYTEORLOWERSURROGATE() 2021-04-09 09:14:10 +00:00
jan.nijtmans 4f93205802 Fix append-3.4, append-3.7 and utf-1.18 testcases 2021-04-09 07:33:40 +00:00
jan.nijtmans 023286a7fd Merge 8.7 2021-04-09 06:37:14 +00:00
jan.nijtmans 7bb103b64e More test-cases, involving \xC0 \x80 2021-04-09 06:36:45 +00:00
jan.nijtmans 3ed1f7b055 Remove TclpCreateFileHandler/TclpDeleteFileHandler on windows. The linker should complain when even trying to create something calling those functions. 2021-04-08 12:29:49 +00:00
jan.nijtmans 67e4ed2290 TIP #598: export TclWinConvertError 2021-04-08 12:22:16 +00:00
jan.nijtmans e287e35105 Fix compiler warning when using select notifier 2021-04-08 11:36:19 +00:00
jan.nijtmans 0b8bd54063 Merge 8.6 2021-04-08 08:47:18 +00:00
jan.nijtmans a463bf5525 Backport dde 1.4.4 from Tcl 8.7. Doesn't conflict with installed Tcl 9.0 version of dde any more.
(don't bother doing this for the "registry" extension, because the Tcl 8.7+ version installs in a different directory)
2021-04-08 08:45:12 +00:00
jan.nijtmans 6c72d33ef1 Make "registry" and "dde" dll's for 8.x and 9.0 installable in the same directory. See TIP #595 2021-04-08 07:56:45 +00:00
dkf 03aff519f2 Use a lot more enums and inline funcs instead of macros; behaviour is more predictable. 2021-04-07 16:47:33 +00:00
jan.nijtmans ee577ebd90 There is no "eq" command any more 2021-04-07 12:38:56 +00:00
jan.nijtmans 2b508d7964 Merge fork 2021-04-07 12:30:56 +00:00
jan.nijtmans 0dcddf9cf0 More test-cases showing the bug 2021-04-07 12:30:33 +00:00
jan.nijtmans 79fd04384a A few more Package -> Library renamings (testcases only) 2021-04-07 11:50:03 +00:00
jan.nijtmans 6792b8a53c A few missing renamings 2021-04-07 10:44:29 +00:00
jan.nijtmans 06813163a8 TIP #595 (for Tcl 8.7) part 1: just rename Tcl_StaticPackage to Tcl_StaticLibrary, Tcl_PackageInitProc to Tcl_LibraryInitProc and Tcl_PackageUnloadProc to Tcl_LibraryUnloadProc. Adapt documentation, mentioning that the old names are now deprecated. 2021-04-07 09:55:24 +00:00
jan.nijtmans a1ab68d1ea Revert previous commit, and add comments why it's wrong. 2021-04-07 09:01:55 +00:00
pooryorick 83025a44e0 Replace simple refCount decrement with the proper decrementing function. 2021-04-05 21:07:00 +00:00
jan.nijtmans 85d1500c50 tclZipfs.c:1857:33: warning: request for implicit conversion from ‘void *’ to ‘char *’ not permitted in C++ [-Wc++-compat] 2021-04-05 17:58:13 +00:00
jan.nijtmans 15b5f31caf Rename exported symbol "Tcl_StaticPackage" to "Tcl_StaticLibrary". Still undocumented, to be formalized by TIP #595. Tcl_StaticPackage() still works the same 2021-04-04 16:56:26 +00:00
jan.nijtmans 226bb13f4e Fix [https://github.com/tcltk/tcl/runs/2263266926|failing test-cases] with --enable-symbols=mem build by reverting the series of commits that caused the memory-leak 2021-04-04 14:31:43 +00:00
pooryorick 7f4cc308f3 Update code comments. 2021-04-03 17:58:03 +00:00
pooryorick 42c960506d Changes to code comments. 2021-04-03 13:20:14 +00:00
pooryorick 970479b4ee When a namesapce is deleted delete all namespaces under it before making any
modifictions to it.
2021-04-03 12:48:54 +00:00
pooryorick 55f8e3ac01 Remove suspected inadvertent copypasta from test. 2021-04-03 12:36:10 +00:00
pooryorick c494f8045e Use TclCleanupCommandMacro instead of just decrementing the reference count. 2021-04-03 12:33:58 +00:00
pooryorick 756e0c234a OO cleanup fix that passes test 11.7. 2021-04-03 12:33:00 +00:00
pooryorick 1c4c352fe9 New test for OO cleanup: routine for object gets deleted before namespace deletion
is complete.
2021-04-03 12:17:40 +00:00
dkf 743881d3ce Clean up the notifier code to not spread the hooks quite so widely 2021-04-03 11:09:47 +00:00
dkf 3628bed3ba Don't do double definition; code was moved to tclInt.h previously. 2021-04-02 18:41:36 +00:00
jan.nijtmans d1bd0f28ef Merge 8.6 2021-04-01 10:19:56 +00:00
jan.nijtmans e5991250e0 Follow-up to [15c7b4f93e]: "Implement TCL_ENCODING_STOPONERROR flag for UtfToUtf encoder/decoder". Only do this check when pureNullMode == 0, otherwise we violate EIAS. 2021-04-01 09:47:33 +00:00
dkf 55bb44b8be Forgot a place to #ifndef out 2021-04-01 08:18:38 +00:00
dkf 5ca6887e66 Don't define Tcl_CreateFileHandler or Tcl_DeleteFileHandler on Windows. 2021-03-31 10:45:40 +00:00
dkf 4c25696376 merge core-8-branch 2021-03-31 10:38:25 +00:00
jan.nijtmans 9406745440 Add 3 undocumented #defines. To be formalized by TIP #595 (currently being voted on) 2021-03-31 10:09:32 +00:00
jan.nijtmans 9b5af56932 RFE 4b4830eb54: reflected channel truncate method 2021-03-30 16:30:31 +00:00
dkf 107f7173d2 Improve documentation for exec and open, especially in relation to binary pipelines 2021-03-30 10:17:09 +00:00
dkf 73953be8b1 Improve documentation for exec and open, especially in relation to binary pipelines 2021-03-30 10:14:20 +00:00
dkf 63f4be3aa2 Improve documentation for exec and open, especially in relation to binary pipelines 2021-03-30 09:03:19 +00:00
dkf 2dab8fa488 Refactoring, ahoy 2021-03-30 08:22:26 +00:00
jan.nijtmans 1f1f43fcd2 Thanks to TIP #587, convert many escapes in the testcases into the actual (UTF-8) character. 2021-03-30 07:11:18 +00:00
jan.nijtmans c8617b374b merge-mark 2021-03-30 06:12:18 +00:00
jan.nijtmans 9eb5b14a3c remove useless save/restore 2021-03-30 06:10:23 +00:00
jan.nijtmans 79b9ab1039 Change TCL_ENCODING_EXTERNAL flag into TCL_ENCODING_MODIFIED, but with opposite meaning. Simplify code. 2021-03-28 20:09:51 +00:00
jan.nijtmans 6c6a470c2b Rename MODULESCOPE TclGetLoadedPackagesEx() to TclGetLoadedLibraries() 2021-03-22 17:07:01 +00:00
jan.nijtmans 3b6d7d6119 merge-mark 2021-03-22 10:08:10 +00:00
jan.nijtmans 0f632bd1c5 Merge 8.5 2021-03-22 10:06:36 +00:00
jan.nijtmans d63f456a83 Fix incorrect comment: underscore ('_') is allowed in a packageName 2021-03-22 10:04:12 +00:00
jan.nijtmans 9e6945739a Rename internal variables, making it more clear that tclLoad.c is not part of Tcl's "package" mechanism. 2021-03-22 10:00:06 +00:00
dkf c49b98fa6b Start of doing a clean up of the notifier code.
This originated as trying to stop macOS builds from doing silly warnings during
a static build, but I noticed that there were common patterns that belong in
generic code instead of being repeated in each of the platform-specific pieces.
2021-03-21 13:07:15 +00:00
jan.nijtmans 8a9eba41a2 merge-mark 2021-03-21 09:30:06 +00:00
jan.nijtmans dd9f3c1246 Implement TCL_ENCODING_STOPONERROR flag for UtfToUtf encoder/decoder. Backported from 8.7 2021-03-21 09:27:07 +00:00
jan.nijtmans 4e90ccc6db Fix [0221b993a1]: Tcl command [update idletasks] doesn't skip main loop in Tcl_DoOneEvent 2021-03-19 14:55:25 +00:00
jan.nijtmans d5479489aa Fully implement TCL_ENCODING_STOPONERROR flag for Utf2Utf encoder/decoder. 2021-03-19 12:58:41 +00:00
jan.nijtmans c39345b47a Merge 8.6 2021-03-19 10:49:13 +00:00
jan.nijtmans fff5060d94 Change Tcl_StaticPackage's "pkgName" argument to "prefix" and improve documentation, describing better what this argument does. 2021-03-19 09:20:26 +00:00
dkf f2cb38dda9 Handle the encoding of filenames in ZIPs correctly. (This is awful. The awful isn't Tcl's fault. Terrible spec...) 2021-03-18 21:35:09 +00:00
dkf e6d6e2962d Delete some useless code. Was only place where we fed an uncontrolled value to %f, and it was actually a conversion we didn't need to do at all. 2021-03-18 21:17:46 +00:00
jan.nijtmans 80af639d39 Merge 8.6 2021-03-18 14:49:01 +00:00
jan.nijtmans 8390478dbf Fix [8663689908]. Final documentation fix, implementation was already fixed earlier. 2021-03-18 14:46:57 +00:00
jan.nijtmans 2b7eb65f53 Suggested fix for [0221b993a1]: Tcl command [update idletasks] doesn't skip main loop in Tcl_DoOneEvent 2021-03-18 13:20:47 +00:00
jan.nijtmans 260c7e595a Merge 8.6 2021-03-18 12:07:38 +00:00
jan.nijtmans a3ae9d7e57 Fix [2860859e84]: Misleading description in README file 2021-03-18 12:05:56 +00:00
jan.nijtmans 8df980fc3e Merge 8.6 2021-03-18 09:51:49 +00:00
jan.nijtmans 3aa4b20ea8 Remove incorrect/useless comment 2021-03-18 09:36:27 +00:00
jan.nijtmans 6da553ec22 Proposed implementation of RFE [4b4830eb54] 2021-03-18 09:26:03 +00:00
jan.nijtmans c84e03a7a8 More simplification of UtfToUtfProc(). Get rid of wrapper functions UtfIntToUtfExtProc/UtfExtToUtfIntProc. This can be handled by additional flags. 2021-03-18 09:12:18 +00:00
jan.nijtmans 4b3814f752 Simplify UtfToUtfProc() and UtfToUtf16Proc(): Using TclUtfToUCS4() internally means that we don't have to keep track of internal state any more (Tcl_EncodingState)
Also, add (HMODULE) cast (back) in tclZipfs.c
2021-03-17 15:01:54 +00:00
jan.nijtmans 15849c859a Fix MSVC build 2021-03-17 08:50:28 +00:00
dkf 90040e0573 More cleaning up of zipfs
Don't put straight binary data in a Tcl string, and other better API uses.
2021-03-16 20:45:39 +00:00
jan.nijtmans 0013597b33 Fix gcc warnings 2021-03-16 09:16:39 +00:00
jan.nijtmans c54d29df06 Tweak usage of TCL_NO_DEPRECATED 2021-03-15 13:17:54 +00:00
jan.nijtmans 6e657cfb83 Implement TIP #575: Switchable Tcl_UtfCharComplete()/Tcl_UtfNext()/Tcl_UtfPrev() 2021-03-15 11:52:09 +00:00
dkf 57bf9fe12f More refactoring to reduce the choked-up complexity of tclZipfs.c 2021-03-15 09:52:02 +00:00
dkf 1f2858fefd Flipped a test 2021-03-14 20:53:39 +00:00
jan.nijtmans 2d6586915f merge-mark 2021-03-14 18:28:47 +00:00
jan.nijtmans a132514652 Merge 8.5 2021-03-14 16:13:44 +00:00
jan.nijtmans b0e0d4b618 Document that Tcl_UtfCharComplete() can (now) be used to protect Tcl_UtfNext() calls against overflow, if the string being handled is not NULL-terminated. 2021-03-14 16:12:25 +00:00
dkf 58fb98d8a9 More on making tclZipfs.c comprehensible. Refactoring to the rescue! 2021-03-14 15:26:44 +00:00
jan.nijtmans be3426d527 merge-mark 2021-03-11 12:20:11 +00:00
jan.nijtmans 2ea2ef0609 Backport Tcl_UtfCharComplete() functionality from 8.6 for TCL_UTF_MAX>3. This makes Tcl_UtfCharComplete() usable to protect Tcl_UtfNext() calls for overflow. No change for TCL_UTF_MAX=3 (default build) 2021-03-11 12:19:14 +00:00
jan.nijtmans d0443e229f Merge 8.6 2021-03-10 16:16:08 +00:00
jan.nijtmans f223db50fd Repair Tcl_UniCharNcasecmp() in the same way as Tcl_UniCharNcmp() for fix [4c591fa487]. Also put back minor optimization for big-endian machines removed in the previous commit 2021-03-10 16:12:01 +00:00
jan.nijtmans 07c6dc0d49 Merge 8.6 2021-03-10 15:47:34 +00:00
jan.nijtmans 0834bb4547 Fix [4c591fa487]: [string compare] EIAS violation 2021-03-10 15:39:15 +00:00
jan.nijtmans 50b24193de Compatibility tweak wrt 8.6 2021-03-09 15:38:06 +00:00
jan.nijtmans a2b56f4c74 TclWinConvertError -> Tcl_WinConvertError 2021-03-09 15:28:40 +00:00
jan.nijtmans 0255b9c343 Merge 8.7 2021-03-09 15:13:08 +00:00
jan.nijtmans 764ef9b409 Merge 8.6 2021-03-09 09:19:25 +00:00
jan.nijtmans 8aca3246ab Fix [8419c55e2c]: Tclsh read loop does not handle EINTR 2021-03-09 09:14:04 +00:00
jan.nijtmans c197ddb3b2 Merge 8.6. Remove end-of-line spacing 2021-03-09 08:37:47 +00:00
jan.nijtmans 3b584dd13f Remove end-of-line spacing 2021-03-09 08:36:11 +00:00
dkf 25bbbbf3ee Fix SEGV in zipfs mounting, and try to make that code more comprehensible 2021-03-08 16:53:51 +00:00
dkf b9bc37e2b8 Added some tests for [zipfs lmkimg] 2021-03-07 18:42:27 +00:00
dkf a1d8e47ea7 Document that [zipfs mkimg] strips an existing ZIP. We ought to merge instead, but we don't yet. 2021-03-06 16:28:43 +00:00
jan.nijtmans dd7f073e8b Merge 8.6 2021-03-04 16:10:29 +00:00
jan.nijtmans a085ffdd43 In man2html, use consistant color-names (6-char, uppercase), encoding (utf-8) and translation (lf) independant from platform 2021-03-04 15:53:15 +00:00
jan.nijtmans 063e006111 Merge 8.6 2021-03-04 10:36:23 +00:00
jan.nijtmans 19bfe564de Merge 8.5. Add unused stub table entries 2021-03-04 10:22:40 +00:00
jan.nijtmans 3f89004e37 Add some more unused entries to the stub table, keeping up with the table size increase of higher Tcl versions 2021-03-04 09:53:10 +00:00
jan.nijtmans bebf0454f6 cleanup genStubs.tcl, e.g. "==" -> "eq" and "!=" -> "ne". No change in output 2021-03-04 09:42:47 +00:00
jan.nijtmans 4355668c80 Merge 8.6. Basically re-number testcases so they align with the 8.6 test-cases 2021-03-03 15:06:08 +00:00
jan.nijtmans 5a2a021cd4 Merge 8.5. Just split some testcases 2021-03-03 14:44:03 +00:00
jan.nijtmans 6433d6a30b Backport improvements in UTF-8 handling for Tcl_UtfPrev/Tcl_UtfNext from 8.7 (through 8.6). No change for TCL_UTF_MAX=3. Adapt test-cases accordingly 2021-03-03 14:31:37 +00:00
jan.nijtmans ae9d23eae8 Merge 8.6 2021-03-02 10:59:25 +00:00
jan.nijtmans 773a30a541 Using 0xFC00 is more readable here than ~0x3FF. It's sufficient becauwe ch1 and ch2 are only 16-bit. Backported from 8.7 2021-03-02 10:53:30 +00:00
jan.nijtmans 895a4597bc Merge 8.6 2021-03-02 10:38:36 +00:00
jan.nijtmans b697c844ad Backport some UTF-8-related changed from 8.7 to 8.6, only for TCL_UTF_MAX > 3. No change for TCL_UTF_MAX=3.
Also adapt test-cases accordingly, and add comments why the changes were done.
2021-03-02 10:10:54 +00:00
oehhar 7c54d7ca1d Ticket [87082587c4]: typo in msgcat man page 2021-02-27 11:21:34 +00:00
oehhar 1ac55b7d3f Ticket [87082587c4]: typo in msgcat man page 2021-02-27 11:19:28 +00:00
jan.nijtmans 6293939296 Further internal variable upgrade from long -> size_t 2021-02-26 14:52:14 +00:00
jan.nijtmans a97e3eef6d Increase some (internal) variables from int/long to long/size_t. On the way to allow bigger blocks in the threaded allocator 2021-02-26 13:18:50 +00:00
jan.nijtmans d134d35fef Fix "make checkstubs": A few more MODULE_SCOPE libtommath functions 2021-02-24 11:56:53 +00:00
jan.nijtmans e5153a8d0c Fix typo, eliminate type-cast 2021-02-24 08:58:15 +00:00
jan.nijtmans 5c8ce61f79 Merge 8.6. Fix Cygwin compile 2021-02-23 13:30:01 +00:00
jan.nijtmans 4723df2a35 Merge 8.5 2021-02-23 13:03:28 +00:00
jan.nijtmans c0f6db4b81 Revise buffer-sizes used in GetModuleFileNameW() calls. Available buffer-size reported to GetModuleFileNameW() was not always accurate 2021-02-23 12:34:58 +00:00
jan.nijtmans 06ea55d820 Simplify implementation on Cygwin: No need to use CFG_RUNTIME_BINDIR any more 2021-02-23 10:08:46 +00:00
jan.nijtmans eb9f949b2c Merge 8.6 2021-02-23 07:39:34 +00:00
jan.nijtmans 8242d1a544 Use _wgetenv() in stead of getenv() on Windows: The wide environment is not always well-synchonized with the locale environment. Problem detected on the sebres-8-6-clock-speedup-cr2, but this branch only exposed the bug, it did not cause it. 2021-02-23 07:23:29 +00:00
jan.nijtmans e3afa12420 Merge 8.6 2021-02-19 07:20:52 +00:00
jan.nijtmans 7bfe776283 Fix [7c64aa5e1a]: Another uninitialized-variable bug in BRE-mode parsing. Thanks to Tom Lane for the bug-report and the fix 2021-02-19 07:20:06 +00:00
jan.nijtmans bdd6e3f4df Fix [7c64aa5e1a]: Another uninitialized-variable bug in BRE-mode parsing. Thanks to Tom Lane for the bug-report and the fix. 2021-02-19 07:18:13 +00:00
jan.nijtmans 185b0d1493 Merge 8.7 2021-02-18 12:35:44 +00:00
jan.nijtmans 345894cae9 Protect "interp limit" command better for allowed range in -millis and -seconds values 2021-02-18 12:01:44 +00:00
jan.nijtmans f4032799de Merge 8.6 2021-02-18 08:46:21 +00:00
jan.nijtmans 957890bf54 Two new testcases for abs() 2021-02-18 08:32:28 +00:00
jan.nijtmans f2c4a32d7f Performance optimization in TzsetIfNecessary() function. Cherry-picked from sebres-8-6-clock-speedup-cr2 branch 2021-02-18 07:55:08 +00:00
jan.nijtmans cf0af45b5a merge-mark 2021-02-17 18:51:12 +00:00
jan.nijtmans 042e9a4f8a Backport 3 additional test-cases from 8.6 for TCL_UTF_MAX>3 2021-02-17 18:48:47 +00:00
jan.nijtmans 28d58d74b0 Fix abs(-9223372036854775808) special-case on platforms where sizeof(Tcl_WideInt) > sizeof(int64_t). Theoretical, yes, but at least add a testcase for this (expr-38.14) 2021-02-17 16:16:19 +00:00
jan.nijtmans 6067ce5573 Fix compiler warning on non-intel CPU's 2021-02-17 15:44:24 +00:00
jan.nijtmans 39a8b9813a Multi-arch only works on MacOS-11 2021-02-17 13:07:18 +00:00
jan.nijtmans 467337387f Don't pack tcl_library/registry/pkgIndex in zip-file on UNIX 2021-02-17 09:41:46 +00:00
jan.nijtmans 6ee6cd1ae4 Fix "make dist" on UNIX, broken due to TIP #590 2021-02-17 08:50:17 +00:00
jan.nijtmans b3d34ad317 Another TIP #430 fix for cygwin: libtcl8.7.dll is installed in /usr/bin, not in /usr/lib as on other platforms 2021-02-17 08:35:44 +00:00
jan.nijtmans 499e962572 Don't try to use ln when creating libtcl.vfs on windows: It doesn't work for encodings or msg-files (anything on a deeper level) when zipping (at least not on cygwin) 2021-02-17 08:32:53 +00:00
jan.nijtmans 0b9b440ce0 Attempt to produce double-arch (x86_64 and arm) binary for MacOS 2021-02-16 13:59:08 +00:00
jan.nijtmans 8844e2789a Merge 8.7 2021-02-16 12:17:49 +00:00
jan.nijtmans 532506ea20 merge-mark 2021-02-16 12:10:00 +00:00
jan.nijtmans 5fd34b8806 Fix bug in previous commit: Don't update stringPtr->numChars when doing a "string reverse", because TclUtfToUCS4() doesn't count surrogate pairs as 2 2021-02-16 12:07:42 +00:00
jan.nijtmans bb836a3071 Merge 8.6 2021-02-16 12:00:21 +00:00
jan.nijtmans 999decddb3 Fix [22324bcbd]: string reverse is broken for Emoji. Thanks to Chrisian Werner for bug report and POC patch. 2021-02-16 11:11:23 +00:00
jan.nijtmans 3001f87063 Remove unnecessary end-of-line spacing in test-cases 2021-02-16 11:05:18 +00:00
jan.nijtmans 94c40f8b71 Merge 8.7 2021-02-16 09:11:54 +00:00
jan.nijtmans 635b0327a6 merge-mark 2021-02-16 09:03:59 +00:00
jan.nijtmans 4b639c1ec5 Fix Tcl_UtfPrev expected testcases for TCL_UTF_MAX>3 2021-02-16 09:00:14 +00:00
jan.nijtmans 5dc64243f3 Merge 8.6 2021-02-16 08:30:17 +00:00
jan.nijtmans d97e25b2ad Fix Tcl_UtfPrev for TCL_UTF_MAX>3, so it can jump back over Emoji. Backported from 8.7, no change for TCL_UTF_MAX=3.
This way, the previous fix can be slightly more simplified, and working for TCL_UTF_MAX>3 too.
2021-02-16 08:10:34 +00:00
culler 3eb07e538c Switch to version 1.3 of macher for the onefiledist 2021-02-15 17:06:47 +00:00
jan.nijtmans cb794e731c Merge 8.6 2021-02-15 16:20:40 +00:00
jan.nijtmans c6e348a28b Fix [d43f96c1a8]: string trimright is broken for Emoji 2021-02-15 16:13:15 +00:00
jan.nijtmans b4660a7ff9 Remove unused variable in win32 static build 2021-02-15 15:41:55 +00:00
jan.nijtmans 3bbf07a495 Merge 8.6 2021-02-15 12:42:09 +00:00
jan.nijtmans 13b1a0635f More testcases from Christian Werner, regarding "string reverse" with Emoji. Those testcases fail in all Tcl 8.6.x releases. 2021-02-15 12:35:33 +00:00
jan.nijtmans 90565904aa Merge 8.7 2021-02-15 12:08:17 +00:00
jan.nijtmans 73745cbfbf Enhance new testscases for compiled/interpreted mode 2021-02-15 08:18:22 +00:00
jan.nijtmans ab91723185 Add testcases from Christian Werner, regarding "string trim" with Emoji 2021-02-15 08:07:42 +00:00
jan.nijtmans 5eba4fa4d7 Add testcases, contributed by Christian Werner. Two of them fail, so still some work to do. [d43f96c1a8] 2021-02-15 07:48:54 +00:00
jan.nijtmans 0d7614dd81 Missing semicolon in UNIX Makefile 2021-02-15 07:47:33 +00:00
jan.nijtmans 6fcd32ac08 "macher" output should be executable 2021-02-15 07:31:08 +00:00
jan.nijtmans 73277b178e Use Marc Culler's "macher" utility for the onefiledist MacOSX builds. Only for non-framework builds. 2021-02-12 17:27:11 +00:00
culler 21d34a1956 The syntax error was caused by Aquamacs inserting tabs into the YAML file. 2021-02-12 14:57:10 +00:00
jan.nijtmans 7b662b613d Syntax error in yaml-file 2021-02-12 11:12:09 +00:00
jan.nijtmans 42e3415106 Fix warning about unused symbol on --disable-shared build 2021-02-12 08:21:46 +00:00
culler 840ba03059 macher 1.1 -> 1.2 (bug fixes) and account for new append syntax. 2021-02-12 01:46:21 +00:00
jan.nijtmans 89fa1f862f macher 1.0 -> 1.1 2021-02-11 17:19:38 +00:00
jan.nijtmans c1a56eb2d1 Experiment: Integrate culler's "macher" tool. Only for thin binaries 2021-02-11 16:30:11 +00:00
culler a4bf99fa2c Add CFLAGS to the github actions to build fat binaries on macOS. 2021-02-11 15:12:40 +00:00
jan.nijtmans dfd4a2e5c1 Missing #endif 2021-02-10 13:12:42 +00:00
jan.nijtmans c0cb466a86 Make TIP #430 work on cygwin. Simplify some makefiles 2021-02-10 12:56:47 +00:00
jan.nijtmans 24128f43df Backport win/rules.vc from 8.7 2021-02-10 10:44:52 +00:00
jan.nijtmans ea4e2c5432 Fix pkgconfig-1.1 testcase for static builds 2021-02-10 08:52:08 +00:00
jan.nijtmans d12eee4a39 Fix various aspects in TIP #430 implementation. Should now work for Tk too (together with some fixes in Tk). zip-file is no longer installed separately, but attached to either tclsh (in a static build) or libtcl8.7.so (in a shared build) 2021-02-10 08:25:56 +00:00
jan.nijtmans 2ba1ef3db1 In a static build, don't pack dde/registry in zip-file. In shared build, pack dde/registry dll's in zip-file. Rename zip-file 2021-02-10 08:11:29 +00:00
jan.nijtmans 6e603480b3 Only set dllfile,runtime key info when doing a shared build 2021-02-09 16:43:57 +00:00
jan.nijtmans aeeb808b30 ZIPFS_BUILD=1 only needs to be set once 2021-02-09 14:16:11 +00:00
jan.nijtmans 0043160893 Handle the situation that ::${basename}::pkgconfig does not have bindir/libdir,runtime keys: Either get those from Tcl, or from [info nameofexecutable] 2021-02-09 13:34:26 +00:00
jan.nijtmans af4a77f3e3 Change TCL_ZIP_FILE name, just using dots in stead of underscores 2021-02-09 12:07:09 +00:00
jan.nijtmans 5740a9e3d2 Add --disable-zipfs flag to GNUmakefile 2021-02-09 07:34:01 +00:00
jan.nijtmans ebf4c78ed8 Attempt to fix the last TIP #430 bits, needed to make it work for Tk (and other external packages) 2021-02-08 18:23:40 +00:00
jan.nijtmans 8395974e1b Merge-mark 2021-02-08 15:59:24 +00:00
jan.nijtmans 6f3b0bd108 Bugfix in TIP #430 implementation: tcl_findLibrary should use the same zip-file naming as the configure scripts do 2021-02-08 15:51:46 +00:00
jan.nijtmans b142586b21 Fix "auto.tcl" indenting 2021-02-08 15:25:55 +00:00
jan.nijtmans 32dc9b67a9 Merge 8.6 2021-02-08 10:46:58 +00:00
jan.nijtmans 6efc470726 Merge 8.5 2021-02-08 10:11:38 +00:00
jan.nijtmans fa2bb177eb Makefile cleanup: Remove *.zip and *.vfs files/directories as part of "make clean", which might be a leftover of a previous Tcl 8.7 build in this directory 2021-02-08 09:21:37 +00:00
jan.nijtmans 7104004d57 Merge 8.6 2021-02-05 13:45:51 +00:00
jan.nijtmans fed1ff66dc More implicit type-casts, for better compatibility with C++ 2021-02-05 13:42:40 +00:00
jan.nijtmans d9e28af5f3 Oops 2021-02-05 13:37:26 +00:00
jan.nijtmans 392c7ad8eb Merge 8.6 2021-02-05 11:36:49 +00:00
jan.nijtmans 3a18a03f3d Fix filename-11.45 testcase when there are multiple volumes: This testcase only works for the native file system, which is the lastt one. 2021-02-05 11:34:28 +00:00
jan.nijtmans c09ddd48e3 In a --disable-shared build, attach the zip-file to the executable, so "onfiledist.yml" doesn't need to do that any more 2021-02-04 13:11:37 +00:00
jan.nijtmans 0d69fc832e Fix [03b70c8918]: core-8-branch : trying to build on macOS10.9 linked against XQuartz 2021-02-04 11:11:34 +00:00
jan.nijtmans 6e97fd01b0 Merge 8.6 2021-02-02 08:50:55 +00:00
jan.nijtmans e2c482312c On Big Sur, distingish 11.0, 11.1 and 11.2. platform 1.0.16 -> 1.0.17 2021-02-02 08:46:12 +00:00
jan.nijtmans 00e0788723 On Big Sur, distingish 11.0, 11.1 and 11.2. platform 1.0.16 -> 1.0.17 2021-02-02 08:41:35 +00:00
jan.nijtmans 3aab127556 Undo previous change to unix/configure.ac: It doesn't work 2021-01-29 15:51:28 +00:00
jan.nijtmans 58625c6ba9 Undo previous change to unix/configure.in 2021-01-29 15:45:01 +00:00
jan.nijtmans 2cf339ce3b Merge 8.6 2021-01-29 14:02:43 +00:00
jan.nijtmans 57f9c7dae5 Fix 2 warnings when running "autoconf" (2.69 or 2.70) 2021-01-29 13:45:18 +00:00
jan.nijtmans f6c86d7972 re-generate unix/configure 2021-01-29 09:18:36 +00:00
jan.nijtmans 1fb596128b Fix [113be1991e]: zipfs on mac.
From now on, --enable-framework automatically means --disable-zipfs, since those 2 options can never work together.
2021-01-29 09:15:41 +00:00
jan.nijtmans 2cb77a221b Lowercase package names are recommended now 2021-01-28 15:54:53 +00:00
jan.nijtmans 33b2c94323 Merge 8.6 2021-01-28 11:08:46 +00:00
jan.nijtmans 8d49123e73 Use {} braces in more "expr" expressions. 2021-01-28 10:42:05 +00:00
jan.nijtmans 9c024d9d3b Use "in" operator in stead of "lsearch -exact" when possible 2021-01-28 10:38:44 +00:00
jan.nijtmans 82f2bed5fe Merge 8.6 2021-01-27 10:15:26 +00:00
jan.nijtmans 6b29884385 *.decls files are now in UTF-8. Use "in" operator in stead of "lsearch -exact". 2021-01-27 10:13:51 +00:00
jan.nijtmans 06f42e40b2 Merge 8.6 2021-01-27 09:35:07 +00:00
jan.nijtmans 2ff8145561 When generating stubs, always read *.decls and *Decls.h files in UTF-8. This corrects possible invalid UTF-8. 2021-01-27 09:32:44 +00:00
jan.nijtmans 581d7fccf5 Merge 8.6 2021-01-25 12:26:18 +00:00
jan.nijtmans 05b6284310 Update to tzdata 2021a 2021-01-25 12:25:20 +00:00
jan.nijtmans 2ee9e74ac6 Update to tzdata 2021a 2021-01-25 12:24:07 +00:00
jan.nijtmans ba3f00d403 Make Tcl_GetString() a macro calling Tcl_GetStringFromObj(). Just the same as Tcl_GetUnicode(). 2021-01-25 11:53:59 +00:00
jan.nijtmans f837b2ca92 Fix [f4b0cb2080] by only accepting new syntax when TCL_NO_DEPRECATED is defined 2021-01-25 10:26:22 +00:00
jan.nijtmans 6724e74377 Merge 8.6 2021-01-25 09:16:54 +00:00
jan.nijtmans 29c768d6c9 Merge 8.5 2021-01-25 09:05:45 +00:00
jan.nijtmans 458c3e9cc5 ERROR_ON_FAILURES=1, otherwise failing Linux tests don't result in a failing build 2021-01-25 08:42:27 +00:00
jan.nijtmans 31e49b4c7c Make sure MODULE_SCOPE is always defined correctly, for C++ compilers too 2021-01-25 08:27:22 +00:00
jan.nijtmans 298c9aa866 Fix [http://core.tcl.tk/tk/tktview?name=1712098|1712098]: Tk still needs Tcl source distro, by new export Tcl_MacOSXNotifierAddRunLoopMode() 2021-01-22 14:22:11 +00:00
jan.nijtmans 4612b57a1e Change exported symbol from TclMacOSXNotifierAddRunLoopMode -> Tcl_MacOSXNotifierAddRunLoopMode 2021-01-22 09:24:13 +00:00
jan.nijtmans b02ecd46ec Rebase to core-8-branch 2021-01-22 08:57:44 +00:00
jan.nijtmans f050bae793 Merge 8.6 2021-01-21 16:01:07 +00:00
jan.nijtmans b2cabbf79c Fix [8c025f8f0d]: Run-time error on tcl 8.6.11 32 bits (from cross-compile Centos6.9 64-bits) 2021-01-21 15:56:52 +00:00
jan.nijtmans 14ab9ebc55 Fix [8c025f8f0d]: Run-time error on tcl 8.6.11 32 bits (from cross-compile Centos6.9 64-bits) 2021-01-21 15:54:02 +00:00
jan.nijtmans 298a0ffc19 Merge 8.6 2021-01-21 15:46:16 +00:00
jan.nijtmans ea1fdc511d Fix [https://core.tcl-lang.org/thread/tktview?name=98ae20f0f5|98ae20f0f5]: Type mismatch in TclIntStubs 2021-01-21 15:42:11 +00:00
jan.nijtmans 207a4b3122 Fix [https://core.tcl-lang.org/thread/info/98ae20f0f5|98ae20f0f5] by no longer compile the stub library using LTO (even if CFLAGS enables LTO) 2021-01-21 15:31:28 +00:00
jan.nijtmans 2b394dc55d Close fork 2021-01-21 12:43:40 +00:00
jan.nijtmans ab2df51726 Close fork 2021-01-21 12:40:08 +00:00
msi e9dfa3ed3c Improve [file attributes] documentation 2021-01-20 22:35:57 +00:00
msi ca8cef9587 Improve [file attributes] documentation 2021-01-20 22:31:34 +00:00
msi 0befd21328 Improve [file attributes] documentation further 2021-01-20 22:28:30 +00:00
msi f0e85a15a0 Improve [file attributes] documentation 2021-01-20 22:23:59 +00:00
msi 80c04f15f3 Fix line width in [file attributes] documentation 2021-01-20 22:18:48 +00:00
msi b633ee636f Improve punctuation and wording in [file attributes] documentation 2021-01-20 21:57:38 +00:00
jan.nijtmans cbe4ab7b6a merge-mark 2021-01-20 16:23:03 +00:00
jan.nijtmans f6f8bdc72d Make tclCkalloc.c and tclExecute warning-free on Windows when compiled with --enable-memory=(mem|all). 2021-01-20 16:19:21 +00:00
jan.nijtmans a096c64c32 Fix potential endless loop in "stats" command (only enable in debug-build) 2021-01-20 14:13:15 +00:00
jan.nijtmans a9f031fc1a Don't use LTO for any stub libraries: It's asking for trouble when an extension is compiled with different CFLAGS as the stub library. 2021-01-20 10:57:44 +00:00
jan.nijtmans 2e5746d60c Possible fix (workaround) for [8c025f8f0d]: Run-time error on tcl 8.6.11 32 bits (from cross-compile Centos6.9 64-bits).
Since autoconf-2.59 has limited support for cross-compilation, a better fix has to wait for Tcl 8.7 (which uses autoconf-2.70)
2021-01-20 08:52:10 +00:00
jan.nijtmans 850c978dcc Merge fork 2021-01-20 07:49:39 +00:00
jan.nijtmans 5a3587a3ad Close fork 2021-01-20 07:47:26 +00:00
msi 3345a310b6 Improve clarity of [file attributes] documentation 2021-01-19 20:14:11 +00:00
msi 9038dae6fe Improve clarity of [file attributes] documentation 2021-01-19 20:11:32 +00:00
msi 817e391ddb Improve clarity of [file attributes] documentation 2021-01-19 20:07:54 +00:00
msi 011e7c1e5f Fix missing backslash 2021-01-19 19:51:55 +00:00
msi 040818e1db Improve description of Unix options for [file attributes] (Pt. 2) 2021-01-19 19:41:31 +00:00
msi 7a3766376f Create new branch named "msi-core-8-5-branch" 2021-01-19 16:53:24 +00:00
jan.nijtmans f387d58e76 Merge 8.6 2021-01-19 13:20:39 +00:00
jan.nijtmans afe025dc93 Don't worry about Windows 3.1 any more. 2021-01-19 13:16:05 +00:00
jan.nijtmans 81e7dac314 Document that Tcl_GetByteArrayFromObj accepts a size_t *lengthPtr as well (TIP #481) 2021-01-19 07:50:29 +00:00
jan.nijtmans dbd3f823aa Bugfix for TIP #587 implementation: Always use -eofchar "\032 {}" and _NOT_ -eofchar \032, otherwise there's the risk that ^Z is appended too the open channel. See [5bfe3de008], we don't want to open that can of worms again! 2021-01-15 14:58:03 +00:00
jan.nijtmans 78d6e8f34c Fix [ff658e10fc]: tip 551 in 8.7a4 0b1111_1111 not working. Also fix some indenting in code 2021-01-15 10:52:26 +00:00
jan.nijtmans a7bc79bffb Experiment: Fix [https://core.tcl-lang.org/thread/tktview?name=98ae20f0f5|98ae20f0f5]. Works for any extension using this construct, not only Thread 2021-01-15 09:47:36 +00:00
jan.nijtmans 0cd0d2191b Starting with TIP #514, we know exactly what [largest_int] is. So, make use of that in "string.test" 2021-01-14 16:46:00 +00:00
jan.nijtmans 071381e984 Add mp_unpack() to the libtommath stub table, so this function is available to extensions (and to Tcl itself, but not used yet) 2021-01-13 15:37:21 +00:00
jan.nijtmans 5f79368eaf Merge 8.6 2021-01-13 10:48:37 +00:00
jan.nijtmans aa7bf1b2e1 Fix [b89209f5cd]: compilation error Windows 10 / Visual Studio 2019 2021-01-13 10:42:58 +00:00
jan.nijtmans 370b557389 Fix [b89209f5cd]: compilation error Windows 10 / Visual Studio 2019 2021-01-13 10:38:56 +00:00
jan.nijtmans 711adf15f9 Bring documentation in line with *.decls files 2021-01-12 17:11:52 +00:00
jan.nijtmans a14063d19a Make tclStrToD.c compile on systems without inttypes.h 2021-01-11 16:01:36 +00:00
jan.nijtmans 7ff4e84af2 Merge 8.6 2021-01-11 11:52:01 +00:00
jan.nijtmans 60ca614740 Fix [1dab713a38]: Uninitialized-variable use while parsing '*' in BRE-mode regexps 2021-01-11 11:41:54 +00:00
jan.nijtmans 473d9adddc Fix [1dab713a38]: Uninitialized-variable use while parsing '*' in BRE-mode regexps 2021-01-11 11:39:12 +00:00
jan.nijtmans 089b997044 TIP #481 implementation: Tcl_GetStringFromObj() with size_t length parameter 2021-01-11 08:33:04 +00:00
jan.nijtmans b61dbff448 Make Tcl independent from exact definition of TCL_LL_MODIFIER. In tclStrToD.c we need an _exact_ 64-bit type, _at least_ 64-bit is not good enough here. 2021-01-11 08:23:48 +00:00
msi 4e3cd053db Improve description of Unix options for [file attributes] (Pt. 1) 2021-01-08 20:07:09 +00:00
msi 70da19ccf0 Improve description of Unix options for [file attributes] (Pt. 1) 2021-01-08 20:05:35 +00:00
msi 4206bf2818 Improve description of Unix options for [file attributes] (Pt. 1) 2021-01-08 19:55:51 +00:00
msi a9c9e46669 Fix consistency and grammar in re_syntax.n 2021-01-08 17:15:35 +00:00
msi 3edc49c702 Fix consistency and grammar in re_syntax.n 2021-01-08 16:16:39 +00:00
jan.nijtmans 0872562c80 TIP #592 implememtation: Stop support for Windows XP, Server 2003, Vista, Server 2008 2021-01-08 14:45:53 +00:00
jan.nijtmans f09dcac785 Omit -Wdeclaration-after-statement from CFLAGS: No longer needed since we stopped support for MSVC 6++
Change Tcl_WideInt -> long long in various places: Tcl_WideInt could be a 128-bit type, we don't want that everywhere.
2021-01-08 09:37:25 +00:00
jan.nijtmans 6b7dec8d6a define UWIDE_MAX and friends in terms of Tcl_WideUInt/Tcl_WideInt, since we cannot be sure that Tcl_WideInt == long long 2021-01-07 15:31:52 +00:00
jan.nijtmans ad4c7a03b7 Revise UWIDE_MAX and friends 2021-01-07 14:45:40 +00:00
jan.nijtmans 76fd53b302 Merge 8.7. Don't bother BorlandC, LCC and WatcomC any more, since they (probably) cannot handle Windows 7 API anyway. 2021-01-07 13:42:14 +00:00
jan.nijtmans 7a36f11216 Merge 8.6 2021-01-07 12:31:24 +00:00
jan.nijtmans fed0f920e1 Fix mingw-w64 compiler warnings when using __USE_MINGW_ANSI_STDIO=1. Not recommended, but it should work. See: [https://sourceforge.net/p/mingw-w64/wiki2/gnu%20printf/|gnu printf] 2021-01-07 12:14:55 +00:00
jan.nijtmans 4f237d732e Fix warnings when __USE_MINGW_ANSI_STDIO=1 2021-01-07 10:55:39 +00:00
jan.nijtmans 1227eed18e No need any more for -D_ATL_XP_TARGETING=1 2021-01-07 10:13:24 +00:00
jan.nijtmans a21daf36ae Merge 8.7 2021-01-07 07:37:36 +00:00
msi 2a2321bf6a Fix consistency and grammar in re_syntax.n 2021-01-06 19:43:35 +00:00
jan.nijtmans 5c3f6b06b7 Merge 8.6 2021-01-06 15:48:43 +00:00
jan.nijtmans 3005927df1 Eliminate obsolete AC_HAVE_HEADERS and two more AC_TRY_COMPILE constructs. Some formatting 2021-01-06 15:39:18 +00:00
jan.nijtmans 0a38e523d3 tcltest -> 2.5.4. Version change should have been done at this commit: [95852bc2ed0e2c11] 2021-01-06 10:31:27 +00:00
jan.nijtmans f39dee95d7 TIP #590 follow-up: Restore 2nd 'load' argument in dde/registry pkgIndex.tcl. Otherwise those pkgIndex.tcl files no longer work in a Tcl 8.6 environment.
dde -> 1.4.4, registry -> 1.3.6 (to stop all confusion about the difference to Tcl 8.6.11)
2021-01-06 09:26:30 +00:00
dkf 124e36102e Fix unclear language in re_syntax. [2da4c23916] 2021-01-05 20:35:25 +00:00
dkf fb6da59e2f Fix unclear language in re_syntax. [2da4c23916] 2021-01-05 20:34:35 +00:00
dkf 279c0829fc Fix unclear language in re_syntax. [2da4c23916] 2021-01-05 20:33:49 +00:00
jan.nijtmans 3b7c040233 Merge 8.6: Add 4 processor-types to Win32/Cygwin. "platform" -> 1.0.16 2021-01-05 17:06:14 +00:00
jan.nijtmans c040d037ef Merge 8.5: Add 4 processor-types to Win32/Cygwin. "platform" -> 1.0.16 2021-01-05 17:02:19 +00:00
jan.nijtmans 2f9727a745 Add 4 processor-types to Win32/Cygwin. On Cygwin, don't bother tcl_platform[os], since "Windows NT" is the only one supported. "platform" -> 1.0.16 2021-01-05 16:55:44 +00:00
jan.nijtmans b24275a7c4 Merge 8.6 2021-01-05 14:43:26 +00:00
jan.nijtmans 9f96f3816e Merge 8.5 2021-01-05 14:27:27 +00:00
jan.nijtmans edb8fe7c9b #undef PACKAGE_VERSION in tclConfig.h too, since Tcl and Tk don't necessary have the same version. 2021-01-05 14:24:00 +00:00
jan.nijtmans ab6f3aa7a8 Merge 8.6 2021-01-05 10:29:13 +00:00
jan.nijtmans f8e1773f67 More elimination of (obsolete) AC_TRY_COMPILE 2021-01-05 10:19:03 +00:00
jan.nijtmans 89dbd5cedd Merge 8.6 2021-01-05 09:19:51 +00:00
jan.nijtmans 21e01ee4e5 Merge 8.5. Restore use of AC_HEADER_STDC in win/configure.in: Wait for 8.7 to make that change 2021-01-05 08:23:07 +00:00
jan.nijtmans cc3b85771e Require at least autoconf-2.59 for tools/configure 2021-01-05 08:15:01 +00:00
jan.nijtmans fd512f5f94 Eliminate (obsolete) use of AC_TRY_LINK in */configure.in. Still generates the same */configure scripts with autoconf-2.59. 2021-01-05 08:06:28 +00:00
jan.nijtmans 67639babd5 Merge 8.6 2021-01-04 16:46:25 +00:00
jan.nijtmans 1a457f040a Roll-back part of [4dfa9000e1]: This isn't used for Tcl, but breaks some extensions (like tkImg) 2021-01-04 16:45:36 +00:00
jan.nijtmans 906b33b772 Merge-mark 2021-01-04 16:32:39 +00:00
jan.nijtmans a27098cb71 AC_HELP_STRING -> AS_HELP_STRING 2021-01-04 15:37:02 +00:00
jan.nijtmans dd56627191 Fix [c376607b22]: Tcl 8.6: Extended plane character does not encode correctly to UTF-16 with TCL_UTF_MAX==5 2021-01-04 15:06:34 +00:00
jan.nijtmans 29b5516f5f Merge 8.6 2021-01-04 14:34:18 +00:00
jan.nijtmans ab7b060df7 No longer use deprecated syntax for AC_INIT/AC_OUTPUT. (almost) no change in generated configure scripts 2021-01-04 14:24:13 +00:00
jan.nijtmans 4789e8e063 Merge-mark 2021-01-04 10:01:20 +00:00
jan.nijtmans a29e5ccac3 re-generate win/configure 2021-01-04 09:51:53 +00:00
jan.nijtmans dcebb038ed re-generate win/configure 2021-01-04 09:40:19 +00:00
jan.nijtmans 50199a5302 Merge 8.7 2021-01-04 07:54:50 +00:00
jan.nijtmans 89653c15cf Merge 8.7 2021-01-04 07:48:36 +00:00
dgp 7dd3bef5d3 merge 8.6 2021-01-02 22:53:43 +00:00
dgp c86e9e2b45 merge release 2021-01-02 22:34:55 +00:00
dgp 17b5b3e020 [e7eb94e8d1] typo fix in changes. Each ambiguous hash still identifies only
one ticket, which is good enough.
2020-12-30 18:23:08 +00:00
jan.nijtmans 6d547b0c2c merge-mark 2020-12-29 22:23:30 +00:00
jan.nijtmans ee9004c35f Fix [43d371ac19]: Usage of exit() without including <stdlib.h> in unix/configure 2020-12-29 22:22:26 +00:00
jan.nijtmans 0a3a1a075a Fix [43d371ac19]: Usage of exit() without including <stdlib.h> in unix/configure 2020-12-29 22:21:20 +00:00
dgp e620c687f7 update changes 2020-12-28 15:12:20 +00:00
jan.nijtmans 098ad4c7f3 TIP #587 follow-up: Looks like -encoding utf-8 still was missing in some places, only visible on Windows 2020-12-28 14:46:50 +00:00
jan.nijtmans b91eaa4a75 Merge 8.7 2020-12-26 22:47:02 +00:00
jan.nijtmans 52cf0e0a28 Merge 8.6. Give up handling EXTRA_CC_SWITCHES for c++ compile 2020-12-26 22:12:37 +00:00
dgp 536fad2c6d Suppress testing of known bug only when it is present. Allow tests that pass. 2020-12-26 18:42:09 +00:00
dgp ad77faa0e4 merge 8.6 2020-12-26 18:01:46 +00:00
dgp 3665cff596 changes file updates WIP 2020-12-24 20:27:00 +00:00
jan.nijtmans b5b121bedb Fix [5a15a88490]: Checkin [1f6f21856b] quoting broke unix/installManpage 2020-12-24 16:11:44 +00:00
jan.nijtmans 24c0f50472 correct quoting in unix/installManPage, so $Dir can contain spaces 2020-12-24 16:06:24 +00:00
jan.nijtmans 4e05ae8a64 Merge 8.6 2020-12-24 15:40:48 +00:00
jan.nijtmans 31de47e1d6 unix/configure.in is not supposed to be executable in the distribution 2020-12-24 15:33:59 +00:00
jan.nijtmans 2b54268bb7 unix/configure.in is not supposed to be executable in the distribution.
Don't re-generate unix/tclConfig.h.in and unix/configure as part of "make dist": This should be done with autoconf-2.59, not with whatever autoconf is present on this machine
2020-12-24 15:28:48 +00:00
jan.nijtmans 6acfb3e800 Last pre-autoconf-2.69 obsolete construct eliminated. Works with autoconf-2.59 as well. Still to be tested with autoconf-2.70. 2020-12-24 14:07:55 +00:00
jan.nijtmans 67dd971e70 Fix check for broken strstr/strtoul/strtod functions: Modern C compilers don't accept signature mismatches any more. 2020-12-24 12:09:33 +00:00
jan.nijtmans 5f6824ef23 Convert AC_TRY_COMPILE (which is obsolete now) to AC_COMPILE_IFELSE/AC_LANG_PROGRAM. This still works with autoconf-2.59 too. 2020-12-24 11:46:29 +00:00
jan.nijtmans d56bda5224 Another attempt to make EXTRA_CC_SWITCHES work for c++ compiles in github actions 2020-12-24 11:07:05 +00:00
jan.nijtmans d6bbe53dfb More progress in autoconf-2.70 compatibility. Not to be merged to 8.6 yet! 2020-12-23 15:42:01 +00:00
jan.nijtmans 02cf664be1 (cherry-pick): Update TZ info to tzdata2020e 2020-12-23 15:13:32 +00:00
José Ignacio Marín f74fb9a7dc Update TZ info to tzdata2020e (via merge). 2020-12-23 10:26:33 +00:00
José Ignacio Marín 9fe163167b Update TZ info to tzdata2020e. 2020-12-23 10:12:27 +00:00
jan.nijtmans af23e7a53d EXTRA_CC_SWITCHES quoting doesn't work. Let's try again 2020-12-23 10:01:13 +00:00
jan.nijtmans a128f1c033 Merge 8.6 2020-12-23 08:17:39 +00:00
jan.nijtmans c615f910f7 Missing constraint, in case we are running on Windows 10 in developer mode 2020-12-23 08:04:02 +00:00
jan.nijtmans 649c413c41 Merge 8.6 2020-12-23 07:47:15 +00:00
jan.nijtmans a1c17947a6 (cherry-pick): Repair flaws exposed by debugging test run. 2020-12-23 07:44:27 +00:00
jan.nijtmans da2d3610f9 Fix testcase for [548cd945d6]: Consistant error-code if creating link fails on all platforms. On Win10 disable the testcase, because latest Win10 in "Developer Mode" _can_ create symbolic links to files. 2020-12-23 07:42:19 +00:00
dgp 3dd7667698 Repair flaws exposed by debugging test run. 2020-12-22 16:34:09 +00:00
jan.nijtmans 4291e4e815 Update all configure-related stuff to work with autoconf-2.70 too. For now, everything still generated with (modified) autoconf-2.59 2020-12-22 14:25:30 +00:00
dgp f66286892b merge 8.6 2020-12-22 13:18:20 +00:00
jan.nijtmans 6dd81c7dba Merge 8.6 2020-12-22 09:28:07 +00:00
jan.nijtmans ae17e8d1b4 Compile on github actions using C++ compiler, even without CC=g++ (which doesn't work with autoconf 2.70) 2020-12-22 08:58:52 +00:00
jan.nijtmans d7f4679221 Fix [ea8cd4789c]: Tcl 8.6.11 does not compile with VisualStudio 2010. Thanks Paul! 2020-12-22 07:12:06 +00:00
jan.nijtmans afc0577d2e autoupdate */configure.ac and */tcl.m4. Should still work with autoconf-2.69 too 2020-12-19 22:17:00 +00:00
jan.nijtmans 2215f74b2d Remove g++ builds from travis/github actions. The construct "CC=g++" doesn't work any more with autoconf-2.70 2020-12-18 14:00:56 +00:00
jan.nijtmans d456e92a29 Rename AC_HELP_STRING to AS_HELP_STRING, and fix determination of intptr_t/uintptr_t with autoconf 2.70 2020-12-18 10:42:05 +00:00
dgp 220e5e6245 close fork 2020-12-17 19:07:48 +00:00
dgp 66147b2e11 close fork 2020-12-17 19:05:47 +00:00
jan.nijtmans 928360bd4d Merge fork 2020-12-17 18:58:53 +00:00
jan.nijtmans 9419ff1d29 Merge 8.7 2020-12-17 18:56:24 +00:00
jan.nijtmans 517a6a5159 Merge 8.6 2020-12-17 18:21:24 +00:00
jan.nijtmans 63426886f5 Further elimination of __int64 type 2020-12-17 16:39:25 +00:00
jan.nijtmans 075e333cc2 Undo one change from previous commit: this gives a warning on mingw-w64 2020-12-17 15:47:56 +00:00
jan.nijtmans c5500b6035 Simplifications when assuming VS 2015 or later 2020-12-17 15:44:01 +00:00
jan.nijtmans 0e05734542 Merge 8.7 2020-12-17 14:14:21 +00:00
jan.nijtmans 392ecd0f2d Merge 8.6. Re-generate tclConfig.h.in with autoheader v2.70 2020-12-17 12:48:40 +00:00
jan.nijtmans f9a71ac128 Add .travis.yml and .github/worksflows to "make dist". Use "cp -p" for all files in "make dist" 2020-12-17 12:38:29 +00:00
jan.nijtmans ab4cbd7685 Add .travis.yml and .github/worksflows to "make dist" 2020-12-17 12:27:48 +00:00
jan.nijtmans c4bcec96ea Re-generate configure scripts with (brand-new!!!) autoconf-2.70 2020-12-17 08:11:15 +00:00
jan.nijtmans 4855172d08 Remove "Vista" from manifest. Test simplifications 2020-12-16 15:46:04 +00:00
jan.nijtmans ee2c8b324f TIP #592 implementation: Stop support for Windows XP, Server 2003, Vista, Server 2008 2020-12-16 15:32:20 +00:00
jan.nijtmans fc6c71a6ff Merge 8.7 2020-12-16 15:10:45 +00:00
jan.nijtmans 4ea5470891 Merge 8.7 2020-12-16 15:04:10 +00:00
jan.nijtmans 7795886d49 Merge 8.6 2020-12-16 14:31:39 +00:00
jan.nijtmans fe22db4eda [testConstraint winVista] should be true on Windows 10 too 2020-12-16 14:28:47 +00:00
jan.nijtmans 80a7fdbc90 Merge 8.6 2020-12-16 14:24:12 +00:00
jan.nijtmans 01279acc11 rfe [548cd945d6]: symlinks for Windows 10 2020-12-16 14:11:13 +00:00
dgp 3a3b91de59 merge 8.6 2020-12-15 21:51:56 +00:00
jan.nijtmans 00280a4727 Protect fCmd-28.8 with constaint win10 2020-12-15 11:37:29 +00:00
jan.nijtmans 02ab7419f0 Merge 8.6 2020-12-14 08:49:27 +00:00
jan.nijtmans ebf2863b94 Fix C:\test\tcl8.6.11_rc0\win\..\generic\tclStubInit.c(107) : warning C4761:
integral size mismatch in argument;
Only happening on 32-bit Windows
2020-12-14 08:44:58 +00:00
jan.nijtmans 14cf327d37 Merge 8.6 2020-12-14 08:11:11 +00:00
jan.nijtmans 66bf4b493e Fix [cb4d185ea57b8966]: Fix tests safe-* for tcl-8.6.11rc0 2020-12-14 08:05:08 +00:00
jan.nijtmans 9a7583c219 Fix [fe57ad096d97623e]: Fix test http-4.14 for tcl-8.6.11rc0 2020-12-14 07:33:42 +00:00
jan.nijtmans d06a5c4c22 Merge 8.7 2020-12-13 16:59:33 +00:00
jan.nijtmans c899e46a97 Merge 8.6 2020-12-13 16:45:47 +00:00
jan.nijtmans 56c8c7f4a2 Merge 8.6 2020-12-13 16:38:12 +00:00
jan.nijtmans 4c0c6d80cd make dist 2020-12-13 16:36:23 +00:00
jan.nijtmans 8897e69513 Merge 8.6 2020-12-12 11:39:32 +00:00
apnadkarni e341dd7a16 nmake: fix path in tcl.nmake check 2020-12-12 06:14:02 +00:00
dgp 18c766a08c make dist 2020-12-11 19:21:55 +00:00
jan.nijtmans b15870ed70 Merge 8.6. Get CreateSymbolicLinkW symbol from kernel32.dll, since Windows XP doesn't have it 2020-12-11 14:47:33 +00:00
dgp e3d0b11da5 merge 8.6 2020-12-11 13:35:39 +00:00
jan.nijtmans 4f95cb4de4 Merge 8.6 2020-12-11 12:44:03 +00:00
jan.nijtmans 0045179f39 Update "platform" package to handle macOS Big Sur with arm processor.
Also handle that Catalina and higher no longer support 32-bit applications
2020-12-11 12:41:13 +00:00
jan.nijtmans de49e4b0fc Update "platform" package for Big Sur:
1) Catalina was the last platform supporting 32-bit applications
2) macOS is no longer 10 but 11
3) New "arm" processor
2020-12-11 12:33:27 +00:00
apnadkarni 7b3afa79ed nmake: export zip metadata for Tk and extensions 2020-12-11 09:12:45 +00:00
apnadkarni 21553ac98c Merge 8.6 (msvcrt time64 fixes) 2020-12-11 09:00:27 +00:00
apnadkarni c77e03b978 Fix commits 93ab6a and 606df1. msvcrt time64bit - TCL_{MAJOR,MINOR}_VERSION checks.
msvcrt and time64bit OPTS checks were using Tcl versions before definition.
Moved Tcl version retrieval to earlier in the build as a fix.
Also, < cannot be used with strings, so made the checks numerics.
2020-12-11 08:57:38 +00:00
jan.nijtmans a17bf04dba Merge 8.7 2020-12-11 08:25:14 +00:00
apnadkarni 2120b2e775 Merge 8.6 (nmake) 2020-12-11 07:59:56 +00:00
apnadkarni 33d854e95b nmake: build nmakehlp with -DNDEBUG, sync rules.vc for 8.7 2020-12-11 07:57:41 +00:00
dgp b33993aaf9 merge 8.6 2020-12-10 18:34:37 +00:00
jan.nijtmans 742df3666a Merge 8.6 2020-12-10 18:06:28 +00:00
jan.nijtmans f4ec29ceb2 Update "platform" package to handle Big Sur version numbering. Also remove special case for cygwin/msys2, just make it more generic 2020-12-10 18:05:34 +00:00
jan.nijtmans 0c788cde5c publicize TclWinConvertError 2020-12-10 15:45:44 +00:00
jan.nijtmans 39813465e8 Merge 8.6 2020-12-10 13:27:58 +00:00
jan.nijtmans 615b18fee4 Fix [ed5be77734]: win: "comx:" not recognized as serial port 2020-12-10 13:26:43 +00:00
jan.nijtmans 45c9e44c82 Tweak: account for terminating '\0' 2020-12-10 12:31:37 +00:00
jan.nijtmans c69d9fda47 Potential fix for [ed5be77734]: win: "comx:" not recognized as serial port.
(concluded from code inspection, not tested yet)
2020-12-10 12:17:50 +00:00
jan.nijtmans e5777aad56 Merge 8.6. Add empty "tests/safe-stock86.test", in an attempt to remove this file from the GIT branches (it shouldn't be there, just as in fossil) 2020-12-10 09:50:25 +00:00
jan.nijtmans 6421b7b8b2 RFE 548cd945d6: symlinks for Windows 10 2020-12-10 09:41:09 +00:00
jan.nijtmans 20e0998a32 Use more 0o??? syntax for octal. Clean up build *.yml files 2020-12-10 09:38:24 +00:00
jan.nijtmans 5d4116b638 sync win/rules.vc with Tcl 8.7. No change for 8.6 2020-12-10 09:00:02 +00:00
jan.nijtmans 84bbce0e29 Fix github actions Windows build 2020-12-09 09:56:37 +00:00
jan.nijtmans f67b351466 nmake: OPTS=msvcrt is now the default, even for static builds. Use OPTS=nomsvcrt if you don't want that.
Add more comments in win/*.vc files, describing what's going on.^C
2020-12-09 09:17:19 +00:00
apnadkarni 3fbbf14bf2 nmake: make zipfs mount point consistent with Unix/autoconf 2020-12-09 06:17:50 +00:00
apnadkarni 9f88ecdd97 nmake: subsume staticpkg option within static builds 2020-12-09 04:31:07 +00:00
jan.nijtmans 56dbbded83 Add -finput-charset=UTF-8 and -fextended-identifiers to gcc (and clang). All C sources can now use UTF-8, as far as gcc/clang/msvc support it. Not used yet 2020-12-08 15:31:15 +00:00
apnadkarni f5e6fef433 TIP 430: generate and embed library zip. 2020-12-08 11:06:24 +00:00
apnadkarni 070d566ad5 TIP 430: generate and attach library zip 2020-12-08 10:46:12 +00:00
jan.nijtmans 0a04dce70d Merge 8.7 2020-12-08 10:37:03 +00:00
jan.nijtmans 35231ec0d7 Skip testcases filesystem-7.1.[1|2] with msvc OPTS=staticpkg: This isn't supposed to work 2020-12-08 10:30:05 +00:00
jan.nijtmans 99a90efbfd TIP #590 follow-up: Adapt documentation and tclStubLib.c 2020-12-08 10:14:49 +00:00
jan.nijtmans b6088f7331 Merge 8.7 2020-12-08 09:04:03 +00:00
dgp 2f178f93ab merge 8.6 2020-12-07 16:02:44 +00:00
jan.nijtmans 49baa37b9c Put dde/registry obj-files in the stub library in stead of the static library. Needed to combine --disable-shared build of Tk with --enable-shared build of Tcl in a single executable 2020-12-07 15:08:16 +00:00
jan.nijtmans f6bd13629f In configure/make Windows build, static builds include dde and registry extension statically too implicitly 2020-12-07 14:25:31 +00:00
jan.nijtmans 025153490f Merge 8.6 2020-12-07 13:57:11 +00:00
jan.nijtmans cf333de098 rules.vc: Make sure that 3th "load" argument is titlecased in pkgIndex.tcl 2020-12-07 13:53:21 +00:00
apnadkarni f3f92eae51 nmake: Generate libtcl_VERSION.zip as per TIP 430 2020-12-06 10:39:22 +00:00
apnadkarni 6343875344 Merge core-8-branch for new rules.vc 2020-12-06 09:39:25 +00:00
apnadkarni fcee72d2c7 Merge 8.6 2020-12-06 08:09:57 +00:00
apnadkarni fc71c7c2fc nmake builds: extract {TCL,TK}_RELEASE_SERIAL and patch letters from {tcl,tk}.h 2020-12-06 08:06:03 +00:00
apnadkarni 0f2d72cefb Create new branch named "apn-sfe" 2020-12-05 11:06:15 +00:00
apnadkarni e5bf8e9ed0 Fix suffix on single file exe name 2020-12-05 02:51:10 +00:00
jan.nijtmans 29be47f451 Merge 8.7 2020-12-04 15:32:17 +00:00
jan.nijtmans c47a861663 Merge 8.6 2020-12-04 10:44:13 +00:00
jan.nijtmans 0cdd87c215 Merge 8.5 (syncing "tcltest" package). Use more uppercase hex representations 2020-12-04 10:31:43 +00:00
jan.nijtmans cd48044e1b Backport "tcltest" package from 8.7. No changes when running on 8.5 or 8.6 2020-12-04 10:19:51 +00:00
jan.nijtmans 4fa48d135a Merge 8.6 2020-12-04 10:04:33 +00:00
jan.nijtmans 25084dcd33 Merge 8.5 2020-12-04 10:01:50 +00:00
jan.nijtmans 9a3e53bd90 TclWordEnd was removed in 8.1, so those testcases cannot be run anymore 2020-12-04 10:00:56 +00:00
jan.nijtmans ebd7b1edb7 Fix 4 socket testcases on Msys (those fail on Cygwin too) 2020-12-04 09:58:37 +00:00
jan.nijtmans 86cfccca91 TIP 590: Recommend lowercase Package Names 2020-12-04 09:56:08 +00:00
apnadkarni efb126543f Add makefile.vc target sfe for single-file executable 2020-12-03 16:50:23 +00:00
jan.nijtmans c30f3e9569 Merge 8.6 2020-12-03 14:39:19 +00:00
jan.nijtmans c99f354166 two more 0o??? notations 2020-12-03 13:57:56 +00:00
jan.nijtmans defc33228d Use 0o??? notation for octal numbers in tools and testcases in stead of 0???. Although it still works in 8.6, it is deprecated an will be removed in 9.0. 2020-12-03 13:51:18 +00:00
jan.nijtmans f23698ae34 Merge 8.6 2020-12-03 09:52:59 +00:00
jan.nijtmans 910d0222de Extend "platform" package for msys2 -> platform 1.0.15 2020-12-03 09:45:17 +00:00
jan.nijtmans a3322b06ac Fix syntax error in win/makefile.vc 2020-12-03 09:37:28 +00:00
jan.nijtmans 482091f871 Extend "platform" package for msys2 -> platform 1.0.15 2020-12-03 09:31:00 +00:00
jan.nijtmans b1517df3ff Simplify some \\u???? escape sequences to \\x?? 2020-12-03 09:09:25 +00:00
jan.nijtmans a2e1bdf3b5 Merge 8.6 2020-12-02 11:58:01 +00:00
jan.nijtmans c387e380de Don't use -opt:nowin98 linker option any more. See: [https://bugzilla.mozilla.org/show_bug.cgi?id=130372] 2020-12-02 11:57:04 +00:00
jan.nijtmans 1adac52046 Merge 8.6 2020-12-02 11:31:01 +00:00
jan.nijtmans 15449e71fb Merge 8.5 2020-12-02 11:29:52 +00:00
jan.nijtmans 02c730b298 Fix linker message on windows: LINK : warming LNK4108: /ALIGN specified without /DRIVER; image may not run.
This options was only useful on MSVC++ 5.0 and earlier, which is no longer supported
2020-12-02 11:19:57 +00:00
jan.nijtmans 9727e58e7d Add options to workflow step titles 2020-12-01 16:41:10 +00:00
jan.nijtmans 2f8611013d Do 4 types of windows builds (just as we did on Travis) 2020-12-01 16:35:59 +00:00
jan.nijtmans fc7a2d97e0 Remove redunant piece of SC_ENABLE_SHARED: The AC_ARG_ENABLE already generates this part, resulting in duplicate code in the "configure" script 2020-12-01 16:25:30 +00:00
jan.nijtmans 7c3b884ac2 Another TIP #589 side-effect: Make sure that the encoding used in ::tcltest::viewFile matches the one in ::tcltest::makeFile 2020-12-01 15:28:03 +00:00
jan.nijtmans 5878b9510b Fix 2 testcases in Windows. Cause: tcltest::makeFile should assume the same encoding as the "source" command uses (TIP #589)
Aso remove the ::tcltest::bytestring command: It doesn't work any more starting Tcl 8.7 since the "identity" encoding is gone (TIP #345)
2020-12-01 15:15:28 +00:00
jan.nijtmans 3ae4ed89d0 Remove incomplete stuff from .project: It is not enough to make actual building from within Eclipse possible 2020-12-01 12:17:18 +00:00
jan.nijtmans ff1e919a1b Merge-mark 2020-12-01 11:56:19 +00:00
jan.nijtmans d9fa72d22a Handle 5 test-failures on Cygwin/Msys 2020-12-01 11:54:35 +00:00
jan.nijtmans 3df3c35057 Merge 8.6 2020-12-01 08:53:12 +00:00
jan.nijtmans 92b25c6016 Merge 8.5 2020-12-01 08:50:57 +00:00
jan.nijtmans 53a9a5dc8f Missing '_' in unix/tcl.m4 (Only relevant for mingw) 2020-12-01 08:49:30 +00:00
jan.nijtmans 83f0cd1c03 Merge 8.6 2020-11-30 16:53:34 +00:00
jan.nijtmans fa960af760 Minor fixes + copy editing :). See [https://github.com/tcltk/tcl/pull/8] 2020-11-30 16:52:50 +00:00
jan.nijtmans 180cec8aa9 Merge 8.6 2020-11-30 14:20:34 +00:00
jan.nijtmans 17de94982b doc update: 16-bit DOS appllications are not supported any more.
Use &amp;bull; in stead of &amp;#8226; representing bullets in html
2020-11-30 14:16:23 +00:00
jan.nijtmans 0134af324d Merge 8.6 2020-11-30 13:37:14 +00:00
jan.nijtmans 87439e7d28 Fix [b6a7fc9243]. Also add (back) \*(qo, which might be used in older man-pages 2020-11-30 13:32:00 +00:00
jan.nijtmans 2ac074313b Fix [6b1c6bb09c]: Extended plane character does not encode correctly to UTF-16 with TCL_UTF_MAX==4
Als use more of TIP #587 in encoding.test
2020-11-30 12:18:19 +00:00
jan.nijtmans 7081037955 Merge 8.6 2020-11-30 08:57:18 +00:00
jan.nijtmans eb342fb1e0 Update README.md 2020-11-30 08:52:04 +00:00
jan.nijtmans 231cf96018 Merge 8.6 2020-11-30 08:46:27 +00:00
jan.nijtmans 4ba63aa46a Merge 8.5 2020-11-30 08:31:29 +00:00
jan.nijtmans 15194461b1 Cherry-pick part of "msys2-fixes_v001" branch: build/test fixes for msys2 2020-11-30 08:21:20 +00:00
dkf 2664737588 Added single-file distributions of Tcl for all main platforms.
These are *UNOFFICIAL* builds as they do not correspond to particular releases.

The macOS build is packaged in a .dmg with a README that explains how to run it
as the binary is not signed or notarized (and this is unlikely to change).
2020-11-27 18:13:10 +00:00
dkf 0cb78052e4 That's the best we can do without entering the morass that is signing/notarization on macOS; Windows now uses the right version IDs 2020-11-27 18:07:05 +00:00
jan.nijtmans 3c86724fcf Merge 8.6 2020-11-27 14:39:40 +00:00
jan.nijtmans 750dd56fe0 Merge 8.5 2020-11-27 14:37:41 +00:00
jan.nijtmans 5bf4c011e1 label change in win-build.yml 2020-11-27 14:28:18 +00:00
jan.nijtmans 965d357ab6 Merge 8.6 2020-11-27 13:50:33 +00:00
jan.nijtmans a2c547e12a Merge 8.5 2020-11-27 11:19:07 +00:00
dkf 8c7898b5d2 Better version ID, trying to track down weird macOS problem 2020-11-27 09:58:46 +00:00
jan.nijtmans 2ed258bb67 Fix winFCmd testcase. Add --disable-shared and TCL_UTF_MAX=4 builds to github actions 2020-11-27 07:41:58 +00:00
dkf 005227c53d Try to use a .dmg for macOS distribution 2020-11-26 20:09:11 +00:00
jan.nijtmans 96f84a6d9a Merge 8.6 2020-11-26 14:54:04 +00:00
jan.nijtmans 6ad60f8b3b Get rid of "register" keyword, forbidden in c++20.
Fix some more warnings, discovered in c20/c++20 mode
2020-11-26 14:43:22 +00:00
jan.nijtmans cf0a602c97 Merge 8.6 2020-11-26 08:28:35 +00:00
jan.nijtmans dbb32499b0 Merge 8.5 2020-11-26 08:21:30 +00:00
jan.nijtmans fd1bc4abd1 More TCL_UNUSED 2020-11-26 07:52:00 +00:00
jan.nijtmans 9393b695b2 squelch warning by using proper format specifiers 2020-11-26 07:37:40 +00:00
jan.nijtmans 7d9d9597aa grammar 2020-11-26 07:23:16 +00:00
jan.nijtmans 259f659ad6 Merge 8.7 2020-11-25 13:51:32 +00:00
dkf 49ad442ac6 Switch to older Ubuntu so that we build with older glibc. Thanks to morganw for testing. 2020-11-25 11:16:46 +00:00
jan.nijtmans e037b3a40c Make HTML documentation html5-compatible. Still works the same with older browsers too.
Remove obsolete winhelp construction parts: winhelp is obsoleted since Vista
2020-11-25 09:57:15 +00:00
jan.nijtmans 7c1cfd6e15 Merge 8.7 2020-11-25 09:52:14 +00:00
jan.nijtmans 1aa3608a1c Remove the Tcl_GetValue() functionality. This can always be developed separately 2020-11-25 09:16:11 +00:00
dkf cada5eb9bd Name of target is different 2020-11-25 09:13:55 +00:00
jan.nijtmans f33056b162 Slightly friendlier "jobs" labels. Fix exact OS (Linux/Mac/Windows) we want to build on, not just "latest" 2020-11-25 08:15:16 +00:00
dkf fc553a3ea1 Experimental branch: building single file distributions 2020-11-25 00:41:24 +00:00
jan.nijtmans aca216973f Some missing test-constraints 2020-11-24 15:04:05 +00:00
jan.nijtmans 1704d23d60 Fix testcases on Windows. Use more "info loaded" as appropriate 2020-11-24 14:45:38 +00:00
jan.nijtmans 188c4f944e contents.htm -> index.html and *.htm -> *.html 2020-11-24 08:24:12 +00:00
jan.nijtmans c15270a797 Fix "make dist" 2020-11-24 07:51:38 +00:00
jan.nijtmans a1dd05a170 More ©-sign consolidation 2020-11-23 09:16:00 +00:00
jan.nijtmans 55383ed9b1 Now that all Tcl source files are UTF-8 by default, we can use the ©-sign whenever reasonable. 2020-11-23 08:25:48 +00:00
jan.nijtmans a73325fed0 Merge 8.6 2020-11-20 14:58:13 +00:00
jan.nijtmans ee4dcff50f Don't use "Copyright &lt;year> _by_" any more. This results in more consistant copyright statements in the (html) documentation 2020-11-20 14:48:57 +00:00
jan.nijtmans e2721f9546 Merge 8.7 2020-11-20 14:08:43 +00:00
jan.nijtmans 32beb1556e Add a --disable-shared build to github actions 2020-11-20 14:02:01 +00:00
jan.nijtmans 467e0d60b2 Add a --disable-shared build to github actions 2020-11-20 13:59:36 +00:00
jan.nijtmans 4a451f540f Generate html documentation in html5 format. Fix some html5 compatibiliy warnings.
Remove old htmlhelp-related parts (since this is obsolete since Vista)
2020-11-20 13:46:59 +00:00
jan.nijtmans edcb5e1d91 shorten github actions build name 2020-11-20 08:58:39 +00:00
jan.nijtmans 58bf5b79b7 Merge 8.7 2020-11-20 08:44:50 +00:00
jan.nijtmans b4cc01c658 Merge 8.6 2020-11-20 08:26:02 +00:00
jan.nijtmans ef7a8aec00 Use '&' in stead of 'and' in copyright statements consistantly 2020-11-20 08:24:53 +00:00
jan.nijtmans e8b55fb733 Allow tools/tcltk-man2html.tcl to work with both configure.in and configure.ac: It could be used in extensions which still use an older autoconf 2020-11-19 15:11:04 +00:00
jan.nijtmans 17e7dbc31a Merge-mark 8.5 2020-11-19 15:07:10 +00:00
jan.nijtmans d1dfef4884 Handle github actions test failures. Backported from 8.6 2020-11-19 09:39:20 +00:00
jan.nijtmans 14ec7c1d85 Merge 8.7 2020-11-19 08:57:49 +00:00
jan.nijtmans 8e1f957a66 More usage of TclUtfToUCS4/TclUniCharToUCS4 in stead of it's UniChar variants: This handles surrogate pairs better. 2020-11-18 13:51:02 +00:00
jan.nijtmans c55eb93bb4 Merge 8.6 2020-11-18 11:03:11 +00:00
jan.nijtmans 26156cc1cc Merge 8.5 2020-11-18 10:59:37 +00:00
jan.nijtmans f7b532246a Enhance misleading test-case utf-6.23 with better diagnostics: Byte 0xE8 is the start of a 3-byte UTF-8 sequence, so Tcl_UtfNext is expected to read next byte and see if it is a continuation byte 2020-11-18 09:49:08 +00:00
jan.nijtmans c4b8fd351a Add github actions build. Use Titlecase in Tcl_StaticPackage 2020-11-18 09:15:31 +00:00
jan.nijtmans a28856a322 Merge 8.6 2020-11-17 14:36:30 +00:00
jan.nijtmans f88225f6fb Extend tcltk-man2html-utils.tcl a little more: Allow original AT&T syntax for more accented characters, and add support for some ligatures. Use this in re_syntax.n 2020-11-17 14:35:42 +00:00
dkf 6098040754 Test fails with Windows in CI, not MSVC 2020-11-17 12:36:59 +00:00
oehhar 48385f8bba Ticket [ac661a684d]: Tcl_NotifyChannel man page: "no writable callback on pending flush" missing 2020-11-17 10:17:21 +00:00
oehhar 32e54c3504 Ticket [ac661a684d]: Tcl_NotifyChannel man page: "no writable callback on pending flush" missing 2020-11-17 10:11:24 +00:00
jan.nijtmans da2c0d731a Merge 8.6 2020-11-17 09:12:55 +00:00
jan.nijtmans 4929dd61e1 Generated html still not 100% correct .... 2020-11-17 09:11:09 +00:00
jan.nijtmans 95fad70001 Merge 8.6 2020-11-17 08:46:06 +00:00
jan.nijtmans ffda48d07b Extend tcltk-man2html-utils.tcl: Add euro-sign too 2020-11-17 08:45:22 +00:00
jan.nijtmans b9fdbb0710 Merge 8.6 2020-11-17 08:41:07 +00:00
jan.nijtmans 969ef21225 Extend tcltk-man2html-utils.tcl, so it can handle the TIP #588 man-page. Also fix 2 (minor) syntax errors in man-pages 2020-11-17 08:39:19 +00:00
oehhar d7092f4a55 Merge documentation changes for http and dict from branch [oehhar-documentation-tickets] 2020-11-16 15:08:17 +00:00
oehhar 0566be32d5 Merge documentation changes for http and dict from branch [oehhar-documentation-tickets] 2020-11-16 15:03:25 +00:00
oehhar 45aa988905 Ticket [361303]: http doc: status values incomplete 2020-11-16 14:37:00 +00:00
oehhar 7fa0505ae8 Ticket [4f511270af7]: http documentation: -query data may be any data 2020-11-16 14:14:36 +00:00
oehhar 413ce795e0 Ticket [93551c1230]: Document that http::geturl processes the event loop without -command 2020-11-16 14:06:50 +00:00
oehhar 71a412b8da Ticket [d8ae5d5f4c]: Documentation of dict filter script: script results, not returns a boolean 2020-11-16 13:55:33 +00:00
jan.nijtmans 32d5f89b18 Merge 8.6 2020-11-16 13:17:35 +00:00
jan.nijtmans 0589f3b799 Fix 2 testcases which failed when compiled with TCL_UTF_MAX>3 2020-11-16 13:12:26 +00:00
jan.nijtmans c13d3b0405 Merge 8.6 2020-11-16 12:55:49 +00:00
jan.nijtmans 0943b71810 Enhance misleading test-case utf-6.23 with better diagnostics: Byte 0xE8 is the start of a 3-byte UTF-8 sequence, so Tcl_UtfNext is expected to read next byte and see if it is a continuation byte.
Comment 4 testcases (utf-6.110/111/114/115) for being misleading too, because they don't even call Tcl_UtfNext().
No change to code, only testcases
2020-11-16 12:48:00 +00:00
jan.nijtmans a3a070b13c TIP #586 implementation: C String Parsing Support for binary scan 2020-11-16 10:53:58 +00:00
dkf dac1c2f4f2 Merge 8.6 2020-11-16 10:06:20 +00:00
dkf 106838de02 Clean up for GitHub Actions as our CI service 2020-11-16 09:26:07 +00:00
dkf ffa8d1d461 Disable test that fails in CI environments 2020-11-16 09:24:33 +00:00
dkf eff08da703 Rethinking how to do a build matrix on several platforms 2020-11-15 15:48:43 +00:00
dkf 807ed7b13c Added MSYS/gcc build for Windows, renamed Linux build step 2020-11-15 09:17:41 +00:00
dkf 3ef704b39c Updated README 2020-11-15 08:38:14 +00:00
dkf 346721f3f0 Fix minor errors 2020-11-15 08:35:49 +00:00
dkf b3e4fc2a04 Fixed some tests, added trial macOS build 2020-11-14 12:25:38 +00:00
dkf a22953bb77 Back to powershell 2020-11-14 09:31:49 +00:00
jan.nijtmans d8f5e027e2 merge-mark 2020-11-13 16:59:36 +00:00
jan.nijtmans 8e61a58c14 Backport [fc1e203728]: backout e56a9f214a. If it was wrong in core-8-branch, it's wrong here too. 2020-11-13 16:55:36 +00:00
jan.nijtmans 8adc51759b Merge 8.7 2020-11-11 16:32:51 +00:00
culler c41e7ffff5 backout e56a9f214a 2020-11-10 18:47:47 +00:00
dgp bd382d87b3 merge 8.6 2020-11-10 18:38:43 +00:00
culler f809af7e7b Merge 8.6 2020-11-10 17:52:04 +00:00
culler a376924771 Set a default DESTDIR in macosx/GNUmakefile 2020-11-10 17:50:09 +00:00
dgp 1e44705dc8 merge 8.6 2020-11-10 16:40:14 +00:00
jan.nijtmans 72c49f6909 Merge 8.7. Tweak "tclreg" directory/library name and tclLoad.c, such that the entry point of the "dde" and "registry" extensions can be guessed correctly 2020-11-10 11:55:34 +00:00
dkf 20664f1fa1 Cleaning up the actions and trying to make them behave more usefully on Windows. 2020-11-10 09:26:10 +00:00
dkf 44d6e3ab5e merge mark 2020-11-09 09:15:00 +00:00
dkf 33955d6933 Copied build control files for Github Actions from 8.7 2020-11-09 09:13:57 +00:00
dkf f25b288505 Github Actions seem to be working 2020-11-09 09:07:42 +00:00
dkf dd45c8be9d Merge 8.7 2020-11-08 17:31:38 +00:00
dkf 40b3d4d5dd TIP 582: Comments in Expressions 2020-11-08 17:21:09 +00:00
dkf 25c115b5a8 Added badges to README 2020-11-08 13:38:20 +00:00
dkf d4ef5a261a Added experimental Windows CI build instructions 2020-11-08 13:34:03 +00:00
dkf 81a445ad46 Updated arrangement 2020-11-08 12:08:01 +00:00
dkf ca9f2d6210 Updated README 2020-11-07 14:29:06 +00:00
dkf 0b56647743 Updated workflow name 2020-11-07 14:21:15 +00:00
dkf f827fd2a9d Added basic github action starter 2020-11-07 14:14:17 +00:00
jan.nijtmans d60bc321ce Merge 8.6 2020-11-06 17:33:22 +00:00
jan.nijtmans 4404292972 Add MSVC "StaticPackage" build to travis. Fix another bug in winDde.test which didn't account for statically loaded dde package. 2020-11-06 17:17:41 +00:00
jan.nijtmans 82ffc550db Merge jn-module-names. Sorry Don, but this is 100% compatible! 2020-11-06 16:11:58 +00:00
jan.nijtmans 89e3b6811b Deprecate the (internal) functions TclGuessPackageName/TclGetLoadedPackages functions, since they turn out to be useless. The can be removed in 9.0 2020-11-06 14:43:48 +00:00
jan.nijtmans 3c53be5e75 Correct casing of "packageName" argument in Tcl_StaticPackage() call and "load" command (which - actually - is not a packageName at all ...)
UPDATE: I am moving this to a feature branch.  Changing the arguments passed to Tcl_StaticPackage will be an incompatible break for any scripts currently searching the [info loaded] list for "dde" or "registry".  Not a change we should put in a patchlevel without at least a ticket to record the explanation and a (POTENTIAL INCOMPATIBILITY) warning.
2020-11-06 13:32:39 +00:00
jan.nijtmans feb336f6b3 Lesser TIP #590 implementation: Only package renaming, no code changes 2020-11-06 09:59:46 +00:00
jan.nijtmans cccc07aa28 Merge 8.7 2020-11-05 17:06:22 +00:00
jan.nijtmans efe33a9fd9 Vary dltest package names for test purposes 2020-11-04 08:55:50 +00:00
jan.nijtmans ce3437bf88 Undo experimental unrelated changes 2020-11-03 16:40:32 +00:00
jan.nijtmans e69d8e8e92 Correct casing in some error-messages 2020-11-03 16:24:01 +00:00
jan.nijtmans 8607752aa6 Case-sensitive package names 2020-11-03 15:32:46 +00:00
dkf b7efdfe9bc Merge 8.7 2020-11-01 14:25:49 +00:00
dgp 27cdb091ce merge 8.6 2020-10-30 20:18:40 +00:00
jan.nijtmans d9737c5991 Merge 8.7 2020-10-30 15:13:12 +00:00
jan.nijtmans 3b0ee42270 Merge 8.6 2020-10-30 14:05:26 +00:00
jan.nijtmans f163c24b4c Simplify testcases using "incr" 2020-10-30 13:56:15 +00:00
jan.nijtmans 8f3e8012b1 Merge 8.6 2020-10-30 13:37:42 +00:00
jan.nijtmans 076a7e2839 Add "{}" around many "expr" commands in testcases. Also in doc/expr.n 2020-10-30 13:27:52 +00:00
dgp 49268667e2 merge 8.6 2020-10-29 19:34:55 +00:00
jan.nijtmans cfe53b8870 Merge 8.6 2020-10-29 11:18:19 +00:00
jan.nijtmans 9efaa4d7f1 Fix implib filenames (adapted from Mingw2's 006-proper-implib-name.mingw.patch)
3 new testcases
2020-10-29 10:04:24 +00:00
jan.nijtmans dc84eca339 3 new testcases 2020-10-29 09:42:42 +00:00
jan.nijtmans f15717bcda Update TZ info to tzdata2020d. 2020-10-29 09:25:55 +00:00
jan.nijtmans ff316586bc Fix implib filenames (adapted from Mingw2's 006-proper-implib-name.mingw.patch) 2020-10-29 08:56:17 +00:00
jan.nijtmans 109828f090 Slight tweak to previous commit: Move definition of __USE_MINGW_ANSI_STDIO to the Makefile 2020-10-29 07:47:08 +00:00
jan.nijtmans fb3868da56 Merge 8.7 2020-10-28 15:10:36 +00:00
oehhar f145d5f091 Corrected doc: modifier C instead A 2020-10-28 06:59:12 +00:00
dgp f986721020 merge 8.6 2020-10-27 21:10:41 +00:00
dgp 0df05b3515 [11229bad5f] Fix the bytecode compiler for [string insert]. 2020-10-27 20:27:19 +00:00
dgp 84623a09f2 Use TCL_ERROR to signal inability to compile. 2020-10-27 20:24:13 +00:00
dgp 1c0ca80fe5 [11229bad5f] New test to demonstrate the bug. 2020-10-27 20:09:37 +00:00
jan.nijtmans 17211d39a0 Merge 8.6 2020-10-26 23:00:59 +00:00
jan.nijtmans 37d6f90099 Revert changes in previous commit to clock.n and lassign.n 2020-10-26 22:58:22 +00:00
José Ignacio Marín 32d6283561 Update TZ info to tzdata2020d (via merge). 2020-10-26 20:32:46 +00:00
José Ignacio Marín b0654427ca Update TZ info to tzdata2020d. 2020-10-26 20:32:16 +00:00
jan.nijtmans 6e6d624ec3 Merge 8.6 2020-10-26 16:15:30 +00:00
jan.nijtmans 34d3750e3c Fix [48898ab5f6a0d957]: Too few is better than not enough? (Inconsistent error messages) 2020-10-26 15:07:03 +00:00
jan.nijtmans 577981fee9 re-trigger Travis build (and fix some eol-spacing) 2020-10-26 14:45:47 +00:00
jan.nijtmans 2ae1425228 Merge 8.6. Update "changes", but left out numerous utf-8 testsuite changes and TZ update (since 2020d will come soon) 2020-10-26 14:38:05 +00:00
oehhar 31145f178e Copied man page and test from Androwish https://www.androwish.org/home/ci/bc8b7e8094b66169 2020-10-26 10:53:29 +00:00
oehhar 861d8f512f TIP586: C String Parsing Support for binary scan 2020-10-25 20:03:10 +00:00
jan.nijtmans 63855497af Merge 8.7 2020-10-24 14:50:11 +00:00
jan.nijtmans 263312727f Merge 8.7 2020-10-24 14:41:49 +00:00
jan.nijtmans 48d0827130 Merge 8.6 2020-10-23 15:46:20 +00:00
jan.nijtmans 1c788e178d Fix warning: /home/jboss/workspace/tcl8.7/generic/tclIO.c:9997:27: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]
9997 |   RemovePoint(nextPtr)[0] = '\r';
      |                           ^
2020-10-23 15:36:16 +00:00
dgp d6340955cf merge 8.6 2020-10-23 12:53:44 +00:00
jan.nijtmans 021af90722 Merge 8.7 2020-10-22 14:31:26 +00:00
dgp 7d3aa74249 merge 8.6 2020-10-21 20:42:31 +00:00
culler c6927aa242 Merge 8.6 2020-10-19 19:45:47 +00:00
dgp bb9c489d22 merge 8.6 2020-10-19 14:09:14 +00:00
jan.nijtmans d970d6f3f6 Merge 8.7 2020-10-14 09:43:02 +00:00
jan.nijtmans cfc633e793 Merge 8.7 2020-10-14 06:08:50 +00:00
dgp a3b5f315c6 merge 8.6 2020-10-13 15:39:21 +00:00
dgp dac1dde5ee merge 8.6 2020-10-09 11:41:47 +00:00
dgp 359461f326 merge 8.6 2020-10-08 20:47:29 +00:00
dgp 5ef16060be merge 8.6 2020-10-07 14:55:25 +00:00
dgp cd8531d293 merge 8.6 2020-09-30 15:59:51 +00:00
dgp 4d4d50dc93 merge 8.6 2020-09-30 14:02:26 +00:00
dgp 0188c9979d merge 8.6 2020-09-28 13:07:29 +00:00
dgp 2394d76c65 merge 8.6 2020-09-21 14:10:25 +00:00
dgp d7aa18482a merge 8.6 2020-09-20 16:00:38 +00:00
dgp 8c327a0577 merge 8.6 2020-09-19 16:35:01 +00:00
dgp 1d9b09692d merge 8.6 2020-09-15 16:24:35 +00:00
dkf fe94c1d6c4 Tricky case in function calls. 2020-08-24 13:31:00 +00:00
dkf 1192757fb7 Added two test cases 2020-08-24 08:56:34 +00:00
dkf c76cad8a92 Added documentation 2020-08-22 14:24:31 +00:00
dkf 42a34d459e Implementation of TIP 582: comments in expressions 2020-08-22 14:14:05 +00:00
dgp d281b9c141 merge 8.6 2020-08-05 17:07:18 +00:00
dgp d3aaff6a4e merge 8.6 2020-07-27 21:30:27 +00:00
dgp 64996d4c1a Some additions to changes. 2020-07-24 20:24:08 +00:00
dgp 9185af5e7a merge 8.6 2020-07-23 19:17:44 +00:00
dgp e2610bc7c7 merge 8.6 2020-07-10 18:42:34 +00:00
jan.nijtmans ae4f67d283 First bunch of changes. Please review! 2020-07-09 10:14:50 +00:00
dgp f289a9d57e merge 8.6 2020-07-07 15:32:20 +00:00
dgp c56d964dcb Bump to 8.6.11 for release. 2020-07-06 20:34:31 +00:00
jan.nijtmans a09671a0a0 Change implementation "charstart", not behaving as "prevchar" any more. Also optimize charend/charstart for TCL_UTF_MAX>3 (not need to do actual conversion then). 2020-05-29 13:36:58 +00:00
jan.nijtmans 494d65beb1 Remove nextword/prevword. Rename nextchar/prefchar to charend/charstart, for consistancy with wordend/wordstart. Slightly adapt wordend/wordstart when index is out of range. 2020-05-28 11:44:59 +00:00
jan.nijtmans 0fce9600ee Finish implementation of "string nextchar|nextword|prevchar|prevword". Not thourougly test yet, but seems OK at first sight. 2020-05-25 11:53:11 +00:00
jan.nijtmans 52819473a2 Merge-mark 2020-05-25 09:48:24 +00:00
jan.nijtmans 2d7e36f006 Fix "string is wordchar" in compiled case handling characters > U+FFFF. Adapt testcase exposing the problem. 2020-05-25 07:48:15 +00:00
jan.nijtmans 2b1daf9bb2 Put back "string bytelength", not _that_ important for this TIP.
Document that Tcl_UtfCharComplete() can be used now to protect Tcl_UtfNext()
2020-05-24 22:29:07 +00:00
jan.nijtmans 017257e0ef Rewrite "string wordend" to use the Tcl_UniChar array. 2020-05-23 22:07:53 +00:00
jan.nijtmans 1075137cfc Fix testsuite when "string bytelength" doesn't exist. 2020-05-23 21:51:12 +00:00
jan.nijtmans 0a2c1e30b1 Split more "string" functions. New helper function TclUniCharToUCS4(), not used yet but that's the next step. 2020-05-22 21:28:16 +00:00
jan.nijtmans d6deb4d6d9 New "string" subcommands: "nextchar", "nextword", "prevchar", "prevword". Not implemented yet (for now same as "wordstart"/"wordend"). Deprecate "string bytelength". 2020-05-22 15:27:43 +00:00
jan.nijtmans bc13dc596e Merge 8.7
Add function Tcl_UniCharFold(). It's the same as Tcl_UniCharToLower() for now, but that will change.
2020-05-22 14:36:34 +00:00
jan.nijtmans 8c514a6101 Merge 8.7. Update documentation 2020-05-18 10:51:17 +00:00
jan.nijtmans 9402bad3f4 Merge 8.7. Further progress with TIP implementation. 2020-05-13 22:07:13 +00:00
jan.nijtmans 648162204d First, experimental implementation of TIP #575. Barely tested, will fail. WIP 2020-05-12 18:59:04 +00:00
dgp e4c1bf052f Tests demonstrating the bug. Work on a fix can go here. 2020-04-26 20:49:43 +00:00
jan.nijtmans 35776acac0 Merge 8.7 2018-10-23 21:35:16 +00:00
jan.nijtmans 86ee149689 merge 8.7 2018-10-19 19:22:33 +00:00
jan.nijtmans d883e08781 Merge 8.7 2018-10-11 18:54:23 +00:00
jan.nijtmans 89d6aec1f9 Merge 8.7
Add Unsigned functions to the implementation. TIP text is still far behind describing what's going on here.
2018-10-09 18:12:41 +00:00
jan.nijtmans 617405c023 Re-base to 8.7 2018-10-08 22:22:14 +00:00
jan.nijtmans b616f99ca6 rebase 2013-07-09 09:30:34 +00:00
jan.nijtmans 6546b1dd3d Tk bug [http://core.tcl.tk/tk/tktview?name=1712098|1712098] 2013-06-28 12:31:47 +00:00
607 changed files with 38744 additions and 30643 deletions
-2
View File
@@ -7,7 +7,6 @@ compat/zlib/win64/*.txt
libtommath/*.dsp
libtommath/*.sln
libtommath/*.vcproj
tools/tcl.hpj.in
tools/tcl.wse.in
win/buildall.vc.bat
win/coffbase.txt
@@ -17,4 +16,3 @@ win/rules-ext.vc
win/targets.vc
win/tcl.dsp
win/tcl.dsw
win/tcl.hpj.in
+1 -3
View File
@@ -1,9 +1,7 @@
tools/tcl.hpj.in
tools/tcl.wse.in
win/buildall.vc.bat
win/coffbase.txt
win/makefile.vc
win/rules.vc
win/tcl.dsp
win/tcl.dsw
win/tcl.hpj.in
win/tcl.dsw
+51
View File
@@ -0,0 +1,51 @@
name: Linux
on: [push]
jobs:
gcc:
runs-on: ubuntu-20.04
strategy:
matrix:
cfgopt:
- ""
- "CFLAGS=-DTCL_UTF_MAX=4"
- "CFLAGS=-DTCL_NO_DEPRECATED=1"
- "--disable-shared"
- "--enable-symbols"
- "--enable-symbols=mem"
defaults:
run:
shell: bash
working-directory: unix
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Prepare
run: |
touch tclStubInit.c tclOOStubInit.c tclOOScript.h
working-directory: generic
- name: Configure ${{ matrix.cfgopt }}
run: |
mkdir "${HOME}/install dir"
./configure ${CFGOPT} "--prefix=$HOME/install dir" || (cat config.log && exit 1)
env:
CFGOPT: ${{ matrix.cfgopt }}
- name: Build
run: |
make all
- name: Build Test Harness
run: |
make tcltest
- name: Run Tests
run: |
make test
env:
ERROR_ON_FAILURES: 1
- name: Test-Drive Installation
run: |
make install
- name: Create Distribution Package
run: |
make dist
- name: Convert Documentation to HTML
run: |
make html-tcl
+63
View File
@@ -0,0 +1,63 @@
name: macOS
on: [push]
jobs:
xcode:
runs-on: macos-11.0
defaults:
run:
shell: bash
working-directory: macosx
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Prepare
run: |
touch tclStubInit.c tclOOStubInit.c tclOOScript.h
working-directory: generic
- name: Build
run: make all
env:
CFLAGS: -arch x86_64 -arch arm64e
- name: Run Tests
run: make test styles=develop
env:
ERROR_ON_FAILURES: 1
MAC_CI: 1
clang:
runs-on: macos-11.0
strategy:
matrix:
cfgopt:
- ""
- "--disable-shared"
- "--enable-symbols"
- "--enable-symbols=mem"
defaults:
run:
shell: bash
working-directory: unix
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Prepare
run: |
touch tclStubInit.c tclOOStubInit.c tclOOScript.h
mkdir "$HOME/install dir"
working-directory: generic
- name: Configure ${{ matrix.cfgopt }}
# Note that macOS is always a 64 bit platform
run: ./configure --enable-64bit --enable-dtrace --enable-framework ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1)
env:
CFLAGS: -arch x86_64 -arch arm64e
CFGOPT: ${{ matrix.cfgopt }}
- name: Build
run: |
make all tcltest
env:
CFLAGS: -arch x86_64 -arch arm64e
- name: Run Tests
run: |
make test
env:
ERROR_ON_FAILURES: 1
MAC_CI: 1
+138
View File
@@ -0,0 +1,138 @@
name: Build Binaries
on: [push]
jobs:
linux:
name: Linux
runs-on: ubuntu-16.04
defaults:
run:
shell: bash
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Prepare
run: |
touch generic/tclStubInit.c generic/tclOOStubInit.c
mkdir 1dist
echo "VER_PATH=$(cd tools; pwd)/addVerToFile.tcl" >> $GITHUB_ENV
working-directory: .
- name: Configure
run: ./configure --disable-symbols --disable-shared --enable-zipfs
working-directory: unix
- name: Build
run: |
make tclsh
make shell SCRIPT="$VER_PATH $GITHUB_ENV"
echo "TCL_ZIP=`pwd`/`echo libtcl*.zip`" >> $GITHUB_ENV
working-directory: unix
- name: Package
run: |
cp ../unix/tclsh tclsh${TCL_PATCHLEVEL}_unofficial
chmod +x tclsh${TCL_PATCHLEVEL}_unofficial
tar -cf tclsh${TCL_PATCHLEVEL}_unofficial.tar tclsh${TCL_PATCHLEVEL}_unofficial
working-directory: 1dist
- name: Upload
uses: actions/upload-artifact@v2
with:
name: Tclsh ${{ env.TCL_PATCHLEVEL }} Linux single-file build (unofficial)
path: 1dist/*.tar
macos:
name: macOS
runs-on: macos-11.0
defaults:
run:
shell: bash
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Checkout create-dmg
uses: actions/checkout@v2
with:
repository: create-dmg/create-dmg
ref: v1.0.8
path: create-dmg
- name: Prepare
run: |
mkdir 1dist
touch generic/tclStubInit.c generic/tclOOStubInit.c || true
wget https://github.com/culler/macher/releases/download/v1.3/macher
sudo cp macher /usr/local/bin
sudo chmod a+x /usr/local/bin/macher
echo "VER_PATH=$(cd tools; pwd)/addVerToFile.tcl" >> $GITHUB_ENV
echo "CREATE_DMG=$(cd create-dmg;pwd)/create-dmg" >> $GITHUB_ENV
echo "CFLAGS=-arch x86_64 -arch arm64e" >> $GITHUB_ENV
- name: Configure
run: ./configure --disable-symbols --disable-shared --enable-zipfs
working-directory: unix
- name: Build
run: |
make tclsh
make shell SCRIPT="$VER_PATH $GITHUB_ENV"
echo "TCL_BIN=`pwd`/tclsh" >> $GITHUB_ENV
echo "TCL_ZIP=`pwd`/`echo libtcl*.zip`" >> $GITHUB_ENV
working-directory: unix
- name: Package
run: |
mkdir contents
cp $TCL_BIN contents/tclsh${TCL_PATCHLEVEL}_unofficial
chmod +x contents/tclsh${TCL_PATCHLEVEL}_unofficial
cat > contents/README.txt <<EOF
This is a single-file executable developer preview of Tcl $TCL_PATCHLEVEL
It is not intended as an official release at all, so it is unsigned and unnotarized.
Use strictly at your own risk.
To run it, you need to copy the executable out and run:
xattr -d com.apple.quarantine tclsh${TCL_PATCHLEVEL}_unofficial
to mark the executable as runnable on your machine.
EOF
$CREATE_DMG \
--volname "Tcl $TCL_PATCHLEVEL (unofficial)" \
--window-pos 200 120 \
--window-size 800 400 \
"Tcl-$TCL_PATCHLEVEL-(unofficial).dmg" \
"contents/"
working-directory: 1dist
- name: Upload
uses: actions/upload-artifact@v2
with:
name: Tclsh ${{ env.TCL_PATCHLEVEL }} macOS single-file build (unofficial)
path: 1dist/*.dmg
win:
name: Windows
runs-on: windows-latest
defaults:
run:
shell: bash
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install MSYS2
uses: msys2/setup-msys2@v2
- name: Prepare
run: |
touch generic/tclStubInit.c generic/tclOOStubInit.c
echo "VER_PATH=$(cd tools; pwd)/addVerToFile.tcl" >> $GITHUB_ENV
mkdir 1dist
working-directory: .
- name: Configure
run: ./configure --disable-symbols --disable-shared --enable-zipfs
working-directory: win
- name: Build
run: |
make binaries libraries
echo "TCL_ZIP=`pwd`/`echo libtcl*.zip`" >> $GITHUB_ENV
working-directory: win
- name: Get Exact Version
run: |
./tclsh*.exe $VER_PATH $GITHUB_ENV
working-directory: win
- name: Set Executable Name
run: |
cp ../win/tclsh*.exe tclsh${TCL_PATCHLEVEL}_unofficial.exe
working-directory: 1dist
- name: Upload
uses: actions/upload-artifact@v2
with:
name: Tclsh ${{ env.TCL_PATCHLEVEL }} Windows single-file build (unofficial)
path: '1dist/*_unofficial.exe'
+87
View File
@@ -0,0 +1,87 @@
name: Windows
on: [push]
jobs:
msvc:
runs-on: windows-latest
defaults:
run:
shell: powershell
working-directory: win
strategy:
matrix:
cfgopt:
- ""
- "OPTS=utfmax"
- "CHECKS=nodep"
- "OPTS=static"
- "OPTS=symbols"
- "OPTS=memdbg"
# Using powershell means we need to explicitly stop on failure
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Init MSVC
uses: ilammy/msvc-dev-cmd@v1
- name: Build ${{ matrix.cfgopt }}
run: |
&nmake -f makefile.vc ${{ matrix.cfgopt }} all
if ($lastexitcode -ne 0) {
throw "nmake exit code: $lastexitcode"
}
- name: Build Test Harness ${{ matrix.cfgopt }}
run: |
&nmake -f makefile.vc ${{ matrix.cfgopt }} tcltest
if ($lastexitcode -ne 0) {
throw "nmake exit code: $lastexitcode"
}
- name: Run Tests ${{ matrix.cfgopt }}
run: |
&nmake -f makefile.vc ${{ matrix.cfgopt }} test
if ($lastexitcode -ne 0) {
throw "nmake exit code: $lastexitcode"
}
env:
ERROR_ON_FAILURES: 1
CI_BUILD_WITH_MSVC: 1
gcc:
runs-on: windows-latest
defaults:
run:
shell: bash
working-directory: win
strategy:
matrix:
cfgopt:
- ""
- "CFLAGS=-DTCL_UTF_MAX=4"
- "CFLAGS=-DTCL_NO_DEPRECATED=1"
- "--disable-shared"
- "--enable-symbols"
- "--enable-symbols=mem"
# Using powershell means we need to explicitly stop on failure
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install MSYS2 and Make
run: choco install msys2 make
- name: Prepare
run: |
touch tclStubInit.c tclOOStubInit.c tclOOScript.h
mkdir "${HOME}/install dir"
working-directory: generic
- name: Configure ${{ matrix.cfgopt }}
run: |
./configure ${CFGOPT} "--prefix=$HOME/install dir" || (cat config.log && exit 1)
env:
CFGOPT: --enable-64bit ${{ matrix.cfgopt }}
- name: Build
run: make all
- name: Build Test Harness
run: make tcltest
- name: Run Tests
run: make test
env:
ERROR_ON_FAILURES: 1
# If you add builds with Wine, be sure to define the environment variable
# CI_USING_WINE when running them so that broken tests know not to run.
+1 -1
View File
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>tcl9</name>
<name>tcl8</name>
<comment></comment>
<projects>
</projects>
+39 -51
View File
@@ -20,13 +20,13 @@ jobs:
compiler: gcc
env:
- BUILD_DIR=unix
- name: "Linux/GCC/Shared: UTF_MAX=3"
- name: "Linux/GCC/Shared: UTF_MAX=4"
os: linux
dist: focal
compiler: gcc
env:
- BUILD_DIR=unix
- CFGOPT="CFLAGS=-DTCL_UTF_MAX=3"
- CFGOPT=CFLAGS=-DTCL_UTF_MAX=4
- name: "Linux/GCC/Shared: NO_DEPRECATED"
os: linux
dist: focal
@@ -55,14 +55,6 @@ jobs:
env:
- BUILD_DIR=unix
- CFGOPT="--enable-symbols=mem"
# C++ build.
- name: "Linux/G++/Shared"
os: linux
dist: focal
compiler: g++
env:
- BUILD_DIR=unix
- CFGOPT="CC=g++ CFLAGS=-Dregister=dont+use+register"
# Newer/Older versions of GCC
- name: "Linux/GCC 10/Shared"
os: linux
@@ -91,6 +83,13 @@ jobs:
compiler: clang
env:
- BUILD_DIR=unix
- name: "Linux/Clang/Shared:NO_DEPRECATED"
os: linux
dist: xenial
compiler: clang
env:
- BUILD_DIR=unix
- CFGOPT="CFLAGS=-DTCL_NO_DEPRECATED=1"
- name: "Linux/Clang/Static"
os: linux
dist: focal
@@ -140,14 +139,6 @@ jobs:
homebrew:
packages:
- libtommath
- name: "macOS/Clang++/Xcode 12/Shared"
os: osx
osx_image: xcode12.2
env:
- BUILD_DIR=unix
- CFGOPT="CC=clang++ --enable-framework --enable-dtrace CFLAGS=-Dregister=dont+use+register CPPFLAGS=-D__private_extern__=extern"
script:
- make all tcltest
# Newer MacOS versions
- name: "macOS/Clang/Xcode 12/Universal Apps/Shared"
os: osx
@@ -217,7 +208,6 @@ jobs:
- BUILD_DIR=win
- VCDIR="/C/Program Files (x86)/Microsoft Visual Studio/2017/BuildTools/VC/Auxiliary/Build"
before_install: &vcpreinst
- rm -rf tests/safe-stock8*.test
- touch generic/tclStubInit.c generic/tclOOStubInit.c generic/tclOOScript.h
- PATH="$PATH:$VCDIR"
- cd ${BUILD_DIR}
@@ -225,6 +215,15 @@ jobs:
script:
- cmd.exe //C vcvarsall.bat x64 '&&' nmake '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x64 '&&' nmake '-f' makefile.vc test
- name: "Windows/MSVC/Shared: UTF_MAX=4"
os: windows
compiler: cl
env: *vcenv
before_install: *vcpreinst
install: []
script:
- cmd.exe //C vcvarsall.bat x64 '&&' nmake 'OPTS=utfmax' '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x64 '&&' nmake 'OPTS=utfmax' '-f' makefile.vc test
- name: "Windows/MSVC/Shared: NO_DEPRECATED"
os: windows
compiler: cl
@@ -232,8 +231,8 @@ jobs:
before_install: *vcpreinst
install: []
script:
- cmd.exe //C vcvarsall.bat x64 '&&' nmake 'OPTS=nodep' '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x64 '&&' nmake 'OPTS=nodep' '-f' makefile.vc test
- cmd.exe //C vcvarsall.bat x64 '&&' nmake 'CHECKS=nodep' '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x64 '&&' nmake 'CHECKS=nodep' '-f' makefile.vc test
- name: "Windows/MSVC/Static"
os: windows
compiler: cl
@@ -241,8 +240,8 @@ jobs:
before_install: *vcpreinst
install: []
script:
- cmd.exe //C vcvarsall.bat x64 '&&' nmake 'OPTS=static,msvcrt' '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x64 '&&' nmake 'OPTS=static,msvcrt' '-f' makefile.vc test
- cmd.exe //C vcvarsall.bat x64 '&&' nmake 'OPTS=static' '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x64 '&&' nmake 'OPTS=static' '-f' makefile.vc test
- name: "Windows/MSVC/Debug"
os: windows
compiler: cl
@@ -271,6 +270,15 @@ jobs:
script:
- cmd.exe //C vcvarsall.bat x86 '&&' nmake '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x86 '&&' nmake '-f' makefile.vc test
- name: "Windows/MSVC-x86/Shared: UTF_MAX=4"
os: windows
compiler: cl
env: *vcenv
before_install: *vcpreinst
install: []
script:
- cmd.exe //C vcvarsall.bat x86 '&&' nmake 'OPTS=utfmax' '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x86 '&&' nmake 'OPTS=utfmax' '-f' makefile.vc test
- name: "Windows/MSVC-x86/Shared: NO_DEPRECATED"
os: windows
compiler: cl
@@ -278,8 +286,8 @@ jobs:
before_install: *vcpreinst
install: []
script:
- cmd.exe //C vcvarsall.bat x86 '&&' nmake 'OPTS=nodep' '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x86 '&&' nmake 'OPTS=nodep' '-f' makefile.vc test
- cmd.exe //C vcvarsall.bat x86 '&&' nmake 'CHECKS=nodep' '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x86 '&&' nmake 'CHECKS=nodep' '-f' makefile.vc test
- name: "Windows/MSVC-x86/Static"
os: windows
compiler: cl
@@ -287,8 +295,8 @@ jobs:
before_install: *vcpreinst
install: []
script:
- cmd.exe //C vcvarsall.bat x86 '&&' nmake 'OPTS=static,msvcrt' '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x86 '&&' nmake 'OPTS=static,msvcrt' '-f' makefile.vc test
- cmd.exe //C vcvarsall.bat x86 '&&' nmake 'OPTS=static' '-f' makefile.vc all tcltest
- cmd.exe //C vcvarsall.bat x86 '&&' nmake 'OPTS=static' '-f' makefile.vc test
- name: "Windows/MSVC-x86/Debug"
os: windows
compiler: cl
@@ -315,16 +323,15 @@ jobs:
- BUILD_DIR=win
- CFGOPT="--enable-64bit"
before_install: &makepreinst
- rm -rf tests/safe-stock8*.test
- touch generic/tclStubInit.c generic/tclOOStubInit.c generic/tclOOScript.h
- choco install -y make zip
- cd ${BUILD_DIR}
- name: "Windows/GCC/Shared: UTF_MAX=3"
- name: "Windows/GCC/Shared: UTF_MAX=4"
os: windows
compiler: gcc
env:
- BUILD_DIR=win
- CFGOPT="--enable-64bit CFLAGS=-DTCL_UTF_MAX=3"
- CFGOPT="--enable-64bit CFLAGS=-DTCL_UTF_MAX=4"
before_install: *makepreinst
- name: "Windows/GCC/Shared: NO_DEPRECATED"
os: windows
@@ -333,15 +340,6 @@ jobs:
- BUILD_DIR=win
- CFGOPT="--enable-64bit CFLAGS=-DTCL_NO_DEPRECATED=1"
before_install: *makepreinst
- name: "Windows/G++/Shared"
os: windows
compiler: g++
env:
- BUILD_DIR=win
- CFGOPT="CC=g++ --enable-64bit"
before_install: *makepreinst
script:
- make all tcltest
- name: "Windows/GCC/Static"
os: windows
compiler: gcc
@@ -370,12 +368,12 @@ jobs:
env:
- BUILD_DIR=win
before_install: *makepreinst
- name: "Windows/GCC-x86/Shared: UTF_MAX=3"
- name: "Windows/GCC-x86/Shared: UTF_MAX=4"
os: windows
compiler: gcc
env:
- BUILD_DIR=win
- CFGOPT="CFLAGS=-DTCL_UTF_MAX=3"
- CFGOPT="CFLAGS=-DTCL_UTF_MAX=4"
before_install: *makepreinst
- name: "Windows/GCC-x86/Shared: NO_DEPRECATED"
os: windows
@@ -384,15 +382,6 @@ jobs:
- BUILD_DIR=win
- CFGOPT="CFLAGS=-DTCL_NO_DEPRECATED=1"
before_install: *makepreinst
- name: "Windows/G++-x86/Shared"
os: windows
compiler: g++
env:
- BUILD_DIR=win
- CFGOPT="CC=g++"
before_install: *makepreinst
script:
- make all tcltest
- name: "Windows/GCC-x86/Static"
os: windows
compiler: gcc
@@ -424,7 +413,6 @@ jobs:
script:
- make dist
before_install:
- rm -rf tests/safe-stock8*.test
- touch generic/tclStubInit.c generic/tclOOStubInit.c generic/tclOOScript.h
- cd ${BUILD_DIR}
install:
+1 -1
View File
@@ -3525,7 +3525,7 @@
* generic/tclVar.c (Tcl_UnsetObjCmd): Rewrote argument parser to avoid
a read off the end of the argument array that could occur when
executing something like [unset -nocomplain] was executed. Improved
the error message given when too few arguments are given (-nocomplain
the error message given when not enough arguments are given (-nocomplain
should obviously be *before* --, not after it) and also modified the
test suite to take account of that and the documentation to use the
same improvement. [Bug 405769]
+13 -11
View File
@@ -1,11 +1,13 @@
# README: Tcl
This is the **Tcl 9.0a2** source distribution.
This is the **Tcl 8.7a4** source distribution.
You can get any source release of Tcl from [our distribution
site](https://sourceforge.net/projects/tcl/files/Tcl/).
[![Build Status](https://travis-ci.org/tcltk/tcl.svg?branch=master)](https://travis-ci.org/tcltk/tcl)
[![Build Status](https://github.com/tcltk/tcl/workflows/Linux/badge.svg?branch=core-8-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Linux%22+branch%3Acore-8-branch)
[![Build Status](https://github.com/tcltk/tcl/workflows/Windows/badge.svg?branch=core-8-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Windows%22+branch%3Acore-8-branch)
[![Build Status](https://github.com/tcltk/tcl/workflows/macOS/badge.svg?branch=core-8-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22macOS%22+branch%3Acore-8-branch)
## Contents
1. [Introduction](#intro)
@@ -29,21 +31,21 @@ powerful command languages for applications.
Tcl is maintained, enhanced, and distributed freely by the Tcl community.
Source code development and tracking of bug reports and feature requests
takes place at [core.tcl-lang.org](https://core.tcl-lang.org/).
take place at [core.tcl-lang.org](https://core.tcl-lang.org/).
Tcl/Tk release and mailing list services are [hosted by
SourceForge](https://sourceforge.net/projects/tcl/)
with the Tcl Developer Xchange hosted at
[www.tcl-lang.org](https://www.tcl-lang.org).
Tcl is a freely available open source package. You can do virtually
Tcl is a freely available open-source package. You can do virtually
anything you like with it, such as modifying it, redistributing it,
and selling it either in whole or in part. See the file
`license.terms` for complete information.
## <a id="doc">2.</a> Documentation
Extensive documentation is available at our website.
Extensive documentation is available on our website.
The home page for this release, including new features, is
[here](https://www.tcl.tk/software/tcltk/9.0.html).
[here](https://www.tcl.tk/software/tcltk/8.7.html).
Detailed release notes can be found at the
[file distributions page](https://sourceforge.net/projects/tcl/files/Tcl/)
by clicking on the relevant version.
@@ -53,8 +55,8 @@ Xchange](https://www.tcl-lang.org/about/).
There have been many Tcl books on the market. Many are mentioned in
[the Wiki](https://wiki.tcl-lang.org/_/ref?N=25206).
The complete set of reference manual entries for Tcl 9.0 is [online,
here](https://www.tcl-lang.org/man/tcl9.0/).
The complete set of reference manual entries for Tcl 8.7 is [online,
here](https://www.tcl-lang.org/man/tcl8.7/).
### <a id="doc.unix">2a.</a> Unix Documentation
The `doc` subdirectory in this release contains a complete set of
@@ -88,16 +90,16 @@ about building Tcl from sources
[online](https://www.tcl-lang.org/doc/howto/compile.html).
## <a id="devtools">4.</a> Development tools
ActiveState produces a high quality set of commercial quality development
ActiveState produces a high-quality set of commercial quality development
tools that is available to accelerate your Tcl application development.
Tcl Dev Kit builds on the earlier TclPro toolset and provides a debugger,
static code checker, single-file wrapping utility, bytecode compiler and
static code checker, single-file wrapping utility, bytecode compiler, and
more. More information can be found at
http://www.ActiveState.com/Tcl
## <a id="complangtcl">5.</a> Tcl newsgroup
There is a USENET news group, "`comp.lang.tcl`", intended for the exchange of
There is a USENET newsgroup, "`comp.lang.tcl`", intended for the exchange of
information about Tcl, Tk, and related applications. The newsgroup is a
great place to ask general information questions. For bug reports, please
see the "Support and bug fixes" section below.
+131 -16
View File
@@ -8992,6 +8992,135 @@ in this changeset (new minor version) rather than bug fixes:
- Released 8.6.10, Nov 21, 2019 - details at http://core.tcl-lang.org/tcl/ -
2019-12-03 (bug)[3cd9be] Corner case in surrogate handling (nijtmans)
2019-12-09 (new) Add tcltest::(Setup|Eval|Cleanup|)Test (coulter,sebres)
=> tcltest 2.5.2
2019-12-12 (new) Add 3 libtommath functions to stub table (nijtmans)
2019-12-23 (bug)[ce3b9f] compilation errors with clang, windows msys2 (nijtmans)
2019-12-27 (bug)[1de6b0] [expr 1e2147483648] => 0.0 (kbk)
2020-01-04 (bug)[912886] tis-620 encoding fails to load (coulter)
2020-01-13 (bug)[0b9332] Win: support system encoding init to utf-8 (jedlička)
2020-01-17 (bug)[8cd2fe] [unload] corrupted list of loaded packages (berc)
2020-01-17 (bug)[5d989f] segfault in lsort for large list length (sebres)
2020-01-30 (bug) Reset WSAGetLastError()/errno in channel close (nijtmans)
2020-02-17 (bug) Win: avoid create of legacy error-vars on init phase (sebres)
2020-02-25 (bug) release refs when setting class's superclasses fails (dkf)
2020-02-26 (bug) C++ compiler compatibility for registry and dde (nijtmans)
=> registry 1.3.5
=> dde 1.4.3
2020-03-05 (new) Update to Unicode-13 (nijtmans)
2020-03-16 (bug)[8f89e2] Win: env var encoding, env-2.5 (sebres, nijtmans)
2020-03-27 (bug)[767e07] Tcl_Get(Range|UniChar) validate index inputs (nijtmans)
2020-03-28 (bug)[8edfce] [binary encode base64] & multi-byte wrapchars (dgp)
2020-03-28 (bug)[ffeb20] [binary decode base64] ignore invalid chars (dgp)
See RFC 2045
*** POTENTIAL INCOMPATIBILITY ***
2020-03-31 (bug)[b8e82d] some -maxlen values break uuencode round trip (dgp)
*** POTENTIAL INCOMPATIBILITY ***
2020-04-01 (bug)[f58371] Fileevent run in proper thread (bron,sebres)
2020-04-13 (bug)[afa4b2] TclNeedSpace bug; tests util-8.5 .. util-8.11 (dgp)
2020-04-13 (bug)[085913] Tcl_DStringAppendElement # quoting precision (dgp)
*** POTENTIAL INCOMPATIBILITY ***
2020-04-13 (bug)[a7f685] test util-5.52 (dgp)
2020-04-13 (bug)[c61818] Tcl_UtfPrev regression (dgp)
2020-04-15 (bug)[8af92d] zlib transform issue, bad inflate (sebres)
2020-04-16 (bug)[5e6346] Tcl_UtfPrev handling of overlong sequences (dgp)
2020-04-27 (bug)[45ca23] [string tolower] inconsistency (dgp)
2020-04-30 (bug)[da2352] init [info hostname] with DNS, not NetBIOS (nadkarni)
2020-05-11 (bug)[d402ff] Win32 potential crash when using main() (werner)
2020-05-13 (bug)[81242a] revised documentation for Tcl_UtfAtIndex() (nijtmans)
*** POTENTIAL INCOMPATIBILITY ***
2020-05-13 (bug)[ed2980] Tcl_UtfToUniChar reads > TCL_UTF_MAX bytes (nijtmans)
*** POTENTIAL INCOMPATIBILITY ***
2020-06-02 (bug) prevent segfault in parser (sebres)
2020-06-21 (bug)[f81bec] http POST a binary file (alakendu,nash)
=> http 2.9.2
2020-06-23 (bug)[41c985] auto_path nonsense in Safe Base (nash)
2020-06-24 (bug)[f70ce1] zlib multi-stream inflate acts only on first (sebres)
2020-07-09 (bug)[a1bd37] [clock scan] new ISO format (clock-34.(19-24)) (sebres)
*** POTENTIAL INCOMPATIBILITY ***
2020-07-10 (bug)[501974] [clock scan] +time zone (clock-34.(53-68)) (sebres)
*** POTENTIAL INCOMPATIBILITY ***
2020-07-15 (bug)[3c6e47] compiled [lappend] performance, avoid copy (sebres)
2020-07-16 (bug)[5bbd04] Fix index underflow (schwab)
2020-07-27 (bug)[cb0373] http::geturl -keepalive fixes (nash)
=> http 2.9.3
2020-08-10 (bug)[29e884] cmd resolution cycle (namespace-57.0) (coulter,sebres)
2020-08-12 (bug)[e87000] Tcl_BadChannelOption tolerate NULL (werner,nijtmans)
2020-08-31 (TIP #581) disfavor Master/Slave terminology (nijtmans)
=> opt 0.4.8
2020-09-11 (bug)[3bc0f4] UBSan complains about body.chars[] usage (nijtmans)
2020-09-17 (bug)[835c93] Support TIP 525 exit code for -singleproc 1 (nijtmans)
=> tcltest 2.5.3
2020-09-25 (new) force -eofchar \032 when evaluating library scripts (nijtmans)
*** POTENTIAL INCOMPATIBILITY ***
2020-09-29 (bug)[0063cb] http::geturl -headers must be dict (oehlmann,nijtmans)
2020-10-19 (bug)[cb4582] Update install-sh script (stu,nijtmans)
2020-10-22 (bug)[c97593] Usage of gnu_printf in latest mingw-w64 (nijtmans)
2020-10-26 (new)[48898a] improve error message consistency (stu)
*** POTENTIAL INCOMPATIBILITY ***
2020-11-06 (new) revised case of module names (nijtmans)
*** POTENTIAL INCOMPATIBILITY ***
2020-12-10 (bug)[ed5be7] Win: recognize "comx:" as serial port (oehlmann)
2020-12-11 (new) support for msys2, Big Sur (nijtmans)
=> platform 1.0.15
2020-12-23 tzdata updated to Olson's tzdata2020e (jima)
- Released 8.6.11, Dec 31, 2020 - details at http://core.tcl-lang.org/tcl/ -
Changes to 8.7a3 include all changes to the 8.6 line through 8.6.10,
plus the following, which focuses on the high-level feature changes
in this changeset (new minor version) rather than bug fixes:
@@ -9121,22 +9250,8 @@ in this changeset (new minor version) rather than bug fixes:
- Released 8.7a3, Nov 21, 2019 --- http://core.tcl-lang.org/tcl/ for details -
Changes to 9.0a1 include all changes to the 8.7 line through 8.7a3,
Changes to 8.7a5 include all changes to the 8.6 line through 8.6.11,
plus the following, which focuses on the high-level feature changes
in this changeset (new minor version) rather than bug fixes:
2017-11-03 [TIP 114] Leading zero integer no longer means octal
2017-11-03 [TIP 278] Revise variable name resolution, solve "Creative Writing"
2017-11-03 [TIPs 330,336] Encapsulate struct Tcl_Interp
2017-11-17 [TIP 422] Remove all Tcl_*VA() routines
2017-12-15 [TIP 488] Disable magic $::tcl_precision
2018-10-08 [TIP 494] Increased support for size_t value ranges
2019-05-31 [TIP 537] 64-bit indices in regexp matching
- Released 9.0a1, Nov 25, 2019 --- http://core.tcl-lang.org/tcl/ for details -
- Released 8.7a5, Jan 21, 2021 --- http://core.tcl-lang.org/tcl/ for details -
+2 -2
View File
@@ -28,7 +28,7 @@ opendir(
if ((fd = open(myname, 0, 0)) == -1) {
return NULL;
}
dirp = (DIR *) Tcl_Alloc(sizeof(DIR));
dirp = (DIR *) ckalloc(sizeof(DIR));
if (dirp == NULL) {
/* unreachable? */
close(fd);
@@ -106,5 +106,5 @@ closedir(
close(dirp->dd_fd);
dirp->dd_fd = -1;
dirp->dd_loc = 0;
Tcl_Free(dirp);
ckfree(dirp);
}
+2 -2
View File
@@ -100,7 +100,7 @@ waitpid(
} else {
prevPtr->nextPtr = waitPtr->nextPtr;
}
Tcl_Free(waitPtr);
ckfree(waitPtr);
return result;
}
@@ -156,7 +156,7 @@ waitpid(
goto waitAgain;
}
}
waitPtr = (WaitInfo *) Tcl_Alloc(sizeof(WaitInfo));
waitPtr = (WaitInfo *) ckalloc(sizeof(WaitInfo));
waitPtr->pid = result;
waitPtr->status = status;
waitPtr->nextPtr = deadList;
+11 -3
View File
@@ -9,7 +9,7 @@
.so man.macros
.BS
.SH NAME
Tcl_GetReturnOptions, Tcl_SetReturnOptions, Tcl_AddErrorInfo, Tcl_AppendObjToErrorInfo, Tcl_AddObjErrorInfo, Tcl_SetObjErrorCode, Tcl_SetErrorCode, Tcl_SetErrorLine, Tcl_GetErrorLine, Tcl_PosixError, Tcl_LogCommandInfo \- retrieve or record information about errors and other return options
Tcl_GetReturnOptions, Tcl_SetReturnOptions, Tcl_AddErrorInfo, Tcl_AppendObjToErrorInfo, Tcl_AddObjErrorInfo, Tcl_SetObjErrorCode, Tcl_SetErrorCode, Tcl_SetErrorCodeVA, Tcl_SetErrorLine, Tcl_GetErrorLine, Tcl_PosixError, Tcl_LogCommandInfo \- retrieve or record information about errors and other return options
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
@@ -30,6 +30,8 @@ int
.sp
\fBTcl_SetErrorCode\fR(\fIinterp, element, element, ... \fB(char *) NULL\fR)
.sp
\fBTcl_SetErrorCodeVA\fR(\fIinterp, argList\fR)
.sp
\fBTcl_GetErrorLine\fR(\fIinterp\fR)
.sp
\fBTcl_SetErrorLine\fR(\fIinterp, lineNum\fR)
@@ -58,10 +60,10 @@ unless \fIlength\fR is negative.
.AP Tcl_Obj *objPtr in
A message to be appended to the \fB\-errorinfo\fR return option
in the form of a Tcl_Obj value.
.AP size_t length in
.AP int length in
The number of bytes to copy from \fImessage\fR when
appending to the \fB\-errorinfo\fR return option.
If TCL_INDEX_NONE, all bytes up to the first null byte are used.
If negative, all bytes up to the first null byte are used.
.AP Tcl_Obj *errorObjPtr in
The \fB\-errorcode\fR return option will be set to this value.
.AP char *element in
@@ -242,6 +244,12 @@ The procedure \fBTcl_SetErrorCode\fR is also used to set the
\fB\-errorcode\fR return option. However, it takes one or more strings to
record instead of a value. Otherwise, it is similar to
\fBTcl_SetObjErrorCode\fR in behavior.
.PP
\fBTcl_SetErrorCodeVA\fR is the same as \fBTcl_SetErrorCode\fR except that
instead of taking a variable number of arguments it takes an argument list.
Interfaces using argument lists have been found to be nonportable in practice.
This function is deprecated and will be removed in Tcl 9.0.
.PP
The procedure \fBTcl_GetErrorLine\fR is used to read the integer value
of the \fB\-errorline\fR return option without the overhead of a full
+36 -8
View File
@@ -8,7 +8,7 @@
.so man.macros
.BS
.SH NAME
Tcl_Alloc, Tcl_Free, Tcl_Realloc, Tcl_AttemptAlloc, Tcl_AttemptRealloc \- allocate or free heap memory
Tcl_Alloc, Tcl_Free, Tcl_Realloc, Tcl_AttemptAlloc, Tcl_AttemptRealloc, Tcl_GetMemoryInfo, ckalloc, ckfree, ckrealloc, attemptckalloc, attemptckrealloc \- allocate or free heap memory
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
@@ -19,20 +19,40 @@ char *
void
\fBTcl_Free\fR(\fIptr\fR)
.sp
void *
char *
\fBTcl_Realloc\fR(\fIptr, size\fR)
.sp
void *
char *
\fBTcl_AttemptAlloc\fR(\fIsize\fR)
.sp
void *
char *
\fBTcl_AttemptRealloc\fR(\fIptr, size\fR)
.sp
void
\fBTcl_GetMemoryInfo\fR(\fIdsPtr\fR)
.sp
char *
\fBckalloc\fR(\fIsize\fR)
.sp
void
\fBckfree\fR(\fIptr\fR)
.sp
char *
\fBckrealloc\fR(\fIptr, size\fR)
.sp
char *
\fBattemptckalloc\fR(\fIsize\fR)
.sp
char *
\fBattemptckrealloc\fR(\fIptr, size\fR)
.SH ARGUMENTS
.AS char *size
.AP "unsigned int" size in
Size in bytes of the memory block to allocate.
.AP char *ptr in
Pointer to memory block to free or realloc.
.AP Tcl_DString *dsPtr in
Initialized DString pointer.
.BE
.SH DESCRIPTION
@@ -64,10 +84,18 @@ allocation fails, these functions will return NULL. Note that on some
platforms, but not all, attempting to allocate a zero-sized block of
memory will also cause these functions to return NULL.
.PP
When a module or Tcl itself is compiled with \fBTCL_MEM_DEBUG\fR defined,
the procedures \fBTcl_Alloc\fR, \fBTcl_Free\fR, \fBTcl_Realloc\fR,
\fBTcl_AttemptAlloc\fR, and \fBTcl_AttempRealloc\fR are implemented
as macros, redefined to be special debugging versions of these procedures.
The procedures \fBckalloc\fR, \fBckfree\fR, \fBckrealloc\fR,
\fBattemptckalloc\fR, and \fBattemptckrealloc\fR are implemented
as macros. Normally, they are synonyms for the corresponding
procedures documented on this page. When Tcl and all modules
calling Tcl are compiled with \fBTCL_MEM_DEBUG\fR defined, however,
these macros are redefined to be special debugging versions
of these procedures. To support Tcl's memory debugging within a
module, use the macros rather than direct calls to \fBTcl_Alloc\fR, etc.
\fBTcl_GetMemoryInfo\fR appends a list-of-lists of memory stats to the
provided DString. This function cannot be used in stub-enabled extensions,
and it is only available if Tcl is compiled with the threaded memory allocator.
.SH KEYWORDS
alloc, allocation, free, malloc, memory, realloc, TCL_MEM_DEBUG
+2 -1
View File
@@ -30,7 +30,8 @@ or \fBTCL_RETURN\fR, then Tcl normally converts this into a \fBTCL_ERROR\fR
return with an appropriate message. The particular script
evaluation procedures of Tcl that act in the manner are
\fBTcl_EvalObjEx\fR, \fBTcl_EvalObjv\fR, \fBTcl_Eval\fR, \fBTcl_EvalEx\fR,
\fBTcl_GlobalEval\fR, \fBTcl_GlobalEvalObj\fR and \fBTcl_VarEval\fR.
\fBTcl_GlobalEval\fR, \fBTcl_GlobalEvalObj\fR, \fBTcl_VarEval\fR and
\fBTcl_VarEvalVA\fR.
.PP
However, if \fBTcl_AllowExceptions\fR is invoked immediately before
calling one of those a procedures, then arbitrary completion
+3 -3
View File
@@ -13,7 +13,7 @@ Tcl_GetAssocData, Tcl_SetAssocData, Tcl_DeleteAssocData \- manage associations o
.nf
\fB#include <tcl.h>\fR
.sp
void *
ClientData
\fBTcl_GetAssocData\fR(\fIinterp, key, delProcPtr\fR)
.sp
\fBTcl_SetAssocData\fR(\fIinterp, key, delProc, clientData\fR)
@@ -31,7 +31,7 @@ Procedure to call when \fIinterp\fR is deleted.
.AP Tcl_InterpDeleteProc **delProcPtr in
Pointer to location in which to store address of current deletion procedure
for association. Ignored if NULL.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value associated with the given key in this
interpreter. This data is owned by the caller.
.BE
@@ -64,7 +64,7 @@ the type \fBTcl_InterpDeleteProc\fR:
.PP
.CS
typedef void \fBTcl_InterpDeleteProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR);
.CE
.PP
+2 -2
View File
@@ -30,7 +30,7 @@ int
.AS Tcl_AsyncHandler clientData
.AP Tcl_AsyncProc *proc in
Procedure to invoke to handle an asynchronous event.
.AP void *clientData in
.AP ClientData clientData in
One-word value to pass to \fIproc\fR.
.AP Tcl_AsyncHandler async in
Token for asynchronous event handler.
@@ -84,7 +84,7 @@ type \fBTcl_AsyncProc\fR:
.PP
.CS
typedef int \fBTcl_AsyncProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR,
int \fIcode\fR);
.CE
+47
View File
@@ -0,0 +1,47 @@
'\"
'\" Copyright (c) 1989-1993 The Regents of the University of California.
'\" Copyright (c) 1994-1996 Sun Microsystems, Inc.
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
.TH Tcl_Backslash 3 "8.1" Tcl "Tcl Library Procedures"
.so man.macros
.BS
.SH NAME
Tcl_Backslash \- parse a backslash sequence
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
.sp
char
\fBTcl_Backslash\fR(\fIsrc, countPtr\fR)
.SH ARGUMENTS
.AS char *countPtr out
.AP char *src in
Pointer to a string starting with a backslash.
.AP int *countPtr out
If \fIcountPtr\fR is not NULL, \fI*countPtr\fR gets filled
in with number of characters in the backslash sequence, including
the backslash character.
.BE
.SH DESCRIPTION
.PP
The use of \fBTcl_Backslash\fR is deprecated in favor of
\fBTcl_UtfBackslash\fR.
.PP
This is a utility procedure provided for backwards compatibility with
non-internationalized Tcl extensions. It parses a backslash sequence and
returns the low byte of the Unicode character corresponding to the sequence.
\fBTcl_Backslash\fR modifies \fI*countPtr\fR to contain the number of
characters in the backslash sequence.
.PP
See the Tcl manual entry for information on the valid backslash sequences.
All of the sequences described in the Tcl manual entry are supported by
\fBTcl_Backslash\fR.
.SH "SEE ALSO"
Tcl(n), Tcl_UtfBackslash(3)
.SH KEYWORDS
backslash, parse
+5 -4
View File
@@ -29,16 +29,17 @@ unsigned char *
.AP "const unsigned char" *bytes in
The array of bytes used to initialize or set a byte-array value. May be NULL
even if \fIlength\fR is non-zero.
.AP size_t length in
The length of the array of bytes.
.AP int length in
The length of the array of bytes. It must be >= 0.
.AP Tcl_Obj *objPtr in/out
For \fBTcl_SetByteArrayObj\fR, this points to the value to be converted to
byte-array type. For \fBTcl_GetByteArrayFromObj\fR and
\fBTcl_SetByteArrayLength\fR, this points to the value from which to get
the byte-array value; if \fIobjPtr\fR does not already point to a byte-array
value, it will be converted to one.
.AP int *lengthPtr out
If non-NULL, filled with the length of the array of bytes in the value.
.AP size_t | int *lengthPtr out
Filled with the length of the array of bytes in the value.
May be (int *)NULL when not used.
.BE
.SH DESCRIPTION
+2 -2
View File
@@ -23,7 +23,7 @@ Tcl_CallWhenDeleted, Tcl_DontCallWhenDeleted \- Arrange for callback when interp
Interpreter with which to associated callback.
.AP Tcl_InterpDeleteProc *proc in
Procedure to call when \fIinterp\fR is deleted.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR.
.BE
.SH DESCRIPTION
@@ -38,7 +38,7 @@ type \fBTcl_InterpDeleteProc\fR:
.PP
.CS
typedef void \fBTcl_InterpDeleteProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR);
.CE
.PP
+1 -1
View File
@@ -30,7 +30,7 @@ ORed combination of flag bits that specify additional options.
For \fBTcl_CancelEval\fR, only \fBTCL_CANCEL_UNWIND\fR is currently
supported. For \fBTcl_Canceled\fR, only \fBTCL_LEAVE_ERR_MSG\fR and
\fBTCL_CANCEL_UNWIND\fR are currently supported.
.AP void *clientData in
.AP ClientData clientData in
Currently reserved for future use.
It should be set to NULL.
.BE
+6 -3
View File
@@ -32,7 +32,7 @@ Tcl_Channel
Interpreter for error reporting.
.AP "const Tcl_ChannelType" *typePtr in
The new channel I/O procedures to use for \fIchannel\fR.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to channel I/O procedures.
.AP int mask in
Conditions under which \fIchannel\fR will be used: OR-ed combination of
@@ -49,8 +49,11 @@ I/O channels. Examples include compression and encryption modules. These
functions transparently stack and unstack a new channel on top of an
existing one. Any number of channels can be stacked together.
.PP
The \fBTcl_ChannelType\fR version currently supported is
\fBTCL_CHANNEL_VERSION_5\fR. See \fBTcl_CreateChannel\fR for details.
The implementation of the Tcl channel code was rewritten in 8.3.2 to
correct some problems with the previous implementation with regard to
stacked channels. Anyone using stacked channels or creating stacked
channel drivers should update to the new \fBTCL_CHANNEL_VERSION_2\fR
\fBTcl_ChannelType\fR structure. See \fBTcl_CreateChannel\fR for details.
.PP
\fBTcl_StackChannel\fR stacks a new \fIchannel\fR on an existing channel
with the same name that was registered for \fIchannel\fR by
+7 -7
View File
@@ -41,12 +41,12 @@ Tcl_Object
int
\fBTcl_ObjectDeleted\fR(\fIobject\fR)
.sp
void *
ClientData
\fBTcl_ObjectGetMetadata\fR(\fIobject, metaTypePtr\fR)
.sp
\fBTcl_ObjectSetMetadata\fR(\fIobject, metaTypePtr, metadata\fR)
.sp
void *
ClientData
\fBTcl_ClassGetMetadata\fR(\fIclass, metaTypePtr\fR)
.sp
\fBTcl_ClassSetMetadata\fR(\fIclass, metaTypePtr, metadata\fR)
@@ -56,7 +56,7 @@ Tcl_ObjectMapMethodNameProc
.sp
\fBTcl_ObjectSetMethodNameMapper\fR(\fIobject\fR, \fImethodNameMapper\fR)
.SH ARGUMENTS
.AS void *metadata in/out
.AS ClientData metadata in/out
.AP Tcl_Interp *interp in/out
Interpreter providing the context for looking up or creating an object, and
into whose result error messages will be written on failure.
@@ -85,7 +85,7 @@ error messages even when complicated calling patterns are used (e.g., via the
.AP Tcl_ObjectMetadataType *metaTypePtr in
The type of \fImetadata\fR being set with \fBTcl_ClassSetMetadata\fR or
retrieved with \fBTcl_ClassGetMetadata\fR.
.AP void *metadata in
.AP ClientData metadata in
An item of metadata to attach to the class, or NULL to remove the metadata
associated with a particular \fImetaTypePtr\fR.
.AP "Tcl_ObjectMapMethodNameProc" "methodNameMapper" in
@@ -185,7 +185,7 @@ a class or object.
.PP
.CS
typedef void \fBTcl_ObjectMetadataDeleteProc\fR(
void *\fImetadata\fR);
ClientData \fImetadata\fR);
.CE
.PP
The \fImetadata\fR argument gives the address of the metadata to be
@@ -198,8 +198,8 @@ associated with a class or object.
.CS
typedef int \fBTcl_CloneProc\fR(
Tcl_Interp *\fIinterp\fR,
void *\fIsrcMetadata\fR,
void **\fIdstMetadataPtr\fR);
ClientData \fIsrcMetadata\fR,
ClientData *\fIdstMetadataPtr\fR);
.CE
.PP
The \fIinterp\fR argument gives a place to write an error message when the
+16 -1
View File
@@ -8,7 +8,7 @@
.so man.macros
.BS
.SH NAME
Tcl_IsSafe, Tcl_MakeSafe, Tcl_CreateChild, Tcl_GetChild, Tcl_GetParent, Tcl_GetInterpPath, Tcl_CreateAlias, Tcl_CreateAliasObj, Tcl_GetAlias, Tcl_GetAliasObj, Tcl_ExposeCommand, Tcl_HideCommand \- manage multiple Tcl interpreters, aliases and hidden commands
Tcl_IsSafe, Tcl_MakeSafe, Tcl_CreateChild, Tcl_CreateSlave, Tcl_GetChild, Tcl_GetSlave, Tcl_GetParent, Tcl_GetMaster, Tcl_GetInterpPath, Tcl_CreateAlias, Tcl_CreateAliasObj, Tcl_GetAlias, Tcl_GetAliasObj, Tcl_ExposeCommand, Tcl_HideCommand \- manage multiple Tcl interpreters, aliases and hidden commands
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
@@ -23,9 +23,18 @@ Tcl_Interp *
\fBTcl_CreateChild\fR(\fIinterp, name, isSafe\fR)
.sp
Tcl_Interp *
\fBTcl_CreateSlave\fR(\fIinterp, name, isSafe\fR)
.sp
Tcl_Interp *
\fBTcl_GetSlave\fR(\fIinterp, name\fR)
.sp
Tcl_Interp *
\fBTcl_GetChild\fR(\fIinterp, name\fR)
.sp
Tcl_Interp *
\fBTcl_GetMaster\fR(\fIinterp\fR)
.sp
Tcl_Interp *
\fBTcl_GetParent\fR(\fIinterp\fR)
.sp
int
@@ -133,6 +142,8 @@ child in which Tcl code has access only to set of Tcl commands defined as
see the manual entry for the Tcl \fBinterp\fR command for details.
If the creation of the new child interpreter failed, \fBNULL\fR is returned.
.PP
\fBTcl_CreateSlave\fR is a synonym for \fBTcl_CreateChild\fR.
.PP
\fBTcl_IsSafe\fR returns \fB1\fR if \fIinterp\fR is
.QW safe
(was created with the \fBTCL_SAFE_INTERPRETER\fR flag specified),
@@ -154,10 +165,14 @@ may be a better choice, since it creates interpreters in a known-safe state.
\fIinterp\fR. The child interpreter is identified by \fIname\fR.
If no such child interpreter exists, \fBNULL\fR is returned.
.PP
\fBTcl_GetSlave\fR is a synonym for \fBTcl_GetChild\fR.
.PP
\fBTcl_GetParent\fR returns a pointer to the parent interpreter of
\fIinterp\fR. If \fIinterp\fR has no parent (it is a
top-level interpreter) then \fBNULL\fR is returned.
.PP
\fBTcl_GetMaster\fR is a synonym for \fBTcl_GetParent\fR.
.PP
\fBTcl_GetInterpPath\fR stores in the result of \fIinterp\fR
the relative path between \fIinterp\fR and \fIchildInterp\fR;
\fIchildInterp\fR must be a child of \fIinterp\fR. If the computation
+169 -54
View File
@@ -9,7 +9,7 @@
.BS
'\" Note: do not modify the .SH NAME line immediately below!
.SH NAME
Tcl_CreateChannel, Tcl_GetChannelInstanceData, Tcl_GetChannelType, Tcl_GetChannelName, Tcl_GetChannelHandle, Tcl_GetChannelMode, Tcl_GetChannelBufferSize, Tcl_SetChannelBufferSize, Tcl_NotifyChannel, Tcl_BadChannelOption, Tcl_ChannelName, Tcl_ChannelVersion, Tcl_ChannelBlockModeProc, Tcl_ChannelClose2Proc, Tcl_ChannelInputProc, Tcl_ChannelOutputProc, Tcl_ChannelWideSeekProc, Tcl_ChannelTruncateProc, Tcl_ChannelSetOptionProc, Tcl_ChannelGetOptionProc, Tcl_ChannelWatchProc, Tcl_ChannelGetHandleProc, Tcl_ChannelFlushProc, Tcl_ChannelHandlerProc, Tcl_ChannelThreadActionProc, Tcl_IsChannelShared, Tcl_IsChannelRegistered, Tcl_CutChannel, Tcl_SpliceChannel, Tcl_IsChannelExisting, Tcl_ClearChannelHandlers, Tcl_GetChannelThread, Tcl_ChannelBuffered \- procedures for creating and manipulating channels
Tcl_CreateChannel, Tcl_GetChannelInstanceData, Tcl_GetChannelType, Tcl_GetChannelName, Tcl_GetChannelHandle, Tcl_GetChannelMode, Tcl_GetChannelBufferSize, Tcl_SetChannelBufferSize, Tcl_NotifyChannel, Tcl_BadChannelOption, Tcl_ChannelName, Tcl_ChannelVersion, Tcl_ChannelBlockModeProc, Tcl_ChannelCloseProc, Tcl_ChannelClose2Proc, Tcl_ChannelInputProc, Tcl_ChannelOutputProc, Tcl_ChannelSeekProc, Tcl_ChannelWideSeekProc, Tcl_ChannelTruncateProc, Tcl_ChannelSetOptionProc, Tcl_ChannelGetOptionProc, Tcl_ChannelWatchProc, Tcl_ChannelGetHandleProc, Tcl_ChannelFlushProc, Tcl_ChannelHandlerProc, Tcl_ChannelThreadActionProc, Tcl_IsChannelShared, Tcl_IsChannelRegistered, Tcl_CutChannel, Tcl_SpliceChannel, Tcl_IsChannelExisting, Tcl_ClearChannelHandlers, Tcl_GetChannelThread, Tcl_ChannelBuffered \- procedures for creating and manipulating channels
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
@@ -17,7 +17,7 @@ Tcl_CreateChannel, Tcl_GetChannelInstanceData, Tcl_GetChannelType, Tcl_GetChanne
Tcl_Channel
\fBTcl_CreateChannel\fR(\fItypePtr, channelName, instanceData, mask\fR)
.sp
void *
ClientData
\fBTcl_GetChannelInstanceData\fR(\fIchannel\fR)
.sp
const Tcl_ChannelType *
@@ -75,6 +75,9 @@ Tcl_ChannelTypeVersion
Tcl_DriverBlockModeProc *
\fBTcl_ChannelBlockModeProc\fR(\fItypePtr\fR)
.sp
Tcl_DriverCloseProc *
\fBTcl_ChannelCloseProc\fR(\fItypePtr\fR)
.sp
Tcl_DriverClose2Proc *
\fBTcl_ChannelClose2Proc\fR(\fItypePtr\fR)
.sp
@@ -84,6 +87,9 @@ Tcl_DriverInputProc *
Tcl_DriverOutputProc *
\fBTcl_ChannelOutputProc\fR(\fItypePtr\fR)
.sp
Tcl_DriverSeekProc *
\fBTcl_ChannelSeekProc\fR(\fItypePtr\fR)
.sp
Tcl_DriverWideSeekProc *
\fBTcl_ChannelWideSeekProc\fR(\fItypePtr\fR)
.sp
@@ -122,7 +128,7 @@ by any other channel. Can be NULL, in which case the channel is
created without a name. If the created channel is assigned to one
of the standard channels (\fBstdin\fR, \fBstdout\fR or \fBstderr\fR),
the assigned channel name will be the name of the standard channel.
.AP void *instanceData in
.AP ClientData instanceData in
Arbitrary one-word value to be associated with this channel. This
value is passed to procedures in \fItypePtr\fR when they are invoked.
.AP int mask in
@@ -133,7 +139,7 @@ The channel to operate on.
.AP int direction in
\fBTCL_READABLE\fR means the input handle is wanted; \fBTCL_WRITABLE\fR
means the output handle is wanted.
.AP void **handlePtr out
.AP ClientData *handlePtr out
Points to the location where the desired OS-specific handle should be
stored.
.AP int size in
@@ -253,7 +259,8 @@ outside this range, \fBTcl_SetChannelBufferSize\fR sets the buffer size to
the generic layer that the events specified by \fImask\fR have
occurred on the channel. Channel drivers are responsible for invoking
this function whenever the channel handlers need to be called for the
channel. See \fBWATCHPROC\fR below for more details.
channel (or other pending tasks like a write flush should be performed).
See \fBWATCHPROC\fR below for more details.
.PP
\fBTcl_BadChannelOption\fR is called from driver specific
\fIsetOptionProc\fR or \fIgetOptionProc\fR to generate a complete
@@ -280,13 +287,16 @@ name is registered in the (thread)-global list of all channels (result
(thread)global list of all channels (of the current thread).
Application to a channel still registered in some interpreter
is not allowed.
Also notifies the driver if
Also notifies the driver if the \fBTcl_ChannelType\fR version is
\fBTCL_CHANNEL_VERSION_4\fR (or higher), and
\fBTcl_DriverThreadActionProc\fR is defined for it.
.PP
\fBTcl_SpliceChannel\fR adds the specified \fIchannel\fR to the
(thread)global list of all channels (of the current thread).
Application to a channel registered in some interpreter is not allowed.
Also notifies the driver if \fBTcl_DriverThreadActionProc\fR is defined for it.
Also notifies the driver if the \fBTcl_ChannelType\fR version is
\fBTCL_CHANNEL_VERSION_4\fR (or higher), and
\fBTcl_DriverThreadActionProc\fR is defined for it.
.PP
\fBTcl_ClearChannelHandlers\fR removes all channel handlers and event
scripts associated with the specified \fIchannel\fR, thus shutting
@@ -306,10 +316,10 @@ The \fBTcl_ChannelType\fR structure contains the following fields:
typedef struct Tcl_ChannelType {
const char *\fItypeName\fR;
Tcl_ChannelTypeVersion \fIversion\fR;
void *\fIcloseProc\fR; /* Not used any more*/
Tcl_DriverCloseProc *\fIcloseProc\fR;
Tcl_DriverInputProc *\fIinputProc\fR;
Tcl_DriverOutputProc *\fIoutputProc\fR;
void *\fIseekProc\fR; /* Not used any more */
Tcl_DriverSeekProc *\fIseekProc\fR;
Tcl_DriverSetOptionProc *\fIsetOptionProc\fR;
Tcl_DriverGetOptionProc *\fIgetOptionProc\fR;
Tcl_DriverWatchProc *\fIwatchProc\fR;
@@ -338,8 +348,9 @@ The user should only use the above structure for \fBTcl_ChannelType\fR
instantiation. When referencing fields in a \fBTcl_ChannelType\fR
structure, the following functions should be used to obtain the values:
\fBTcl_ChannelName\fR, \fBTcl_ChannelVersion\fR,
\fBTcl_ChannelBlockModeProc\fR, \fBTcl_ChannelClose2Proc\fR,
\fBTcl_ChannelInputProc\fR, \fBTcl_ChannelOutputProc\fR,
\fBTcl_ChannelBlockModeProc\fR, \fBTcl_ChannelCloseProc\fR,
\fBTcl_ChannelClose2Proc\fR, \fBTcl_ChannelInputProc\fR,
\fBTcl_ChannelOutputProc\fR, \fBTcl_ChannelSeekProc\fR,
\fBTcl_ChannelWideSeekProc\fR, \fBTcl_ChannelThreadActionProc\fR,
\fBTcl_ChannelTruncateProc\fR,
\fBTcl_ChannelSetOptionProc\fR, \fBTcl_ChannelGetOptionProc\fR,
@@ -362,9 +373,25 @@ a pointer to the string.
.PP
The \fIversion\fR field should be set to the version of the structure
that you require. \fBTCL_CHANNEL_VERSION_5\fR is the minimum supported.
that you require. \fBTCL_CHANNEL_VERSION_2\fR is the minimum recommended.
\fBTCL_CHANNEL_VERSION_3\fR must be set to specify the \fIwideSeekProc\fR member.
\fBTCL_CHANNEL_VERSION_4\fR must be set to specify the \fIthreadActionProc\fR member
(includes \fIwideSeekProc\fR).
\fBTCL_CHANNEL_VERSION_5\fR must be set to specify the
\fItruncateProc\fR members (includes
\fIwideSeekProc\fR and \fIthreadActionProc\fR).
If it is not set to any of these, then this
\fBTcl_ChannelType\fR is assumed to have the original structure. See
\fBOLD CHANNEL TYPES\fR for more details. While Tcl will recognize
and function with either structures, stacked channels must be of at
least \fBTCL_CHANNEL_VERSION_2\fR to function correctly.
.PP
This value can be retrieved with \fBTcl_ChannelVersion\fR.
This value can be retrieved with \fBTcl_ChannelVersion\fR, which returns
one of
\fBTCL_CHANNEL_VERSION_5\fR,
\fBTCL_CHANNEL_VERSION_4\fR,
\fBTCL_CHANNEL_VERSION_3\fR,
\fBTCL_CHANNEL_VERSION_2\fR or \fBTCL_CHANNEL_VERSION_1\fR.
.SS BLOCKMODEPROC
.PP
The \fIblockModeProc\fR field contains the address of a function called by
@@ -373,7 +400,7 @@ the generic layer to set blocking and nonblocking mode on the device.
.PP
.CS
typedef int \fBTcl_DriverBlockModeProc\fR(
void *\fIinstanceData\fR,
ClientData \fIinstanceData\fR,
int \fImode\fR);
.CE
.PP
@@ -400,23 +427,22 @@ blocking mode is acceptable to it, and should this also document for
the user so that the blocking mode of the channel is not changed to an
unacceptable value. Any confusion here may lead the interpreter into a
(spurious and difficult to find) deadlock.
.SS "CLOSE2PROC"
.SS "CLOSEPROC AND CLOSE2PROC"
.PP
The \fIclose2Proc\fR field contains the address of a function called by the
The \fIcloseProc\fR field contains the address of a function called by the
generic layer to clean up driver-related information when the channel is
closed. \fIClose2Proc\fR must match the following prototype:
closed. \fICloseProc\fR must match the following prototype:
.PP
.CS
typedef int \fBTcl_DriverClose2Proc\fR(
void *\fIinstanceData\fR,
Tcl_Interp *\fIinterp\fR,
int \fIflags\fR);
typedef int \fBTcl_DriverCloseProc\fR(
ClientData \fIinstanceData\fR,
Tcl_Interp *\fIinterp\fR);
.CE
.PP
If \fIflags\fR is 0, the \fIinstanceData\fR argument is the same as the value
provided to \fBTcl_CreateChannel\fR when the channel was created. The function
should release any storage maintained by the channel driver for this channel,
and close the input and output devices encapsulated by this channel. All queued
The \fIinstanceData\fR argument is the same as the value provided to
\fBTcl_CreateChannel\fR when the channel was created. The function should
release any storage maintained by the channel driver for this channel, and
close the input and output devices encapsulated by this channel. All queued
output will have been flushed to the device before this function is called,
and no further driver operations will be invoked on this instance after
calling the \fIcloseProc\fR. If the close operation is successful, the
@@ -425,20 +451,35 @@ error code. In addition, if an error occurs and \fIinterp\fR is not NULL,
the procedure should store an error message in the interpreter's result.
.PP
Alternatively, channels that support closing the read and write sides
independently may accept other flag values than 0.
Then \fIclose2Proc\fR will be called with \fIflags\fR set to an OR'ed
independently may set \fIcloseProc\fR to \fBTCL_CLOSE2PROC\fR and set
\fIclose2Proc\fR to the address of a function that matches the
following prototype:
.PP
.CS
typedef int \fBTcl_DriverClose2Proc\fR(
ClientData \fIinstanceData\fR,
Tcl_Interp *\fIinterp\fR,
int \fIflags\fR);
.CE
.PP
The \fIclose2Proc\fR will be called with \fIflags\fR set to an OR'ed
combination of \fBTCL_CLOSE_READ\fR or \fBTCL_CLOSE_WRITE\fR to
indicate that the driver should close the read and/or write side of
the channel. The channel driver may be invoked to perform
additional operations on the channel after \fIclose2Proc\fR is
called to close one or both sides of the channel. In all cases, the
\fIclose2Proc\fR function should return zero if the close operation was
successful; otherwise it should return a nonzero POSIX error code.
In addition, if an error occurs and \fIinterp\fR is not NULL, the procedure
should store an error message in the interpreter's result.
called to close one or both sides of the channel. If \fIflags\fR is
\fB0\fR (zero), the driver should close the channel in the manner
described above for \fIcloseProc\fR. No further operations will be
invoked on this instance after \fIclose2Proc\fR is called with all
flags cleared. In all cases, the \fIclose2Proc\fR function should
return zero if the close operation was successful; otherwise it should
return a nonzero POSIX error code. In addition, if an error occurs and
\fIinterp\fR is not NULL, the procedure should store an error message
in the interpreter's result.
.PP
The \fIclose2Proc\fR value can be retrieved with \fBTcl_ChannelClose2Proc\fR,
which returns a pointer to the function.
The \fIcloseProc\fR and \fIclose2Proc\fR values can be retrieved with
\fBTcl_ChannelCloseProc\fR or \fBTcl_ChannelClose2Proc\fR, which
return a pointer to the respective function.
.SS INPUTPROC
.PP
The \fIinputProc\fR field contains the address of a function called by the
@@ -447,7 +488,7 @@ internal buffer. \fIInputProc\fR must match the following prototype:
.PP
.CS
typedef int \fBTcl_DriverInputProc\fR(
void *\fIinstanceData\fR,
ClientData \fIinstanceData\fR,
char *\fIbuf\fR,
int \fIbufSize\fR,
int *\fIerrorCodePtr\fR);
@@ -491,7 +532,7 @@ generic layer to transfer data from an internal buffer to the output device.
.PP
.CS
typedef int \fBTcl_DriverOutputProc\fR(
void *\fIinstanceData\fR,
ClientData \fIinstanceData\fR,
const char *\fIbuf\fR,
int \fItoWrite\fR,
int *\fIerrorCodePtr\fR);
@@ -521,17 +562,17 @@ without writing any data.
.PP
This value can be retrieved with \fBTcl_ChannelOutputProc\fR, which returns
a pointer to the function.
.SS "WIDESEEKPROC"
.SS "SEEKPROC AND WIDESEEKPROC"
.PP
The \fIwideSeekProc\fR field contains the address of a function called by the
The \fIseekProc\fR field contains the address of a function called by the
generic layer to move the access point at which subsequent input or output
operations will be applied. \fIWideSeekProc\fR must match the following
operations will be applied. \fISeekProc\fR must match the following
prototype:
.PP
.CS
typedef Tcl_WideInt \fBTcl_DriverWideSeekProc\fR(
void *\fIinstanceData\fR,
Tcl_WideInt \fIoffset\fR,
typedef int \fBTcl_DriverSeekProc\fR(
ClientData \fIinstanceData\fR,
long \fIoffset\fR,
int \fIseekMode\fR,
int *\fIerrorCodePtr\fR);
.CE
@@ -550,8 +591,30 @@ does not implement seeking.
The return value is the new access point or -1 in case of error. If an
error occurred, the function should not move the access point.
.PP
The \fIwideSseekProc\fR value can be retrieved with
\fBTcl_ChannelWideSeekProc\fR, which returns a pointer to the function.
If there is a non-NULL \fIseekProc\fR field, the \fIwideSeekProc\fR
field may contain the address of an alternative function to use which
handles wide (i.e. larger than 32-bit) offsets, so allowing seeks
within files larger than 2GB. The \fIwideSeekProc\fR will be called
in preference to the \fIseekProc\fR, but both must be defined if the
\fIwideSeekProc\fR is defined. \fIWideSeekProc\fR must match the
following prototype:
.PP
.CS
typedef long long \fBTcl_DriverWideSeekProc\fR(
ClientData \fIinstanceData\fR,
long long \fIoffset\fR,
int \fIseekMode\fR,
int *\fIerrorCodePtr\fR);
.CE
.PP
The arguments and return values mean the same thing as with
\fIseekProc\fR above, except that the type of offsets and the return
type are different.
.PP
The \fIseekProc\fR value can be retrieved with
\fBTcl_ChannelSeekProc\fR, which returns a pointer to the function,
and similarly the \fIwideSeekProc\fR can be retrieved with
\fBTcl_ChannelWideSeekProc\fR.
.SS SETOPTIONPROC
.PP
The \fIsetOptionProc\fR field contains the address of a function called by
@@ -560,7 +623,7 @@ the generic layer to set a channel type specific option on a channel.
.PP
.CS
typedef int \fBTcl_DriverSetOptionProc\fR(
void *\fIinstanceData\fR,
ClientData \fIinstanceData\fR,
Tcl_Interp *\fIinterp\fR,
const char *\fIoptionName\fR,
const char *\fInewValue\fR);
@@ -601,7 +664,7 @@ channel. \fIgetOptionProc\fR must match the following prototype:
.PP
.CS
typedef int \fBTcl_DriverGetOptionProc\fR(
void *\fIinstanceData\fR,
ClientData \fIinstanceData\fR,
Tcl_Interp *\fIinterp\fR,
const char *\fIoptionName\fR,
Tcl_DString *\fIoptionValue\fR);
@@ -639,7 +702,7 @@ notice events of interest on this channel.
.PP
.CS
typedef void \fBTcl_DriverWatchProc\fR(
void *\fIinstanceData\fR,
ClientData \fIinstanceData\fR,
int \fImask\fR);
.CE
.PP
@@ -670,9 +733,9 @@ the generic layer to retrieve a device-specific handle from the channel.
.PP
.CS
typedef int \fBTcl_DriverGetHandleProc\fR(
void *\fIinstanceData\fR,
ClientData \fIinstanceData\fR,
int \fIdirection\fR,
void **\fIhandlePtr\fR);
ClientData *\fIhandlePtr\fR);
.CE
.PP
\fIInstanceData\fR is the same as the value passed to
@@ -699,7 +762,7 @@ It should be set to NULL.
.PP
.CS
typedef int \fBTcl_DriverFlushProc\fR(
void *\fIinstanceData\fR);
ClientData \fIinstanceData\fR);
.CE
.PP
This value can be retrieved with \fBTcl_ChannelFlushProc\fR, which returns
@@ -714,7 +777,7 @@ that occur on the underlying (stacked) channel.
.PP
.CS
typedef int \fBTcl_DriverHandlerProc\fR(
void *\fIinstanceData\fR,
ClientData \fIinstanceData\fR,
int \fIinterestMask\fR);
.CE
.PP
@@ -743,7 +806,7 @@ might be maintaining using the calling thread as the associate. See
.PP
.CS
typedef void \fBTcl_DriverThreadActionProc\fR(
void *\fIinstanceData\fR,
ClientData \fIinstanceData\fR,
int \fIaction\fR);
.CE
.PP
@@ -760,8 +823,8 @@ length. It can be NULL.
.PP
.CS
typedef int \fBTcl_DriverTruncateProc\fR(
void *\fIinstanceData\fR,
Tcl_WideInt \fIlength\fR);
ClientData \fIinstanceData\fR,
long long \fIlength\fR);
.CE
.PP
\fIInstanceData\fR is the same as the value passed to
@@ -808,6 +871,58 @@ The function takes good care of inserting minus signs before
each option, commas after, and an
.QW or
before the last option.
.SH "OLD CHANNEL TYPES"
The original (8.3.1 and below) \fBTcl_ChannelType\fR structure contains
the following fields:
.PP
.CS
typedef struct Tcl_ChannelType {
const char *\fItypeName\fR;
Tcl_DriverBlockModeProc *\fIblockModeProc\fR;
Tcl_DriverCloseProc *\fIcloseProc\fR;
Tcl_DriverInputProc *\fIinputProc\fR;
Tcl_DriverOutputProc *\fIoutputProc\fR;
Tcl_DriverSeekProc *\fIseekProc\fR;
Tcl_DriverSetOptionProc *\fIsetOptionProc\fR;
Tcl_DriverGetOptionProc *\fIgetOptionProc\fR;
Tcl_DriverWatchProc *\fIwatchProc\fR;
Tcl_DriverGetHandleProc *\fIgetHandleProc\fR;
Tcl_DriverClose2Proc *\fIclose2Proc\fR;
} \fBTcl_ChannelType\fR;
.CE
.PP
It is still possible to create channel with the above structure. The
internal channel code will determine the version. It is imperative to use
the new \fBTcl_ChannelType\fR structure if you are creating a stacked
channel driver, due to problems with the earlier stacked channel
implementation (in 8.2.0 to 8.3.1).
.PP
Prior to 8.4.0 (i.e. during the later releases of 8.3 and early part
of the 8.4 development cycle) the \fBTcl_ChannelType\fR structure
contained the following fields:
.PP
.CS
typedef struct Tcl_ChannelType {
const char *\fItypeName\fR;
Tcl_ChannelTypeVersion \fIversion\fR;
Tcl_DriverCloseProc *\fIcloseProc\fR;
Tcl_DriverInputProc *\fIinputProc\fR;
Tcl_DriverOutputProc *\fIoutputProc\fR;
Tcl_DriverSeekProc *\fIseekProc\fR;
Tcl_DriverSetOptionProc *\fIsetOptionProc\fR;
Tcl_DriverGetOptionProc *\fIgetOptionProc\fR;
Tcl_DriverWatchProc *\fIwatchProc\fR;
Tcl_DriverGetHandleProc *\fIgetHandleProc\fR;
Tcl_DriverClose2Proc *\fIclose2Proc\fR;
Tcl_DriverBlockModeProc *\fIblockModeProc\fR;
Tcl_DriverFlushProc *\fIflushProc\fR;
Tcl_DriverHandlerProc *\fIhandlerProc\fR;
Tcl_DriverTruncateProc *\fItruncateProc\fR;
} \fBTcl_ChannelType\fR;
.CE
.PP
When the above structure is registered as a channel type, the
\fIversion\fR field should always be \fBTCL_CHANNEL_VERSION_2\fR.
.SH "SEE ALSO"
Tcl_Close(3), Tcl_OpenFileChannel(3), Tcl_SetErrno(3), Tcl_QueueEvent(3), Tcl_StackChannel(3), Tcl_GetStdChannel(3)
.SH KEYWORDS
+2 -2
View File
@@ -32,7 +32,7 @@ a zero value to temporarily disable an existing handler.
.AP Tcl_FileProc *proc in
Procedure to invoke whenever the channel indicated by \fIchannel\fR meets
the conditions specified by \fImask\fR.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR.
.BE
.SH DESCRIPTION
@@ -48,7 +48,7 @@ what it means for a channel to be readable or writable.
.PP
.CS
typedef void \fBTcl_ChannelProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
int \fImask\fR);
.CE
.PP
+2 -2
View File
@@ -26,7 +26,7 @@ void
The channel for which to create or delete a close callback.
.AP Tcl_CloseProc *proc in
The procedure to call as the callback.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR.
.BE
.SH DESCRIPTION
@@ -38,7 +38,7 @@ Arbitrary one-word value to pass to \fIproc\fR.
.PP
.CS
typedef void \fBTcl_CloseProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
The \fIclientData\fR is the same as the value provided in the call to
+3 -3
View File
@@ -25,7 +25,7 @@ Name of command.
.AP Tcl_CmdProc *proc in
Implementation of new command: \fIproc\fR will be called whenever
\fIcmdName\fR is invoked as a command.
.AP voie *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR and \fIdeleteProc\fR.
.AP Tcl_CmdDeleteProc *deleteProc in
Procedure to call before \fIcmdName\fR is deleted from the interpreter;
@@ -75,7 +75,7 @@ and it returns NULL.
.PP
.CS
typedef int \fBTcl_CmdProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR,
int \fIargc\fR,
const char *\fIargv\fR[]);
@@ -131,7 +131,7 @@ result that match the type \fBTcl_CmdDeleteProc\fR:
.PP
.CS
typedef void \fBTcl_CmdDeleteProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
The \fIclientData\fR argument will be the same as the \fIclientData\fR
+2 -2
View File
@@ -29,7 +29,7 @@ a handler.
.AP Tcl_FileProc *proc in
Procedure to invoke whenever the file or device indicated
by \fIfile\fR meets the conditions specified by \fImask\fR.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR.
.BE
.SH DESCRIPTION
@@ -51,7 +51,7 @@ type \fBTcl_FileProc\fR:
.PP
.CS
typedef void \fBTcl_FileProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
int \fImask\fR);
.CE
.PP
+162
View File
@@ -0,0 +1,162 @@
'\"
'\" Copyright (c) 1989-1993 The Regents of the University of California.
'\" Copyright (c) 1994-1996 Sun Microsystems, Inc.
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
.TH Tcl_CreateMathFunc 3 8.4 Tcl "Tcl Library Procedures"
.so man.macros
.BS
.SH NAME
Tcl_CreateMathFunc, Tcl_GetMathFuncInfo, Tcl_ListMathFuncs \- Define, query and enumerate math functions for expressions
.SH "NOTICE OF EVENTUAL DEPRECATION"
.PP
The \fBTcl_CreateMathFunc\fR and \fBTcl_GetMathFuncInfo\fR functions
are rendered somewhat obsolete by the ability to create functions for
expressions by placing commands in the \fBtcl::mathfunc\fR namespace,
as described in the \fBmathfunc\fR manual page; the API described on
this page is not expected to be maintained indefinitely.
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
.sp
void
\fBTcl_CreateMathFunc\fR(\fIinterp, name, numArgs, argTypes, proc, clientData\fR)
.sp
int
\fBTcl_GetMathFuncInfo\fR(\fIinterp, name, numArgsPtr, argTypesPtr, procPtr,
clientDataPtr\fR)
.sp
Tcl_Obj *
\fBTcl_ListMathFuncs\fR(\fIinterp, pattern\fR)
.SH ARGUMENTS
.AS Tcl_ValueType *clientDataPtr out
.AP Tcl_Interp *interp in
Interpreter in which new function will be defined.
.AP "const char" *name in
Name for new function.
.AP int numArgs in
Number of arguments to new function; also gives size of \fIargTypes\fR array.
.AP Tcl_ValueType *argTypes in
Points to an array giving the permissible types for each argument to
function.
.AP Tcl_MathProc *proc in
Procedure that implements the function.
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR when it is invoked.
.AP int *numArgsPtr out
Points to a variable that will be set to contain the number of
arguments to the function.
.AP Tcl_ValueType **argTypesPtr out
Points to a variable that will be set to contain a pointer to an array
giving the permissible types for each argument to the function which
will need to be freed up using \fITcl_Free\fR.
.AP Tcl_MathProc **procPtr out
Points to a variable that will be set to contain a pointer to the
implementation code for the function (or NULL if the function is
implemented directly in bytecode).
.AP ClientData *clientDataPtr out
Points to a variable that will be set to contain the clientData
argument passed to \fITcl_CreateMathFunc\fR when the function was
created if the function is not implemented directly in bytecode.
.AP "const char" *pattern in
Pattern to match against function names so as to filter them (by
passing to \fITcl_StringMatch\fR), or NULL to not apply any filter.
.BE
.SH DESCRIPTION
.PP
Tcl allows a number of mathematical functions to be used in
expressions, such as \fBsin\fR, \fBcos\fR, and \fBhypot\fR.
These functions are represented by commands in the namespace,
\fBtcl::mathfunc\fR. The \fBTcl_CreateMathFunc\fR function is
an obsolete way for applications to add additional functions
to those already provided by Tcl or to replace existing functions.
It should not be used by new applications, which should create
math functions using \fBTcl_CreateObjCommand\fR to create a command
in the \fBtcl::mathfunc\fR namespace.
.PP
In the \fBTcl_CreateMathFunc\fR interface,
\fIName\fR is the name of the function as it will appear in expressions.
If \fIname\fR does not already exist in the \fB::tcl::mathfunc\fR
namespace, then a new command is created in that namespace.
If \fIname\fR does exist, then the existing function is replaced.
\fINumArgs\fR and \fIargTypes\fR describe the arguments to the function.
Each entry in the \fIargTypes\fR array must be
one of \fBTCL_INT\fR, \fBTCL_DOUBLE\fR, \fBTCL_WIDE_INT\fR,
or \fBTCL_EITHER\fR to indicate whether the corresponding argument must be an
integer, a double-precision floating value, a wide (64-bit) integer,
or any, respectively.
.PP
Whenever the function is invoked in an expression Tcl will invoke
\fIproc\fR. \fIProc\fR should have arguments and result that match
the type \fBTcl_MathProc\fR:
.PP
.CS
typedef int \fBTcl_MathProc\fR(
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR,
Tcl_Value *\fIargs\fR,
Tcl_Value *\fIresultPtr\fR);
.CE
.PP
When \fIproc\fR is invoked the \fIclientData\fR and \fIinterp\fR
arguments will be the same as those passed to \fBTcl_CreateMathFunc\fR.
\fIArgs\fR will point to an array of \fInumArgs\fR Tcl_Value structures,
which describe the actual arguments to the function:
.PP
.CS
typedef struct Tcl_Value {
Tcl_ValueType \fItype\fR;
long \fIintValue\fR;
double \fIdoubleValue\fR;
Tcl_WideInt \fIwideValue\fR;
} \fBTcl_Value\fR;
.CE
.PP
The \fItype\fR field indicates the type of the argument and is
one of \fBTCL_INT\fR, \fBTCL_DOUBLE\fR or \fBTCL_WIDE_INT\fR.
It will match the \fIargTypes\fR value specified for the function unless
the \fIargTypes\fR value was \fBTCL_EITHER\fR. Tcl converts
the argument supplied in the expression to the type requested in
\fIargTypes\fR, if that is necessary.
Depending on the value of the \fItype\fR field, the \fIintValue\fR,
\fIdoubleValue\fR or \fIwideValue\fR
field will contain the actual value of the argument.
.PP
\fIProc\fR should compute its result and store it either as an integer
in \fIresultPtr->intValue\fR or as a floating value in
\fIresultPtr->doubleValue\fR.
It should set also \fIresultPtr->type\fR to one of
\fBTCL_INT\fR, \fBTCL_DOUBLE\fR or \fBTCL_WIDE_INT\fR
to indicate which value was set.
Under normal circumstances \fIproc\fR should return \fBTCL_OK\fR.
If an error occurs while executing the function, \fIproc\fR should
return \fBTCL_ERROR\fR and leave an error message in the interpreter's result.
.PP
\fBTcl_GetMathFuncInfo\fR retrieves the values associated with
function \fIname\fR that were passed to a preceding
\fBTcl_CreateMathFunc\fR call. Normally, the return code is
\fBTCL_OK\fR but if the named function does not exist, \fBTCL_ERROR\fR
is returned and an error message is placed in the interpreter's
result.
.PP
If an error did not occur, the array reference placed in the variable
pointed to by \fIargTypesPtr\fR is newly allocated, and should be
released by passing it to \fBTcl_Free\fR. Some functions (the
standard set implemented in the core, and those defined by placing
commands in the \fBtcl::mathfunc\fR namespace) do not have
argument type information; attempting to retrieve values for
them causes a NULL to be stored in the variable pointed to by
\fIprocPtr\fR and the variable pointed to by \fIclientDataPtr\fR
will not be modified. The variable pointed to by \fInumArgsPointer\fR
will contain -1, and no argument types will be stored in the variable
pointed to by \fIargTypesPointer\fR.
.PP
\fBTcl_ListMathFuncs\fR returns a Tcl value containing a list of all
the math functions defined in the interpreter whose name matches
\fIpattern\fR. The returned value has a reference count of zero.
.SH "SEE ALSO"
expr(n), info(n), Tcl_CreateObjCommand(3), Tcl_Free(3), Tcl_NewListObj(3)
.SH KEYWORDS
expression, mathematical function
+10 -10
View File
@@ -59,7 +59,7 @@ Name of command.
.AP Tcl_ObjCmdProc *proc in
Implementation of the new command: \fIproc\fR will be called whenever
\fIcmdName\fR is invoked as a command.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR and \fIdeleteProc\fR.
.AP Tcl_CmdDeleteProc *deleteProc in
Procedure to call before \fIcmdName\fR is deleted from the interpreter;
@@ -102,7 +102,7 @@ and it returns NULL.
.PP
.CS
typedef int \fBTcl_ObjCmdProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR,
int \fIobjc\fR,
Tcl_Obj *const \fIobjv\fR[]);
@@ -175,7 +175,7 @@ result that match the type \fBTcl_CmdDeleteProc\fR:
.PP
.CS
typedef void \fBTcl_CmdDeleteProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
The \fIclientData\fR argument will be the same as the \fIclientData\fR
@@ -217,11 +217,11 @@ A \fBTcl_CmdInfo\fR structure has the following fields:
typedef struct Tcl_CmdInfo {
int \fIisNativeObjectProc\fR;
Tcl_ObjCmdProc *\fIobjProc\fR;
void *\fIobjClientData\fR;
ClientData \fIobjClientData\fR;
Tcl_CmdProc *\fIproc\fR;
void *\fIclientData\fR;
ClientData \fIclientData\fR;
Tcl_CmdDeleteProc *\fIdeleteProc\fR;
void *\fIdeleteData\fR;
ClientData \fIdeleteData\fR;
Tcl_Namespace *\fInamespacePtr\fR;
} \fBTcl_CmdInfo\fR;
.CE
@@ -247,7 +247,7 @@ otherwise, this is a compatibility procedure
registered by \fBTcl_CreateObjCommand\fR
that simply calls the command's
value-based procedure after converting its string arguments to Tcl values.
The field \fIdeleteData\fR is the clientData value
The field \fIdeleteData\fR is the ClientData value
to pass to \fIdeleteProc\fR; it is normally the same as
\fIclientData\fR but may be set independently using the
\fBTcl_SetCommandInfo\fR procedure.
@@ -261,7 +261,7 @@ from \fBTcl_CreateObjCommand\fR in place of the command name. If the
and fills in the structure designated by \fIinfoPtr\fR.
.PP
\fBTcl_SetCommandInfo\fR is used to modify the procedures and
clientData values associated with a command.
ClientData values associated with a command.
Its \fIcmdName\fR argument is the name of a command in \fIinterp\fR.
\fIcmdName\fR may include \fB::\fR namespace qualifiers
to identify a command in a particular namespace.
@@ -277,9 +277,9 @@ copies the information from \fI*infoPtr\fR to Tcl's internal structure
for the command and returns 1.
.PP
Note that \fBTcl_SetCommandInfo\fR and
\fBTcl_SetCommandInfoFromToken\fR both allow the clientData for a
\fBTcl_SetCommandInfoFromToken\fR both allow the ClientData for a
command's deletion procedure to be given a different value than the
clientData for its command procedure.
ClientData for its command procedure.
.PP
Note that neither \fBTcl_SetCommandInfo\fR nor
\fBTcl_SetCommandInfoFromToken\fR will change a command's namespace.
+2 -2
View File
@@ -24,7 +24,7 @@ Tcl_TimerToken
How many milliseconds to wait before invoking \fIproc\fR.
.AP Tcl_TimerProc *proc in
Procedure to invoke after \fImilliseconds\fR have elapsed.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR.
.AP Tcl_TimerToken token in
Token for previously created timer handler (the return value
@@ -51,7 +51,7 @@ the type \fBTcl_TimerProc\fR:
.PP
.CS
typedef void \fBTcl_TimerProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
The \fIclientData\fR parameter to \fIproc\fR is a
+7 -7
View File
@@ -1,7 +1,7 @@
'\"
'\" Copyright (c) 1989-1993 The Regents of the University of California.
'\" Copyright (c) 1994-1996 Sun Microsystems, Inc.
'\" Copyright (c) 2002 by Kevin B. Kenny <kennykb@acm.org>. All rights reserved.
'\" Copyright (c) 2002 Kevin B. Kenny <kennykb@acm.org>. All rights reserved.
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
@@ -41,7 +41,7 @@ details of the calling sequence.
.AP Tcl_CmdTraceProc *proc in
Procedure to call for each command that is executed. See below for
details on the calling sequence.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIobjProc\fR or \fIproc\fR.
.AP Tcl_CmdObjTraceDeleteProc *deleteProc in
Procedure to call when the trace is deleted. See below for details of
@@ -66,7 +66,7 @@ interpreter.
.PP
.CS
typedef int \fBTcl_CmdObjTraceProc\fR(
\fBvoid *\fR \fIclientData\fR,
\fBClientData\fR \fIclientData\fR,
\fBTcl_Interp\fR* \fIinterp\fR,
int \fIlevel\fR,
const char *\fIcommand\fR,
@@ -77,7 +77,7 @@ typedef int \fBTcl_CmdObjTraceProc\fR(
.PP
The \fIclientData\fR and \fIinterp\fR parameters are copies of the
corresponding arguments given to \fBTcl_CreateTrace\fR.
\fIclientData\fR typically points to an application-specific data
\fIClientData\fR typically points to an application-specific data
structure that describes what to do when \fIobjProc\fR is invoked. The
\fIlevel\fR parameter gives the nesting level of the command (1 for
top-level commands passed to \fBTcl_Eval\fR by the application, 2 for
@@ -144,7 +144,7 @@ When \fBTcl_DeleteTrace\fR is called, the interpreter invokes the
.PP
.CS
typedef void \fBTcl_CmdObjTraceDeleteProc\fR(
\fBvoid *\fR \fIclientData\fR);
\fBClientData\fR \fIclientData\fR);
.CE
.PP
The \fIclientData\fR parameter will be the same as the
@@ -160,12 +160,12 @@ match the type \fBTcl_CmdTraceProc\fR:
.PP
.CS
typedef void \fBTcl_CmdTraceProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR,
int \fIlevel\fR,
char *\fIcommand\fR,
Tcl_CmdProc *\fIcmdProc\fR,
void *\fIcmdClientData\fR,
ClientData \fIcmdClientData\fR,
int \fIargc\fR,
const char *\fIargv\fR[]);
.CE
+11 -5
View File
@@ -9,7 +9,7 @@
.so man.macros
.BS
.SH NAME
Tcl_DStringInit, Tcl_DStringAppend, Tcl_DStringAppendElement, Tcl_DStringStartSublist, Tcl_DStringEndSublist, Tcl_DStringLength, Tcl_DStringValue, Tcl_DStringSetLength, Tcl_DStringFree, Tcl_DStringResult, Tcl_DStringGetResult \- manipulate dynamic strings
Tcl_DStringInit, Tcl_DStringAppend, Tcl_DStringAppendElement, Tcl_DStringStartSublist, Tcl_DStringEndSublist, Tcl_DStringLength, Tcl_DStringValue, Tcl_DStringSetLength, Tcl_DStringTrunc, Tcl_DStringFree, Tcl_DStringResult, Tcl_DStringGetResult \- manipulate dynamic strings
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
@@ -26,7 +26,7 @@ char *
.sp
\fBTcl_DStringEndSublist\fR(\fIdsPtr\fR)
.sp
size_t
int
\fBTcl_DStringLength\fR(\fIdsPtr\fR)
.sp
char *
@@ -34,6 +34,8 @@ char *
.sp
\fBTcl_DStringSetLength\fR(\fIdsPtr, newLength\fR)
.sp
\fBTcl_DStringTrunc\fR(\fIdsPtr, newLength\fR)
.sp
\fBTcl_DStringFree\fR(\fIdsPtr\fR)
.sp
\fBTcl_DStringResult\fR(\fIinterp, dsPtr\fR)
@@ -47,10 +49,10 @@ Pointer to structure that is used to manage a dynamic string.
Pointer to characters to append to dynamic string.
.AP "const char" *element in
Pointer to characters to append as list element to dynamic string.
.AP size_t length in
Number of bytes from \fIbytes\fR to add to dynamic string. If TCL_INDEX_NONE,
.AP int length in
Number of bytes from \fIbytes\fR to add to dynamic string. If -1,
add all characters up to null terminating character.
.AP size_t newLength in
.AP int newLength in
New length for dynamic string, not including null terminating
character.
.AP Tcl_Interp *interp in/out
@@ -126,6 +128,10 @@ caller to fill in the new space.
even if the string is truncated to zero length, so \fBTcl_DStringFree\fR
will still need to be called.
.PP
\fBTcl_DStringTrunc\fR changes the length of a dynamic string.
This procedure is now deprecated. \fBTcl_DStringSetLength\fR should
be used instead.
.PP
\fBTcl_DStringFree\fR should be called when you are finished using
the string. It frees up any memory that was allocated for the string
and reinitializes the string's value to an empty string.
+2 -2
View File
@@ -21,7 +21,7 @@ Tcl_DoWhenIdle, Tcl_CancelIdleCall \- invoke a procedure when there are no pendi
.AS Tcl_IdleProc clientData
.AP Tcl_IdleProc *proc in
Procedure to invoke.
.AP coid *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR.
.BE
.SH DESCRIPTION
@@ -43,7 +43,7 @@ type \fBTcl_IdleProc\fR:
.PP
.CS
typedef void \fBTcl_IdleProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
The \fIclientData\fR parameter to \fIproc\fR is a copy of the \fIclientData\fR
+5 -5
View File
@@ -1,6 +1,6 @@
'\"
'\" Copyright (c) 1992-1999 Karl Lehenbauer and Mark Diekhans.
'\" Copyright (c) 2000 by Scriptics Corporation.
'\" Copyright (c) 1992-1999 Karl Lehenbauer & Mark Diekhans.
'\" Copyright (c) 2000 Scriptics Corporation.
'\" All rights reserved.
'\"
.TH "Tcl_DumpActiveMemory" 3 8.1 Tcl "Tcl Library Procedures"
@@ -43,7 +43,7 @@ is not defined, these functions are all no-ops.
\fBTcl_DumpActiveMemory\fR will output a list of all currently
allocated memory to the specified file. The information output for
each allocated block of memory is: starting and ending addresses
(excluding guard zone), size, source file where \fBTcl_Alloc\fR was
(excluding guard zone), size, source file where \fBckalloc\fR was
called to allocate the block and line number in that file. It is
especially useful to call \fBTcl_DumpActiveMemory\fR after the Tcl
interpreter has been deleted.
@@ -55,8 +55,8 @@ by \fBTcl_Main\fR.
\fBTcl_ValidateAllMemory\fR forces a validation of the guard zones of
all currently allocated blocks of memory. Normally validation of a
block occurs when its freed, unless full validation is enabled, in
which case validation of all blocks occurs when \fBTcl_Alloc\fR and
\fBTcl_Free\fR are called. This function forces the validation to occur
which case validation of all blocks occurs when \fBckalloc\fR and
\fBckfree\fR are called. This function forces the validation to occur
at any point.
.SH "SEE ALSO"
+40 -7
View File
@@ -8,7 +8,7 @@
.so man.macros
.BS
.SH NAME
Tcl_GetEncoding, Tcl_FreeEncoding, Tcl_GetEncodingFromObj, Tcl_ExternalToUtfDString, Tcl_ExternalToUtf, Tcl_UtfToExternalDString, Tcl_UtfToExternal, Tcl_GetEncodingName, Tcl_SetSystemEncoding, Tcl_GetEncodingNameFromEnvironment, Tcl_GetEncodingNames, Tcl_CreateEncoding, Tcl_GetEncodingSearchPath, Tcl_SetEncodingSearchPath \- procedures for creating and using encodings
Tcl_GetEncoding, Tcl_FreeEncoding, Tcl_GetEncodingFromObj, Tcl_ExternalToUtfDString, Tcl_ExternalToUtf, Tcl_UtfToExternalDString, Tcl_UtfToExternal, Tcl_GetEncodingName, Tcl_SetSystemEncoding, Tcl_GetEncodingNameFromEnvironment, Tcl_GetEncodingNames, Tcl_CreateEncoding, Tcl_GetEncodingSearchPath, Tcl_SetEncodingSearchPath, Tcl_GetDefaultEncodingDir, Tcl_SetDefaultEncodingDir \- procedures for creating and using encodings
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
@@ -36,6 +36,12 @@ int
\fBTcl_UtfToExternal\fR(\fIinterp, encoding, src, srcLen, flags, statePtr,
dst, dstLen, srcReadPtr, dstWrotePtr, dstCharsPtr\fR)
.sp
char *
\fBTcl_WinTCharToUtf\fR(\fItsrc, srcLen, dstPtr\fR)
.sp
TCHAR *
\fBTcl_WinUtfToTChar\fR(\fIsrc, srcLen, dstPtr\fR)
.sp
const char *
\fBTcl_GetEncodingName\fR(\fIencoding\fR)
.sp
@@ -56,6 +62,12 @@ Tcl_Obj *
.sp
int
\fBTcl_SetEncodingSearchPath\fR(\fIsearchPath\fR)
.sp
const char *
\fBTcl_GetDefaultEncodingDir\fR(\fIvoid\fR)
.sp
void
\fBTcl_SetDefaultEncodingDir\fR(\fIpath\fR)
.SH ARGUMENTS
.AS "const Tcl_EncodingType" *dstWrotePtr in/out
.AP Tcl_Interp *interp in
@@ -73,11 +85,11 @@ Points to storage where encoding token is to be written.
.AP "const char" *src in
For the \fBTcl_ExternalToUtf\fR functions, an array of bytes in the
specified encoding that are to be converted to UTF-8. For the
\fBTcl_UtfToExternal\fR function, an array of
\fBTcl_UtfToExternal\fR and \fBTcl_WinUtfToTChar\fR functions, an array of
UTF-8 characters to be converted to the specified encoding.
.AP "const TCHAR" *tsrc in
An array of Windows TCHAR characters to convert to UTF-8.
.AP size_t srcLen in
.AP int srcLen in
Length of \fIsrc\fR or \fItsrc\fR in bytes. If the length is negative, the
encoding-specific length of the string is used.
.AP Tcl_DString *dstPtr out
@@ -243,6 +255,18 @@ is filled with the corresponding number of bytes that were stored in
\fIdst\fR. The return values are the same as the return values for
\fBTcl_ExternalToUtf\fR.
.PP
\fBTcl_WinUtfToTChar\fR and \fBTcl_WinTCharToUtf\fR are Windows-only
convenience functions for converting between UTF-8 and Windows strings
based on the TCHAR type which is by convention a Unicode character on
Windows NT. Those functions are deprecated. You can use
\fBTcl_UtfToWCharDString\fR resp. \fBTcl_WCharToUtfDString\fR as replacement.
If you want compatibility with earlier Tcl releases than 8.7, use
\fBTcl_UtfToUniCharDString\fR resp. \fBTcl_UniCharToUtfDString\fR as
replacement, and make sure you compile your extension with -DTCL_UTF_MAX=3.
Beware: Those replacement functions don't initialize their Tcl_DString (you'll
have to do that yourself), and \fBTcl_UniCharToUtfDString\fR from Tcl 8.6
doesn't accept -1 as length parameter.
.PP
\fBTcl_GetEncodingName\fR is roughly the inverse of \fBTcl_GetEncoding\fR.
Given an \fIencoding\fR, the return value is the \fIname\fR argument that
was used to create the encoding. The string returned by
@@ -269,7 +293,7 @@ the encoding name to it. The \fBTcl_DStringValue\fR is returned.
\fBTcl_GetEncodingNames\fR sets the \fIinterp\fR result to a list
consisting of the names of all the encodings that are currently defined
or can be dynamically loaded, searching the encoding path specified by
\fBTcl_SetEncodingSearchPath\fR. This procedure does not ensure that the
\fBTcl_SetDefaultEncodingDir\fR. This procedure does not ensure that the
dynamically-loadable encoding files contain valid data, but merely that they
exist.
.PP
@@ -296,7 +320,7 @@ typedef struct Tcl_EncodingType {
Tcl_EncodingConvertProc *\fItoUtfProc\fR;
Tcl_EncodingConvertProc *\fIfromUtfProc\fR;
Tcl_EncodingFreeProc *\fIfreeProc\fR;
void *\fIclientData\fR;
ClientData \fIclientData\fR;
int \fInullSize\fR;
} \fBTcl_EncodingType\fR;
.CE
@@ -327,7 +351,7 @@ type \fBTcl_EncodingConvertProc\fR:
.PP
.CS
typedef int \fBTcl_EncodingConvertProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
const char *\fIsrc\fR,
int \fIsrcLen\fR,
int \fIflags\fR,
@@ -359,7 +383,7 @@ The callback procedure \fIfreeProc\fR, if non-NULL, should match the type
.PP
.CS
typedef void \fBTcl_EncodingFreeProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
This \fIfreeProc\fR function is called when the encoding is deleted. The
@@ -384,6 +408,15 @@ are not verified as existing readable filesystem directories. When
searching for encoding data files takes place, and non-existent or
non-readable filesystem directories on the \fIsearchPath\fR are silently
ignored.
.PP
\fBTcl_GetDefaultEncodingDir\fR and \fBTcl_SetDefaultEncodingDir\fR
are obsolete interfaces best replaced with calls to
\fBTcl_GetEncodingSearchPath\fR and \fBTcl_SetEncodingSearchPath\fR.
They are called to access and set the first element of the \fIsearchPath\fR
list. Since Tcl searches \fIsearchPath\fR for encoding data files in
list order, these routines establish the
.QW default
directory in which to find encoding data files.
.SH "ENCODING FILES"
Space would prohibit precompiling into Tcl every possible encoding
algorithm, so many encodings are stored on disk as dynamically-loadable
+20 -3
View File
@@ -10,7 +10,7 @@
.so man.macros
.BS
.SH NAME
Tcl_EvalObjEx, Tcl_EvalFile, Tcl_EvalObjv, Tcl_Eval, Tcl_EvalEx, Tcl_GlobalEval, Tcl_GlobalEvalObj, Tcl_VarEval \- execute Tcl scripts
Tcl_EvalObjEx, Tcl_EvalFile, Tcl_EvalObjv, Tcl_Eval, Tcl_EvalEx, Tcl_GlobalEval, Tcl_GlobalEvalObj, Tcl_VarEval, Tcl_VarEvalVA \- execute Tcl scripts
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
@@ -38,6 +38,9 @@ int
.sp
int
\fBTcl_VarEval\fR(\fIinterp, part, part, ... \fB(char *) NULL\fR)
.sp
int
\fBTcl_VarEvalVA\fR(\fIinterp, argList\fR)
.SH ARGUMENTS
.AS Tcl_Interp **termPtr
.AP Tcl_Interp *interp in
@@ -64,6 +67,9 @@ first null byte are used.
Points to first byte of script to execute (null-terminated and UTF-8).
.AP char *part in
String forming part of a Tcl script.
.AP va_list argList in
An argument list which must have been initialized using
\fBva_start\fR, and cleared using \fBva_end\fR.
.BE
.SH DESCRIPTION
@@ -122,10 +128,16 @@ might be a UTF-8 special code. The string is parsed and executed directly
bytecodes. In situations where it is known that the script will never be
executed again, \fBTcl_Eval\fR may be faster than \fBTcl_EvalObjEx\fR.
\fBTcl_Eval\fR returns a completion code and result just like
\fBTcl_EvalObjEx\fR.
\fBTcl_EvalObjEx\fR. Note: for backward compatibility with versions before
Tcl 8.0, \fBTcl_Eval\fR copies the value result in \fIinterp\fR to
\fIinterp->result\fR (use is deprecated) where it can be accessed directly.
This makes \fBTcl_Eval\fR somewhat slower than \fBTcl_EvalEx\fR, which
does not do the copy.
.PP
\fBTcl_EvalEx\fR is an extended version of \fBTcl_Eval\fR that takes
additional arguments \fInumBytes\fR and \fIflags\fR.
additional arguments \fInumBytes\fR and \fIflags\fR. For the
efficiency reason given above, \fBTcl_EvalEx\fR is generally preferred
over \fBTcl_Eval\fR.
.PP
\fBTcl_GlobalEval\fR and \fBTcl_GlobalEvalObj\fR are older procedures
that are now deprecated. They are similar to \fBTcl_EvalEx\fR and
@@ -141,6 +153,11 @@ It returns the result of the command and also modifies
the interpreter result in the same way as \fBTcl_Eval\fR.
The last argument to \fBTcl_VarEval\fR must be NULL to indicate the end
of arguments. \fBTcl_VarEval\fR is now deprecated.
.PP
\fBTcl_VarEvalVA\fR is the same as \fBTcl_VarEval\fR except that
instead of taking a variable number of arguments it takes an argument
list. Interfaces using argument lists have been found to be nonportable
in practice. This function is deprecated and will be removed in Tcl 9.0.
.SH "FLAG BITS"
.PP
+6 -5
View File
@@ -42,7 +42,7 @@ usually means that an error occurred.
Procedure to invoke before exiting application, or (for
\fBTcl_SetExitProc\fR) NULL to uninstall the current application exit
procedure.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR.
.BE
@@ -64,7 +64,7 @@ otherwise causes the application to terminate without calling
returns control to its caller.
If an application exit handler has been installed (see
\fBTcl_SetExitProc\fR), that handler is invoked with an argument
consisting of the exit status (cast to void *); the application
consisting of the exit status (cast to ClientData); the application
exit handler should not return control to Tcl.
.PP
\fBTcl_Finalize\fR is similar to \fBTcl_Exit\fR except that it does not
@@ -93,7 +93,7 @@ and freeing global memory.
.PP
.CS
typedef void \fBTcl_ExitProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
The \fIclientData\fR parameter to \fIproc\fR is a
@@ -133,9 +133,10 @@ installed, that exit handler takes over complete responsibility for
finalization of Tcl's subsystems via \fBTcl_Finalize\fR at an
appropriate time. The argument passed to \fIproc\fR when it is
invoked will be the exit status code (as passed to \fBTcl_Exit\fR)
cast to a void *value.
cast to a ClientData value.
.PP
\fBTcl_SetExitProc\fR can not be used in stub-enabled extensions.
\fBTcl_SetExitProc\fR can not be used in stub-enabled extensions. Its symbol
entry in the stub table is deprecated and it will be removed in Tcl 9.0.
.SH "SEE ALSO"
exit(n)
.SH KEYWORDS
+20 -20
View File
@@ -20,7 +20,7 @@ int
int
\fBTcl_FSUnregister\fR(\fIfsPtr\fR)
.sp
void *
ClientData
\fBTcl_FSData\fR(\fIfsPtr\fR)
.sp
void
@@ -123,7 +123,7 @@ Tcl_Obj *
int
\fBTcl_FSConvertToPathType\fR(\fIinterp, pathPtr\fR)
.sp
void *
ClientData
\fBTcl_FSGetInternalRep\fR(\fIpathPtr, fsPtr\fR)
.sp
Tcl_Obj *
@@ -144,16 +144,16 @@ Tcl_Obj *
Tcl_StatBuf *
\fBTcl_AllocStatBuf\fR()
.sp
Tcl_WideInt
long long
\fBTcl_GetAccessTimeFromStat\fR(\fIstatPtr\fR)
.sp
unsigned
\fBTcl_GetBlockSizeFromStat\fR(\fIstatPtr\fR)
.sp
Tcl_WideUInt
unsigned long long
\fBTcl_GetBlocksFromStat\fR(\fIstatPtr\fR)
.sp
Tcl_WideInt
long long
\fBTcl_GetChangeTimeFromStat\fR(\fIstatPtr\fR)
.sp
int
@@ -174,10 +174,10 @@ int
unsigned
\fBTcl_GetModeFromStat\fR(\fIstatPtr\fR)
.sp
Tcl_WideInt
long long
\fBTcl_GetModificationTimeFromStat\fR(\fIstatPtr\fR)
.sp
Tcl_WideUInt
unsigned long long
\fBTcl_GetSizeFromStat\fR(\fIstatPtr\fR)
.sp
int
@@ -208,7 +208,7 @@ this structure will be returned. This parameter may be NULL.
.AP Tcl_Interp *interp in
Interpreter to use either for results, evaluation, or reporting error
messages.
.AP void *clientData in
.AP ClientData clientData in
The native description of the path value to create.
.AP Tcl_Obj *firstPtr in
The first of two path values to compare. The value may be converted
@@ -241,11 +241,11 @@ The structure that contains the result of a stat or lstat operation.
Name of a procedure to look up in the file's symbol table
.AP "const char" *sym2 in
Name of a procedure to look up in the file's symbol table
.AP Tcl_PackageInitProc **proc1Ptr out
.AP Tcl_LibraryInitProc **proc1Ptr out
Filled with the init function for this code.
.AP Tcl_PackageInitProc **proc2Ptr out
.AP Tcl_LibraryInitProc **proc2Ptr out
Filled with the safe-init function for this code.
.AP void **clientDataPtr out
.AP ClientData *clientDataPtr out
Filled with the clientData value to pass to this code's unload
function when it is called.
.AP Tcl_LoadHandle *loadHandlePtr out
@@ -716,7 +716,7 @@ better functions to use for most purposes.
\fBTcl_FSGetTranslatedStringPath\fR does the same as
\fBTcl_FSGetTranslatedPath\fR, but returns a character string or NULL.
The string returned is dynamically allocated and owned by the caller,
which must store it or call \fBTcl_Free\fR to ensure it is freed. Again,
which must store it or call \fBckfree\fR to ensure it is freed. Again,
\fBTcl_FSGetNormalizedPath\fR or \fBTcl_FSGetNativePath\fR are usually
better functions to use for most purposes.
.PP
@@ -783,7 +783,7 @@ It returns one of \fBTCL_PATH_ABSOLUTE\fR, \fBTCL_PATH_RELATIVE\fR, or
.SS "PORTABLE STAT RESULT API"
.PP
\fBTcl_AllocStatBuf\fR allocates a \fITcl_StatBuf\fR on the system heap (which
may be deallocated by being passed to \fBTcl_Free\fR). This allows extensions to
may be deallocated by being passed to \fBckfree\fR). This allows extensions to
invoke \fBTcl_FSStat\fR and \fBTcl_FSLstat\fR without being dependent on the
size of the buffer. That in turn depends on the flags used to build Tcl.
.PP
@@ -831,7 +831,7 @@ general that is not a good thing to do). \fBTCL_OK\fR will be returned.
the list of known filesystems, if it is known, and returns \fBTCL_OK\fR. If
the filesystem is not currently registered, \fBTCL_ERROR\fR is returned.
.PP
\fBTcl_FSData\fR will return the clientData associated with the given
\fBTcl_FSData\fR will return the ClientData associated with the given
filesystem, if that filesystem is registered. Otherwise it will
return NULL.
.PP
@@ -1008,7 +1008,7 @@ Tcl's internal list of known filesystems.
.CS
typedef int \fBTcl_FSPathInFilesystemProc\fR(
Tcl_Obj *\fIpathPtr\fR,
void **\fIclientDataPtr\fR);
ClientData *\fIclientDataPtr\fR);
.CE
.SS DUPINTERNALREPPROC
.PP
@@ -1018,8 +1018,8 @@ simply not copy the internal representation, which may then need to be
regenerated later.
.PP
.CS
typedef void *\fBTcl_FSDupInternalRepProc\fR(
void *\fIclientData\fR);
typedef ClientData \fBTcl_FSDupInternalRepProc\fR(
ClientData \fIclientData\fR);
.CE
.SS FREEINTERNALREPPROC
Free the internal representation. This must be implemented if internal
@@ -1028,7 +1028,7 @@ internal representation is generated), but may otherwise be NULL.
.PP
.CS
typedef void \fBTcl_FSFreeInternalRepProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.SS INTERNALTONORMALIZEDPROC
.PP
@@ -1039,7 +1039,7 @@ representation is the normalized path.
.PP
.CS
typedef Tcl_Obj *\fBTcl_FSInternalToNormalizedProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.SS CREATEINTERNALREPPROC
.PP
@@ -1050,7 +1050,7 @@ the \fITcl_FSPathInFilesystemProc\fR for this filesystem always
immediately creates an internal representation for paths it accepts.
.PP
.CS
typedef void *\fBTcl_FSCreateInternalRepProc\fR(
typedef ClientData \fBTcl_FSCreateInternalRepProc\fR(
Tcl_Obj *\fIpathPtr\fR);
.CE
.SS NORMALIZEPATHPROC
+2 -1
View File
@@ -59,6 +59,7 @@ equivalent to the \fBinfo nameofexecutable\fR command. NULL
is returned if the internal full path name has not been
computed or unknown.
.PP
\fBTcl_FindExecutable\fR can not be used in stub-enabled extensions.
\fBTcl_FindExecutable\fR can not be used in stub-enabled extensions. Its symbol
entry in the stub table is deprecated and it will be removed in Tcl 9.0.
.SH KEYWORDS
binary, executable file
+1 -1
View File
@@ -1,5 +1,5 @@
'\"
'\" Copyright (c) 1998-2000 by Scriptics Corporation.
'\" Copyright (c) 1998-2000 Scriptics Corporation.
'\" All rights reserved.
'\"
.TH Tcl_GetHostName 3 8.3 Tcl "Tcl Library Procedures"
+5 -2
View File
@@ -64,9 +64,12 @@ if the first such characters are
then \fIsrc\fR is expected to be in octal form; otherwise,
if the first such characters are
.QW \fB0b\fR
then \fIsrc\fR is expected to be in binary form; otherwise,
if the first such character is
.QW \fB0\fR
then \fIsrc\fR
is expected to be in binary form; otherwise, \fIsrc\fR is
expected to be in decimal form.
is expected to be in octal form; otherwise, \fIsrc\fR
is expected to be in decimal form.
.PP
\fBTcl_GetDouble\fR expects \fIsrc\fR to consist of a floating-point
number, which is: white space; a sign; a sequence of digits; a
+1 -1
View File
@@ -28,7 +28,7 @@ be used for reading.
.AP int checkUsage in
If non-zero, then an error will be generated if the file was not opened
for the access indicated by \fIwrite\fR.
.AP void **filePtr out
.AP ClientData *filePtr out
Points to word in which to store pointer to FILE structure for
the file given by \fIchanID\fR.
.BE
+1 -1
View File
@@ -1,5 +1,5 @@
'\"
'\" Copyright (c) 1996 by Sun Microsystems, Inc.
'\" Copyright (c) 1996 Sun Microsystems, Inc.
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+5 -5
View File
@@ -1,5 +1,5 @@
'\"
'\" Copyright (c) 2001 by Kevin B. Kenny <kennykb@acm.org>.
'\" Copyright (c) 2001 Kevin B. Kenny <kennykb@acm.org>.
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
@@ -27,13 +27,13 @@ Pointer to handler function replacing \fBTcl_GetTime\fR's access to the OS.
.AP Tcl_ScaleTimeProc scaleProc in
Pointer to handler function for the conversion of time delays in the
virtual domain to real-time.
.AP void *clientData in
.AP ClientData clientData in
Value passed through to the two handler functions.
.AP Tcl_GetTimeProc *getProcPtr out
Pointer to place the currently registered get handler function into.
.AP Tcl_ScaleTimeProc *scaleProcPtr out
Pointer to place the currently registered scale handler function into.
.AP void **clientDataPtr out
.AP ClientData *clientDataPtr out
Pointer to place the currently registered pass-through value into.
.BE
.SH DESCRIPTION
@@ -83,10 +83,10 @@ The signatures of the handler functions are as follows:
.CS
typedef void \fBTcl_GetTimeProc\fR(
Tcl_Time *\fItimebuf\fR,
void *\fIclientData\fR);
ClientData \fIclientData\fR);
typedef void \fBTcl_ScaleTimeProc\fR(
Tcl_Time *\fItimebuf\fR,
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
The \fItimebuf\fR fields contain the time to manipulate, and the
+10 -4
View File
@@ -30,7 +30,7 @@ Tcl_HashEntry *
Tcl_HashEntry *
\fBTcl_FindHashEntry\fR(\fItablePtr, key\fR)
.sp
void *
ClientData
\fBTcl_GetHashValue\fR(\fIentryPtr\fR)
.sp
\fBTcl_SetHashValue\fR(\fIentryPtr, value\fR)
@@ -66,8 +66,9 @@ The word at \fI*newPtr\fR is set to 1 if a new entry was created
and 0 if there was already an entry for \fIkey\fR.
.AP Tcl_HashEntry *entryPtr in
Pointer to hash table entry.
.AP void *value in
New value to assign to hash table entry.
.AP ClientData value in
New value to assign to hash table entry. Need not have type
ClientData, but must fit in same space as ClientData.
.AP Tcl_HashSearch *searchPtr in
Pointer to record to use to keep track of progress in enumerating
all the entries in a hash table.
@@ -185,6 +186,11 @@ instead, it returns NULL as result.
.PP
\fBTcl_GetHashValue\fR and \fBTcl_SetHashValue\fR are used to
read and write an entry's value, respectively.
Values are stored and retrieved as type
.QW ClientData ,
which is
large enough to hold a pointer value. On almost all machines this is
large enough to hold an integer value too.
.PP
\fBTcl_GetHashKey\fR returns the key for a given hash table entry,
either as a pointer to a string, a one-word
@@ -223,7 +229,7 @@ overall information about a hash table, such as the number of
entries it contains, the number of buckets in its hash array,
and the utilization of the buckets.
It is the caller's responsibility to free the result string
by passing it to \fBTcl_Free\fR.
by passing it to \fBckfree\fR.
.PP
The header file \fBtcl.h\fR defines the actual data structures
used to implement hash tables.
+1 -1
View File
@@ -1,5 +1,5 @@
'\"
'\" Copyright (c) 1998-2000 by Scriptics Corporation.
'\" Copyright (c) 1998-2000 Scriptics Corporation.
'\" All rights reserved.
'\"
.TH Tcl_Init 3 8.0 Tcl "Tcl Library Procedures"
+3 -3
View File
@@ -63,9 +63,9 @@ Define the \fBUSE_TCL_STUBS\fR symbol. Typically, you would include the
\fB\-DUSE_TCL_STUBS\fR flag when compiling the extension.
.IP 3) 5
Link the extension with the Tcl stubs library instead of the standard
Tcl library. For example, to use the Tcl 9.0 ABI on Unix platforms,
the library name is \fIlibtclstub9.0.a\fR; on Windows platforms, the
library name is \fItclstub90.lib\fR.
Tcl library. For example, to use the Tcl 8.6 ABI on Unix platforms,
the library name is \fIlibtclstub8.6.a\fR; on Windows platforms, the
library name is \fItclstub86.lib\fR.
.PP
If the extension also requires the Tk API, it must also call
\fBTk_InitStubs\fR to initialize the Tk stubs interface and link
+2 -2
View File
@@ -23,9 +23,9 @@ first thing in the application's main program.
.PP
\fBTcl_InitSubsystems\fR is very similar in use to
\fBTcl_FindExecutable\fR. It can be used when Tcl is
used as utility library, no other encodings than utf-8,
used as utility library, no other encodings than utf8,
iso8859-1 or unicode are used, and no interest exists in the
value of \fBinfo nameofexecutable\fR. The system encoding will not
be extracted from the environment, but falls back to utf-8.
be extracted from the environment, but falls back to iso8859-1.
.SH KEYWORDS
binary, executable file
+1 -1
View File
@@ -102,7 +102,7 @@ are provided by the C language standard. The \fBTcl_WideInt\fR type is a
typedef defined to be whatever signed integral type covers at least the
64-bit integer range (-9223372036854775808 to 9223372036854775807). Depending
on the platform and the C compiler, the actual type might be
\fBlong long int\fR, \fB__int64\fR, or something else.
\fBlong long int\fR, or something else.
The \fBmp_int\fR type is a multiple-precision integer type defined
by the LibTomMath multiple-precision integer library.
.PP
+41
View File
@@ -0,0 +1,41 @@
'\"
'\" Copyright (c) 1989-1993 The Regents of the University of California.
'\" Copyright (c) 1994-1996 Sun Microsystems, Inc.
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
.TH Tcl_Interp 3 8.7 Tcl "Tcl Library Procedures"
.so man.macros
.BS
.SH NAME
Tcl_Interp \- client-visible fields of interpreter structures
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
.sp
typedef struct {
char *\fIresult\fR; /* NO LONGER AVAILABLE */
Tcl_FreeProc *\fIfreeProc\fR; /* NO LONGER AVAILABLE */
int \fIerrorLine\fR; /* NO LONGER AVAILABLE */
} \fBTcl_Interp\fR;
typedef void \fBTcl_FreeProc\fR(
char *\fIblockPtr\fR);
.BE
.SH DESCRIPTION
.PP
The \fBTcl_CreateInterp\fR procedure returns a pointer to a \fBTcl_Interp\fR
structure. Callers of \fBTcl_CreateInterp\fR should use this pointer
as an opaque token, suitable for nothing other than passing back to
other routines in the Tcl interface from the same thread that called
\fBTcl_CreateInterp\fR. The \fBTcl_Interp\fR struct no longer has any
supported client-visible fields. Supported public routines such as
\fBTcl_SetResult\fR, \fBTcl_GetResult\fR, \fBTcl_SetErrorLine\fR,
\fBTcl_GetErrorLine\fR must be used instead.
.PP
Any legacy programs and extensions trying to access the fields above
in their source code will need conversion to compile for Tcl 8.7 and later.
.SH KEYWORDS
interpreter, result
+3 -3
View File
@@ -83,7 +83,7 @@ the handler returns. Many handlers may be attached to the same
interpreter limit; their order of execution is not defined, and they
must be identified by \fIhandlerProc\fR and \fIclientData\fR when they
are deleted.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary pointer-sized word used to pass some context to the
\fIhandlerProc\fR function.
.AP Tcl_LimitHandlerDeleteProc *deleteProc in
@@ -162,7 +162,7 @@ following prototype:
.PP
.CS
typedef void \fBTcl_LimitHandlerProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR);
.CE
.PP
@@ -179,7 +179,7 @@ following prototype:
.PP
.CS
typedef void \fBTcl_LimitHandlerDeleteProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
A limit handler may be deleted using \fBTcl_LimitRemoveHandler\fR; the
+2 -2
View File
@@ -59,7 +59,7 @@ In \fBTcl_LinkArray\fR, the additional linked types \fBTCL_LINK_CHARS\fR and
All the above for both functions may be
optionally OR'ed with \fBTCL_LINK_READ_ONLY\fR to make the Tcl
variable read-only.
.AP size_t size in
.AP int size in
.VS "TIP 312"
The number of elements in the C array. Must be greater than zero.
.VE "TIP 312"
@@ -265,7 +265,7 @@ Tcl errors.
.
The C variable is of type \fBchar *\fR.
If its value is not NULL then it must be a pointer to a string
allocated with \fBTcl_Alloc\fR.
allocated with \fBTcl_Alloc\fR or \fBckalloc\fR.
Whenever the Tcl variable is modified the current C string will be
freed and new memory will be allocated to hold a copy of the variable's
new value.
+7 -7
View File
@@ -61,7 +61,7 @@ Tcl_Object
int
\fBTcl_ObjectContextSkippedArgs\fR(\fIcontext\fR)
.SH ARGUMENTS
.AS void *clientData in
.AS ClientData clientData in
.AP Tcl_Interp *interp in/out
The interpreter holding the object or class to create or update a method in.
.AP Tcl_Object object in
@@ -83,10 +83,10 @@ and \fBTCL_OO_METHOD_PRIVATE\fR for a private method.
.AP Tcl_MethodType *methodTypePtr in
A description of the type of the method to create, or the type of method to
compare against.
.AP void *clientData in
.AP ClientData clientData in
A piece of data that is passed to the implementation of the method without
interpretation.
.AP void **clientDataPtr out
.AP ClientData *clientDataPtr out
A pointer to a variable in which to write the \fIclientData\fR value supplied
when the method was created. If NULL, the \fIclientData\fR value will not be
retrieved.
@@ -213,7 +213,7 @@ Functions matching this signature are called when the method is invoked.
.PP
.CS
typedef int \fBTcl_MethodCallProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR,
Tcl_ObjectContext \fIobjectContext\fR,
int \fIobjc\fR,
@@ -234,7 +234,7 @@ through a new method being created or because the object or class is deleted.
.PP
.CS
typedef void \fBTcl_MethodDeleteProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
The \fIclientData\fR argument to a Tcl_MethodDeleteProc will be the same as
@@ -248,8 +248,8 @@ class is copied using \fBTcl_CopyObjectInstance\fR (or \fBoo::copy\fR).
.CS
typedef int \fBTcl_CloneProc\fR(
Tcl_Interp *\fIinterp\fR,
void *\fIoldClientData\fR,
void **\fInewClientDataPtr\fR);
ClientData \fIoldClientData\fR,
ClientData *\fInewClientDataPtr\fR);
.CE
.PP
The \fIinterp\fR argument gives a place to write an error message when the
+14 -14
View File
@@ -1,6 +1,6 @@
.\"
.\" Copyright (c) 2008 by Kevin B. Kenny.
.\" Copyright (c) 2018 by Nathan Coulter.
.\" Copyright (c) 2008 Kevin B. Kenny.
.\" Copyright (c) 2018 Nathan Coulter.
.\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
@@ -49,7 +49,7 @@ in the same way as the \fIproc\fR argument to \fBTcl_CreateObjCommand\fR(3)
(\fIq.v.\fR).
.AP Tcl_ObjCmdProc *nreProc in
Called instead of \fIproc\fR when a trampoline is already in use.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value passed to \fIproc\fR, \fInreProc\fR, \fIdeleteProc\fR
and \fIobjProc\fR.
.AP Tcl_CmdDeleteProc *deleteProc in/out
@@ -72,10 +72,10 @@ Pointer to an unshared Tcl_Obj where the result of the evaluation is stored if
the return code is TCL_OK.
.AP Tcl_NRPostProc *postProcPtr in
A function to push.
.AP void *data0 in
.AP void *data1 in
.AP void *data2 in
.AP void *data3 in
.AP ClientData data0 in
.AP ClientData data1 in
.AP ClientData data2 in
.AP ClientData data3 in
\fIdata0\fR through \fIdata3\fR are four one-word values that will be passed
to the function designated by \fIpostProcPtr\fR when it is invoked.
.BE
@@ -130,7 +130,7 @@ a message as the interpreter's result.
.CS
typedef int
\fBTcl_NRPostProc\fR(
\fBvoid *\fR \fIdata\fR[],
\fBClientData\fR \fIdata\fR[],
\fBTcl_Interp\fR *\fIinterp\fR,
int \fIresult\fR);
.CE
@@ -146,7 +146,7 @@ stack, to evalute a script:
.CS
int
\fITheCmdOldObjProc\fR(
void *clientData,
ClientData clientData,
Tcl_Interp *interp,
int objc,
Tcl_Obj *const objv[])
@@ -177,7 +177,7 @@ call \fITheCmdNRObjProc\fR:
.CS
int
\fITheCmdOldObjProc\fR(
void *clientData,
ClientData clientData,
Tcl_Interp *interp,
int objc,
Tcl_Obj *const objv[])
@@ -190,7 +190,7 @@ int
.CS
int
\fITheCmdNRObjProc\fR
void *clientData,
ClientData clientData,
Tcl_Interp *interp,
int objc,
Tcl_Obj *const objv[])
@@ -211,7 +211,7 @@ int
.CS
int
\fITheCmdNRPostProc\fR(
void *data[],
ClientData data[],
Tcl_Interp *interp,
int result)
{
@@ -232,5 +232,5 @@ Tcl_CreateCommand(3), Tcl_CreateObjCommand(3), Tcl_EvalObjEx(3), Tcl_GetCommandF
.SH KEYWORDS
stackless, nonrecursive, execute, command, global, value, result, script
.SH COPYRIGHT
Copyright (c) 2008 by Kevin B. Kenny.
Copyright (c) 2018 by Nathan Coulter.
Copyright \(co 2008 Kevin B. Kenny.
Copyright \(co 2018 Nathan Coulter.
+2 -2
View File
@@ -57,7 +57,7 @@ The interpreter in which the namespace exists and where name lookups
are performed. Also where error result messages are written.
.AP "const char" *name in
The name of the namespace or command to be created or accessed.
.AP void *clientData in
.AP ClientData clientData in
A context pointer by the creator of the namespace. Not interpreted by
Tcl at all.
.AP Tcl_NamespaceDeleteProc *deleteProc in
@@ -117,7 +117,7 @@ the global namespace.)
.PP
.CS
typedef void \fBTcl_NamespaceDeleteProc\fR(
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
\fBTcl_DeleteNamespace\fR deletes a namespace, calling the
+7 -7
View File
@@ -38,7 +38,7 @@ Tcl_ThreadId
void
\fBTcl_DeleteEvents\fR(\fIdeleteProc, clientData\fR)
.sp
void *
ClientData
\fBTcl_InitNotifier\fR()
.sp
void
@@ -78,7 +78,7 @@ Procedure to invoke to prepare for event wait in \fBTcl_DoOneEvent\fR.
Procedure for \fBTcl_DoOneEvent\fR to invoke after waiting for
events. Checks to see if any events have occurred and, if so,
queues them.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIsetupProc\fR, \fIcheckProc\fR, or
\fIdeleteProc\fR.
.AP "const Tcl_Time" *timePtr in
@@ -89,7 +89,7 @@ is NULL, it means there is no maximum wait time: wait forever if
necessary.
.AP Tcl_Event *evPtr in
An event to add to the event queue. The storage for the event must
have been allocated by the caller using \fBTcl_Alloc\fR.
have been allocated by the caller using \fBTcl_Alloc\fR or \fBckalloc\fR.
.AP Tcl_QueuePosition position in
Where to add the new event in the queue: \fBTCL_QUEUE_TAIL\fR,
\fBTCL_QUEUE_HEAD\fR, or \fBTCL_QUEUE_MARK\fR.
@@ -225,7 +225,7 @@ the event source.
.PP
.CS
typedef void \fBTcl_EventSetupProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
int \fIflags\fR);
.CE
.PP
@@ -303,7 +303,7 @@ following prototype:
.PP
.CS
typedef void \fBTcl_EventCheckProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
int \fIflags\fR);
.CE
.PP
@@ -394,7 +394,7 @@ of window events.
When \fIproc\fR returns 1, \fBTcl_ServiceEvent\fR will remove the
event from the event queue and free its storage.
Note that the storage for an event must be allocated by
the event source (using \fBTcl_Alloc\fR)
the event source (using \fBTcl_Alloc\fR or the Tcl macro \fBckalloc\fR)
before calling \fBTcl_QueueEvent\fR, but it
will be freed by \fBTcl_ServiceEvent\fR, not by the event source.
.PP
@@ -419,7 +419,7 @@ queue. \fIProc\fR should match the following prototype:
.CS
typedef int \fBTcl_EventDeleteProc\fR(
Tcl_Event *\fIevPtr\fR,
void *\fIclientData\fR);
ClientData \fIclientData\fR);
.CE
.PP
The \fIclientData\fR argument will be the same as the \fIclientData\fR
+2 -2
View File
@@ -111,9 +111,9 @@ which is defined as follows.
.PP
.CS
typedef struct Tcl_Obj {
size_t \fIrefCount\fR;
int \fIrefCount\fR;
char *\fIbytes\fR;
size_t \fIlength\fR;
int \fIlength\fR;
const Tcl_ObjType *\fItypePtr\fR;
union {
long \fIlongValue\fR;
+2 -2
View File
@@ -184,8 +184,8 @@ to be treated as conventional null character-terminated C strings.
These restrictions are easily met by using Tcl's internal UTF encoding
for the string representation, same as one would do for other
Tcl routines accepting string values as arguments.
Storage for the byte array must be allocated in the heap by \fBTcl_Alloc\fR.
Note that \fIupdateStringProc\fRs must allocate
Storage for the byte array must be allocated in the heap by \fBTcl_Alloc\fR
or \fBckalloc\fR. Note that \fIupdateStringProc\fRs must allocate
enough storage for the string's bytes and the terminating null byte.
.PP
The \fIupdateStringProc\fR for Tcl's built-in double type, for example,
+17 -17
View File
@@ -53,28 +53,28 @@ int
int
\fBTcl_Read\fR(\fIchannel, readBuf, bytesToRead\fR)
.sp
size_t
int
\fBTcl_GetsObj\fR(\fIchannel, lineObjPtr\fR)
.sp
size_t
int
\fBTcl_Gets\fR(\fIchannel, lineRead\fR)
.sp
size_t
int
\fBTcl_Ungets\fR(\fIchannel, input, inputLen, addAtEnd\fR)
.sp
size_t
int
\fBTcl_WriteObj\fR(\fIchannel, writeObjPtr\fR)
.sp
size_t
int
\fBTcl_WriteChars\fR(\fIchannel, charBuf, bytesToWrite\fR)
.sp
size_t
int
\fBTcl_Write\fR(\fIchannel, byteBuf, bytesToWrite\fR)
.sp
size_t
int
\fBTcl_ReadRaw\fR(\fIchannel, readBuf, bytesToRead\fR)
.sp
size_t
int
\fBTcl_WriteRaw\fR(\fIchannel, byteBuf, bytesToWrite\fR)
.sp
int
@@ -92,10 +92,10 @@ int
int
\fBTcl_OutputBuffered\fR(\fIchannel\fR)
.sp
Tcl_WideInt
long long
\fBTcl_Seek\fR(\fIchannel, offset, seekMode\fR)
.sp
Tcl_WideInt
long long
\fBTcl_Tell\fR(\fIchannel\fR)
.sp
int
@@ -134,7 +134,7 @@ input of the invoking process; likewise for \fBTCL_STDOUT\fR and
redirect stdio handles to override the stdio handles for which
\fBTCL_STDIN\fR, \fBTCL_STDOUT\fR and \fBTCL_STDERR\fR have been set. If it
is set, then such redirections cause an error.
.AP void *handle in
.AP ClientData handle in
Operating system specific handle for I/O to a file. For Unix this is a
file descriptor, for Windows it is a HANDLE.
.AP int readOrWrite in
@@ -154,7 +154,7 @@ from a procedure such as \fBTcl_OpenFileChannel\fR.
.AP Tcl_Obj *readObjPtr in/out
A pointer to a Tcl value in which to store the characters read from the
channel.
.AP size_t charsToRead in
.AP int charsToRead in
The number of characters to read from the channel. If the channel's encoding
is \fBbinary\fR, this is equivalent to the number of bytes to read from the
channel.
@@ -163,7 +163,7 @@ If non-zero, data read from the channel will be appended to the value.
Otherwise, the data will replace the existing contents of the value.
.AP char *readBuf out
A buffer in which to store the bytes read from the channel.
.AP size_t bytesToRead in
.AP int bytesToRead in
The number of bytes to read from the channel. The buffer \fIreadBuf\fR must
be large enough to hold this many bytes.
.AP Tcl_Obj *lineObjPtr in/out
@@ -176,7 +176,7 @@ channel. Must have been initialized by the caller. The line read will be
appended to any data already in the dynamic string.
.AP "const char" *input in
The input to add to a channel buffer.
.AP size_t inputLen in
.AP int inputLen in
Length of the input
.AP int addAtEnd in
Flag indicating whether the input should be added to the end or
@@ -187,10 +187,10 @@ A pointer to a Tcl value whose contents will be output to the channel.
A buffer containing the characters to output to the channel.
.AP "const char" *byteBuf in
A buffer containing the bytes to output to the channel.
.AP size_t bytesToWrite in
.AP int bytesToWrite in
The number of bytes to consume from \fIcharBuf\fR or \fIbyteBuf\fR and
output to the channel.
.AP Tcl_WideInt offset in
.AP "long long" offset in
How far to move the access point in the channel at which the next input or
output operation will be applied, measured in bytes from the position
given by \fIseekMode\fR. May be either positive or negative.
@@ -198,7 +198,7 @@ given by \fIseekMode\fR. May be either positive or negative.
Relative to which point to seek; used with \fIoffset\fR to calculate the new
access point for the channel. Legal values are \fBSEEK_SET\fR,
\fBSEEK_CUR\fR, and \fBSEEK_END\fR.
.AP Tcl_WideInt length in
.AP "long long" length in
The (non-negative) length to truncate the channel the channel to.
.AP "const char" *optionName in
The name of an option applicable to this channel, such as \fB\-blocking\fR.
+3 -3
View File
@@ -50,12 +50,12 @@ If nonzero, the client socket is connected asynchronously to the server.
.AP "unsigned int" flags in
ORed combination of \fBTCL_TCPSERVER\fR flags that specify additional
informations about the socket being created.
.AP void *sock in
.AP ClientData sock in
Platform-specific handle for client TCP socket.
.AP Tcl_TcpAcceptProc *proc in
Pointer to a procedure to invoke each time a new connection is
accepted via the socket.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR.
.BE
.SH DESCRIPTION
@@ -127,7 +127,7 @@ the channel. \fIProc\fR must match the following prototype:
.PP
.CS
typedef void \fBTcl_TcpAcceptProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Channel \fIchannel\fR,
char *\fIhostName\fR,
int \fIport\fR);
+10 -3
View File
@@ -7,7 +7,7 @@
.BS
'\" Note: do not modify the .SH NAME line immediately below!
.SH NAME
Tcl_Panic, Tcl_SetPanicProc, Tcl_ConsolePanic \- report fatal error and abort
Tcl_Panic, Tcl_PanicVA, Tcl_SetPanicProc, Tcl_ConsolePanic \- report fatal error and abort
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
@@ -16,6 +16,9 @@ void
\fBTcl_Panic\fR(\fIformat\fR, \fIarg\fR, \fIarg\fR, \fI...\fR)
.sp
void
\fBTcl_PanicVA\fR(\fIformat\fR, \fIargList\fR)
.sp
void
\fBTcl_SetPanicProc\fR(\fIpanicProc\fR)
.sp
void
@@ -83,8 +86,8 @@ The typical use of \fBTcl_SetPanicProc\fR arranges for the error message
to be displayed or reported in a manner more suitable for the
application or the platform.
.PP
\fBTcl_SetPanicProc\fR can not be used safely by stub-enabled extensions, so its
symbol is not included in the stub table.
\fBTcl_SetPanicProc\fR can not be used in stub-enabled extensions. Its symbol
entry in the stub table is deprecated and it will be removed in Tcl 9.0.
.PP
Although the primary callers of \fBTcl_Panic\fR are the procedures of
the Tcl library, \fBTcl_Panic\fR is a public function and may be called
@@ -92,6 +95,10 @@ by any extension or application that wishes to abort the process and
have a panic message displayed the same way that panic messages from Tcl
will be displayed.
.PP
\fBTcl_PanicVA\fR is the same as \fBTcl_Panic\fR except that instead of
taking a variable number of arguments it takes an argument list. Interfaces
using argument lists have been found to be nonportable in practice. This
function is deprecated and will be removed in Tcl 9.0.
.SH "SEE ALSO"
abort(3), printf(3), exec(n), format(n)
.SH KEYWORDS
+4 -4
View File
@@ -31,7 +31,7 @@ The array of arguments to be parsed.
Pointer to a variable that will hold the array of unprocessed arguments.
Should be NULL if no return of unprocessed arguments is required. If
\fIobjcPtr\fR is updated to a non-zero value, the array returned through this
must be deallocated using \fBTcl_Free\fR.
must be deallocated using \fBckfree\fR.
.BE
.SH DESCRIPTION
.PP
@@ -84,7 +84,7 @@ typedef struct {
void *\fIsrcPtr\fR;
void *\fIdstPtr\fR;
const char *\fIhelpStr\fR;
void *\fIclientData\fR;
ClientData \fIclientData\fR;
} \fBTcl_ArgvInfo\fR;
.CE
.PP
@@ -127,7 +127,7 @@ have the following signature:
.PP
.CS
typedef int (\fBTcl_ArgvFuncProc\fR)(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Obj *\fIobjPtr\fR,
void *\fIdstPtr\fR);
.CE
@@ -149,7 +149,7 @@ function will have the following signature:
.PP
.CS
typedef int (\fBTcl_ArgvGenFuncProc\fR)(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR,
int \fIobjc\fR,
Tcl_Obj *const *\fIobjv\fR,
+21 -7
View File
@@ -8,7 +8,7 @@
.so man.macros
.BS
.SH NAME
Tcl_ParseCommand, Tcl_ParseExpr, Tcl_ParseBraces, Tcl_ParseQuotedString, Tcl_ParseVarName, Tcl_ParseVar, Tcl_FreeParse, Tcl_EvalTokensStandard \- parse Tcl scripts and expressions
Tcl_ParseCommand, Tcl_ParseExpr, Tcl_ParseBraces, Tcl_ParseQuotedString, Tcl_ParseVarName, Tcl_ParseVar, Tcl_FreeParse, Tcl_EvalTokens, Tcl_EvalTokensStandard \- parse Tcl scripts and expressions
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
@@ -33,16 +33,20 @@ const char *
.sp
\fBTcl_FreeParse\fR(\fIusedParsePtr\fR)
.sp
Tcl_Obj *
\fBTcl_EvalTokens\fR(\fIinterp, tokenPtr, numTokens\fR)
.sp
int
\fBTcl_EvalTokensStandard\fR(\fIinterp, tokenPtr, numTokens\fR)
.SH ARGUMENTS
.AS Tcl_Interp *usedParsePtr out
.AP Tcl_Interp *interp out
For procedures other than \fBTcl_FreeParse\fR and
\fBTcl_EvalTokensStandard\fR, used only for error reporting;
For procedures other than \fBTcl_FreeParse\fR, \fBTcl_EvalTokens\fR
and \fBTcl_EvalTokensStandard\fR, used only for error reporting;
if NULL, then no error messages are left after errors.
For \fBTcl_EvalTokensStandard\fR, determines the context for evaluating
the script and also is used for error reporting; must not be NULL.
For \fBTcl_EvalTokens\fR and \fBTcl_EvalTokensStandard\fR,
determines the context for evaluating the
script and also is used for error reporting; must not be NULL.
.AP "const char" *start in
Pointer to first character in string to parse.
.AP int numBytes in
@@ -187,6 +191,16 @@ code with one of the values \fBTCL_OK\fR, \fBTCL_ERROR\fR,
some other integer value originating in an extension.
In addition, a result value or error message is left in \fIinterp\fR's
result; it can be retrieved using \fBTcl_GetObjResult\fR.
.PP
\fBTcl_EvalTokens\fR differs from \fBTcl_EvalTokensStandard\fR only in
the return convention used: it returns the result in a new Tcl_Obj.
The reference count of the value returned as result has been
incremented, so the caller must
invoke \fBTcl_DecrRefCount\fR when it is finished with the value.
If an error or other exception occurs while evaluating the tokens
(such as a reference to a non-existent variable) then the return value
is NULL and an error message is left in \fIinterp\fR's result. The use
of \fBTcl_EvalTokens\fR is deprecated.
.SH "TCL_PARSE STRUCTURE"
.PP
\fBTcl_ParseCommand\fR, \fBTcl_ParseExpr\fR, \fBTcl_ParseBraces\fR,
@@ -208,8 +222,8 @@ typedef struct Tcl_Parse {
typedef struct Tcl_Token {
int \fItype\fR;
const char *\fIstart\fR;
size_t \fIsize\fR;
size_t \fInumComponents\fR;
int \fIsize\fR;
int \fInumComponents\fR;
} \fBTcl_Token\fR;
.CE
.PP
+1 -1
View File
@@ -94,4 +94,4 @@ compatibility and translate their invocations to this form.
.SH KEYWORDS
package, present, provide, require, version
.SH "SEE ALSO"
package(n), Tcl_StaticPackage(3)
package(n), Tcl_StaticLibrary(3)
+2 -2
View File
@@ -21,7 +21,7 @@ Tcl_Preserve, Tcl_Release, Tcl_EventuallyFree \- avoid freeing storage while it
\fBTcl_EventuallyFree\fR(\fIclientData, freeProc\fR)
.SH ARGUMENTS
.AS Tcl_FreeProc clientData
.AP void *clientData in
.AP ClientData clientData in
Token describing structure to be freed or reallocated. Usually a pointer
to memory for structure.
.AP Tcl_FreeProc *freeProc in
@@ -91,7 +91,7 @@ reasons, but the value is the same.
.PP
When the \fIclientData\fR argument to \fBTcl_EventuallyFree\fR
refers to storage allocated and returned by a prior call to
\fBTcl_Alloc\fR or another function of the Tcl library,
\fBTcl_Alloc\fR, \fBckalloc\fR, or another function of the Tcl library,
then the \fIfreeProc\fR argument should be given the special value of
\fBTCL_DYNAMIC\fR.
.PP
+7 -2
View File
@@ -18,7 +18,10 @@ Tcl_PrintDouble \- Convert floating value to string
.SH ARGUMENTS
.AS Tcl_Interp *interp out
.AP Tcl_Interp *interp in
This argument is ignored.
Before Tcl 8.0, the \fBtcl_precision\fR variable in this interpreter
controlled the conversion. As of Tcl 8.0, this argument is ignored and
the conversion is controlled by the \fBtcl_precision\fR variable
that is now shared by all interpreters.
.AP double value in
Floating-point value to be converted.
.AP char *dst out
@@ -38,7 +41,9 @@ so that it does not look like an integer. Where \fB%g\fR would
generate an integer with no decimal point, \fBTcl_PrintDouble\fR adds
.QW .0 .
.PP
The result will have the fewest digits needed to
If the \fBtcl_precision\fR value is non-zero, the result will have
precisely that many digits of significance. If the value is zero
(the default), the result will have the fewest digits needed to
represent the number in such a way that \fBTcl_NewDoubleObj\fR
will generate the same number when presented with the given string.
IEEE semantics of rounding to even apply to the conversion.
+1 -1
View File
@@ -31,7 +31,7 @@ the command at global level instead of the current stack level.
.SH DESCRIPTION
.PP
\fBTcl_RecordAndEvalObj\fR is invoked to record a command as an event
on the history list and then execute it using \fBTcl_EvalObjEx\fR.
on the history list and then execute it using \fBTcl_EvalObjEx\fR
It returns a completion code such as \fBTCL_OK\fR just like \fBTcl_EvalObjEx\fR,
as well as a result value containing additional information
(a result value or error message)
+4 -4
View File
@@ -28,7 +28,7 @@ configuration as ASCII string. This means that this information is in
UTF-8 too. Must not be NULL.
.AP "const Tcl_Config" *configuration in
Refers to an array of Tcl_Config entries containing the information
embedded in the binary library. Must not be NULL. The end of the array
embedded in the library. Must not be NULL. The end of the array
is signaled by either a key identical to NULL, or a key referring to
the empty string.
.AP "const char" *valEncoding in
@@ -40,10 +40,10 @@ too. Must not be NULL.
.PP
The function described here has its base in TIP 59 and provides
extensions with support for the embedding of configuration
information into their binary library and the generation of a
information into their library and the generation of a
Tcl-level interface for querying this information.
.PP
To embed configuration information into their binary library an
To embed configuration information into their library an
extension has to define a non-volatile array of Tcl_Config entries in
one if its source files and then call \fBTcl_RegisterConfig\fR to
register that information.
@@ -108,4 +108,4 @@ typedef struct Tcl_Config {
.\" No cross references yet.
.\" .SH "SEE ALSO"
.SH KEYWORDS
embedding, configuration, binary library
embedding, configuration, library
+8 -8
View File
@@ -64,7 +64,7 @@ identifies the beginning of the larger string.
If it is not the same as \fItext\fR, then no
.QW \fB^\fR
matches will be allowed.
.AP size_t index in
.AP int index in
Specifies which range is desired: 0 means the range of the entire
match, 1 or greater means the range that matched a parenthesized
sub-expression.
@@ -80,14 +80,14 @@ OR-ed combination of the compilation flags \fBTCL_REG_ADVANCED\fR,
\fBTCL_REG_QUOTE\fR, \fBTCL_REG_NOCASE\fR, \fBTCL_REG_NEWLINE\fR,
\fBTCL_REG_NLSTOP\fR, \fBTCL_REG_NLANCH\fR, \fBTCL_REG_NOSUB\fR, and
\fBTCL_REG_CANMATCH\fR. See below for more information.
.AP size_t offset in
.AP int offset in
The character offset into the text where matching should begin.
The value of the offset has no impact on \fB^\fR matches. This
behavior is controlled by \fIeflags\fR.
.AP size_t nmatches in
.AP int nmatches in
The number of matching subexpressions that should be remembered for
later use. If this value is 0, then no subexpression match
information will be computed. If the value is TCL_INDEX_NONE, then
information will be computed. If the value is \-1, then
all of the matching subexpressions will be remembered. Any other
value will be taken as the maximum number of subexpressions to
remember.
@@ -337,9 +337,9 @@ defined as follows:
.PP
.CS
typedef struct Tcl_RegExpInfo {
size_t \fInsubs\fR;
int \fInsubs\fR;
Tcl_RegExpIndices *\fImatches\fR;
size_t \fIextendStart\fR;
long \fIextendStart\fR;
} \fBTcl_RegExpInfo\fR;
.CE
.PP
@@ -355,8 +355,8 @@ follows:
.PP
.CS
typedef struct Tcl_RegExpIndices {
size_t \fIstart\fR;
size_t \fIend\fR;
long \fIstart\fR;
long \fIend\fR;
} \fBTcl_RegExpIndices\fR;
.CE
.PP
+1 -1
View File
@@ -1,5 +1,5 @@
'\"
'\" Copyright (c) 1997 by Sun Microsystems, Inc.
'\" Copyright (c) 1997 Sun Microsystems, Inc.
'\" Contributions from Don Porter, NIST, 2004. (not subject to US copyright)
'\" Copyright (c) 2018 Nathan Coulter.
'\"
+4
View File
@@ -87,10 +87,14 @@ the value.
Which functions of a channel driver are allowed to use which bypass function
is listed below, as is which functions of the public channel API may leave a
messages in the bypass areas.
.IP \fBTcl_DriverCloseProc\fR
May use \fBTcl_SetChannelErrorInterp\fR, and only this function.
.IP \fBTcl_DriverInputProc\fR
May use \fBTcl_SetChannelError\fR, and only this function.
.IP \fBTcl_DriverOutputProc\fR
May use \fBTcl_SetChannelError\fR, and only this function.
.IP \fBTcl_DriverSeekProc\fR
May use \fBTcl_SetChannelError\fR, and only this function.
.IP \fBTcl_DriverWideSeekProc\fR
May use \fBTcl_SetChannelError\fR, and only this function.
.IP \fBTcl_DriverSetOptionProc\fR
+1 -1
View File
@@ -29,7 +29,7 @@ New limit for nested calls to \fBTcl_Eval\fR for \fIinterp\fR.
.PP
At any given time Tcl enforces a limit on the number of recursive
calls that may be active for \fBTcl_Eval\fR and related procedures
such as \fBTcl_EvalEx\fR.
such as \fBTcl_GlobalEval\fR.
Any call to \fBTcl_Eval\fR that exceeds this depth is aborted with
an error.
By default the recursion limit is 1000.
+26 -1
View File
@@ -9,7 +9,7 @@
.so man.macros
.BS
.SH NAME
Tcl_SetObjResult, Tcl_GetObjResult, Tcl_SetResult, Tcl_GetStringResult, Tcl_AppendResult, Tcl_AppendElement, Tcl_ResetResult, Tcl_TransferResult \- manipulate Tcl result
Tcl_SetObjResult, Tcl_GetObjResult, Tcl_SetResult, Tcl_GetStringResult, Tcl_AppendResult, Tcl_AppendResultVA, Tcl_AppendElement, Tcl_ResetResult, Tcl_TransferResult, Tcl_FreeResult \- manipulate Tcl result
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
@@ -26,11 +26,15 @@ const char *
.sp
\fBTcl_AppendResult\fR(\fIinterp, result, result, ... , \fB(char *) NULL\fR)
.sp
\fBTcl_AppendResultVA\fR(\fIinterp, argList\fR)
.sp
\fBTcl_ResetResult\fR(\fIinterp\fR)
.sp
\fBTcl_TransferResult\fR(\fIsourceInterp, code, targetInterp\fR)
.sp
\fBTcl_AppendElement\fR(\fIinterp, element\fR)
.sp
\fBTcl_FreeResult\fR(\fIinterp\fR)
.SH ARGUMENTS
.AS Tcl_FreeProc sourceInterp out
.AP Tcl_Interp *interp out
@@ -139,6 +143,11 @@ extensions.
Any number of \fIresult\fR arguments may be passed in a single
call; the last argument in the list must be a NULL pointer.
.PP
\fBTcl_AppendResultVA\fR is the same as \fBTcl_AppendResult\fR except that
instead of taking a variable number of arguments it takes an argument list.
Interfaces using argument lists have been found to be nonportable in practice.
This function is deprecated and will be removed in Tcl 9.0.
.PP
\fBTcl_TransferResult\fR transfers interpreter state from \fIsourceInterp\fR
to \fItargetInterp\fR. The two interpreters must have been created in the
same thread. If \fIsourceInterp\fR and \fItargetInterp\fR are the same,
@@ -175,6 +184,22 @@ single character
or ends in the characters
.QW " {" )
then no space is added.
.PP
\fBTcl_FreeResult\fR performs part of the work
of \fBTcl_ResetResult\fR.
It frees up the memory associated with \fIinterp\fR's result.
It also sets \fIinterp->freeProc\fR to zero, but does not
change \fIinterp->result\fR or clear error state.
\fBTcl_FreeResult\fR is most commonly used when a procedure
is about to replace one result value with another.
.SS "DIRECT ACCESS TO INTERP->RESULT"
.PP
It used to be legal for programs to
directly read and write \fIinterp->result\fR
to manipulate the interpreter result. The Tcl headers no longer
permit this access. C code still doing this must
be updated to use supported routines \fBTcl_GetObjResult\fR,
\fBTcl_GetStringResult\fR, \fBTcl_SetObjResult\fR, and \fBTcl_SetResult\fR.
.SH "THE TCL_FREEPROC ARGUMENT TO TCL_SETRESULT"
.PP
\fBTcl_SetResult\fR's \fIfreeProc\fR argument specifies how
+1 -1
View File
@@ -1,5 +1,5 @@
'\"
'\" Copyright (c) 1998-2000 by Scriptics Corporation.
'\" Copyright (c) 1998-2000 Scriptics Corporation.
'\" All rights reserved.
'\"
.TH Tcl_SourceRCFile 3 8.3 Tcl "Tcl Library Procedures"
+5 -5
View File
@@ -20,16 +20,16 @@ int
char *
\fBTcl_Merge\fR(\fIargc, argv\fR)
.sp
size_t
int
\fBTcl_ScanElement\fR(\fIsrc, flagsPtr\fR)
.sp
size_t
int
\fBTcl_ScanCountedElement\fR(\fIsrc, length, flagsPtr\fR)
.sp
size_t
int
\fBTcl_ConvertElement\fR(\fIsrc, dst, flags\fR)
.sp
size_t
int
\fBTcl_ConvertCountedElement\fR(\fIsrc, length, dst, flags\fR)
.SH ARGUMENTS
.AS "const char *const" ***argvPtr out
@@ -55,7 +55,7 @@ String that is to become an element of a list.
.AP int *flagsPtr in
Pointer to word to fill in with information about \fIsrc\fR.
The value of *\fIflagsPtr\fR must be passed to \fBTcl_ConvertElement\fR.
.AP size_t length in
.AP int length in
Number of bytes in string \fIsrc\fR.
.AP char *dst in
Place to copy converted list element. Must contain enough characters
+78
View File
@@ -0,0 +1,78 @@
'\"
'\" Copyright (c) 1995-1996 Sun Microsystems, Inc.
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
.TH Tcl_StaticLibrary 3 7.5 Tcl "Tcl Library Procedures"
.so man.macros
.BS
.SH NAME
Tcl_StaticLibrary, Tcl_StaticPackage \- make a statically linked library available via the 'load' command
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
.sp
\fBTcl_StaticLibrary\fR(\fIinterp, prefix, initProc, safeInitProc\fR)
.sp
\fBTcl_StaticPackage\fR(\fIinterp, prefix, initProc, safeInitProc\fR)
.SH ARGUMENTS
.AS Tcl_LibraryInitProc *safeInitProc
.AP Tcl_Interp *interp in
If not NULL, points to an interpreter into which the library has
already been incorporated (i.e., the caller has already invoked the
appropriate initialization procedure). NULL means the library
has not yet been incorporated into any interpreter.
.AP "const char" *prefix in
Prefix for library initialization function; should be properly
capitalized (first letter upper-case, all others lower-case).
.AP Tcl_LibraryInitProc *initProc in
Procedure to invoke to incorporate this library into a trusted
interpreter.
.AP Tcl_LibraryInitProc *safeInitProc in
Procedure to call to incorporate this library into a safe interpreter
(one that will execute untrusted scripts). NULL means the library
cannot be used in safe interpreters.
.BE
.SH DESCRIPTION
.PP
This procedure may be invoked to announce that a library has been
linked statically with a Tcl application and, optionally, that it
has already been incorporated into an interpreter.
Once \fBTcl_StaticLibrary\fR has been invoked for a library, it
may be incorporated into interpreters using the \fBload\fR command.
\fBTcl_StaticLibrary\fR is normally invoked only by the \fBTcl_AppInit\fR
procedure for the application, not by libraries for themselves
(\fBTcl_StaticLibrary\fR should only be invoked for statically
linked libraries, and code in the library itself should not need
to know whether the library is dynamically loaded or statically linked).
.PP
When the \fBload\fR command is used later to incorporate the library into
an interpreter, one of \fIinitProc\fR and \fIsafeInitProc\fR will
be invoked, depending on whether the target interpreter is safe
or not.
\fIinitProc\fR and \fIsafeInitProc\fR must both match the
following prototype:
.PP
.CS
typedef int \fBTcl_LibraryInitProc\fR(
Tcl_Interp *\fIinterp\fR);
.CE
.PP
The \fIinterp\fR argument identifies the interpreter in which the library
is to be incorporated. The initialization procedure must return \fBTCL_OK\fR or
\fBTCL_ERROR\fR to indicate whether or not it completed successfully; in
the event of an error it should set the interpreter's result to point to an
error message. The result or error from the initialization procedure will
be returned as the result of the \fBload\fR command that caused the
initialization procedure to be invoked.
.PP
\fBTcl_StaticLibrary\fR was named \fBTcl_StaticPackage\fR in Tcl 8.6 and
earlier, but the old name is deprecated now.
.PP
\fBTcl_StaticLibrary\fR can not be used in stub-enabled extensions. Its symbol
entry in the stub table is deprecated and it will be removed in Tcl 9.0.
.SH KEYWORDS
initialization procedure, package, static linking
.SH "SEE ALSO"
load(n), package(n), Tcl_PkgRequire(3)
-73
View File
@@ -1,73 +0,0 @@
'\"
'\" Copyright (c) 1995-1996 Sun Microsystems, Inc.
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
.TH Tcl_StaticPackage 3 7.5 Tcl "Tcl Library Procedures"
.so man.macros
.BS
.SH NAME
Tcl_StaticPackage \- make a statically linked package available via the 'load' command
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
.sp
\fBTcl_StaticPackage\fR(\fIinterp, pkgName, initProc, safeInitProc\fR)
.SH ARGUMENTS
.AS Tcl_PackageInitProc *safeInitProc
.AP Tcl_Interp *interp in
If not NULL, points to an interpreter into which the package has
already been loaded (i.e., the caller has already invoked the
appropriate initialization procedure). NULL means the package
has not yet been incorporated into any interpreter.
.AP "const char" *pkgName in
Name of the package; should be properly capitalized (first letter
upper-case, all others lower-case).
.AP Tcl_PackageInitProc *initProc in
Procedure to invoke to incorporate this package into a trusted
interpreter.
.AP Tcl_PackageInitProc *safeInitProc in
Procedure to call to incorporate this package into a safe interpreter
(one that will execute untrusted scripts). NULL means the package
cannot be used in safe interpreters.
.BE
.SH DESCRIPTION
.PP
This procedure may be invoked to announce that a package has been
linked statically with a Tcl application and, optionally, that it
has already been loaded into an interpreter.
Once \fBTcl_StaticPackage\fR has been invoked for a package, it
may be loaded into interpreters using the \fBload\fR command.
\fBTcl_StaticPackage\fR is normally invoked only by the \fBTcl_AppInit\fR
procedure for the application, not by packages for themselves
(\fBTcl_StaticPackage\fR should only be invoked for statically
loaded packages, and code in the package itself should not need
to know whether the package is dynamically or statically loaded).
.PP
When the \fBload\fR command is used later to load the package into
an interpreter, one of \fIinitProc\fR and \fIsafeInitProc\fR will
be invoked, depending on whether the target interpreter is safe
or not.
\fIinitProc\fR and \fIsafeInitProc\fR must both match the
following prototype:
.PP
.CS
typedef int \fBTcl_PackageInitProc\fR(
Tcl_Interp *\fIinterp\fR);
.CE
.PP
The \fIinterp\fR argument identifies the interpreter in which the package
is to be loaded. The initialization procedure must return \fBTCL_OK\fR or
\fBTCL_ERROR\fR to indicate whether or not it completed successfully; in
the event of an error it should set the interpreter's result to point to an
error message. The result or error from the initialization procedure will
be returned as the result of the \fBload\fR command that caused the
initialization procedure to be invoked.
.PP
\fBTcl_StaticPackage\fR can not be safely used by stub-enabled extensions,
so its symbol is not included in the stub table.
.SH KEYWORDS
initialization procedure, package, static linking
.SH "SEE ALSO"
load(n), package(n), Tcl_PkgRequire(3)
+1 -1
View File
@@ -1,5 +1,5 @@
'\"
'\" Copyright (c) 2001 by ActiveState Corporation
'\" Copyright (c) 2001 ActiveState Corporation
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+23 -14
View File
@@ -8,7 +8,7 @@
.so man.macros
.BS
.SH NAME
Tcl_NewStringObj, Tcl_NewUnicodeObj, Tcl_SetStringObj, Tcl_SetUnicodeObj, Tcl_GetStringFromObj, Tcl_GetString, Tcl_GetUnicodeFromObj, Tcl_GetUnicode, Tcl_GetUniChar, Tcl_GetCharLength, Tcl_GetRange, Tcl_AppendToObj, Tcl_AppendUnicodeToObj, Tcl_AppendObjToObj, Tcl_AppendStringsToObj, Tcl_AppendLimitedToObj, Tcl_Format, Tcl_AppendFormatToObj, Tcl_ObjPrintf, Tcl_AppendPrintfToObj, Tcl_SetObjLength, Tcl_AttemptSetObjLength, Tcl_ConcatObj \- manipulate Tcl values as strings
Tcl_NewStringObj, Tcl_NewUnicodeObj, Tcl_SetStringObj, Tcl_SetUnicodeObj, Tcl_GetStringFromObj, Tcl_GetString, Tcl_GetUnicodeFromObj, Tcl_GetUnicode, Tcl_GetUniChar, Tcl_GetCharLength, Tcl_GetRange, Tcl_AppendToObj, Tcl_AppendUnicodeToObj, Tcl_AppendObjToObj, Tcl_AppendStringsToObj, Tcl_AppendStringsToObjVA, Tcl_AppendLimitedToObj, Tcl_Format, Tcl_AppendFormatToObj, Tcl_ObjPrintf, Tcl_AppendPrintfToObj, Tcl_SetObjLength, Tcl_AttemptSetObjLength, Tcl_ConcatObj \- manipulate Tcl values as strings
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
@@ -59,6 +59,9 @@ void
\fBTcl_AppendStringsToObj\fR(\fIobjPtr, string, string, ... \fB(char *) NULL\fR)
.sp
void
\fBTcl_AppendStringsToObjVA\fR(\fIobjPtr, argList\fR)
.sp
void
\fBTcl_AppendLimitedToObj\fR(\fIobjPtr, bytes, length, limit, ellipsis\fR)
.sp
Tcl_Obj *
@@ -87,44 +90,44 @@ Tcl_Obj *
Points to the first byte of an array of UTF-8-encoded bytes
used to set or append to a string value.
This byte array may contain embedded null characters
unless \fInumChars\fR is TCL_INDEX_NONE. (Applications needing null bytes
unless \fInumChars\fR is negative. (Applications needing null bytes
should represent them as the two-byte sequence \fI\e300\e200\fR, use
\fBTcl_ExternalToUtf\fR to convert, or \fBTcl_NewByteArrayObj\fR if
the string is a collection of uninterpreted bytes.)
.AP size_t length in
.AP int length in
The number of bytes to copy from \fIbytes\fR when
initializing, setting, or appending to a string value.
If TCL_INDEX_NONE, all bytes up to the first null are used.
If negative, all bytes up to the first null are used.
.AP "const Tcl_UniChar" *unicode in
Points to the first byte of an array of Unicode characters
used to set or append to a string value.
This byte array may contain embedded null characters
unless \fInumChars\fR is negative.
.AP size_t numChars in
.AP int numChars in
The number of Unicode characters to copy from \fIunicode\fR when
initializing, setting, or appending to a string value.
If TCL_INDEX_NONE, all characters up to the first null character are used.
.AP size_t index in
If negative, all characters up to the first null character are used.
.AP int index in
The index of the Unicode character to return.
.AP size_t first in
.AP int first in
The index of the first Unicode character in the Unicode range to be
returned as a new value.
.AP size_t last in
.AP int last in
The index of the last Unicode character in the Unicode range to be
returned as a new value.
.AP Tcl_Obj *objPtr in/out
Points to a value to manipulate.
.AP Tcl_Obj *appendObjPtr in
The value to append to \fIobjPtr\fR in \fBTcl_AppendObjToObj\fR.
.AP int *lengthPtr out
If non-NULL, the location where \fBTcl_GetStringFromObj\fR will store
the length of a value's string representation.
.AP size_t | int *lengthPtr out
The location where \fBTcl_GetStringFromObj\fR will store the length
of a value's string representation. May be (int *)NULL when not used.
.AP "const char" *string in
Null-terminated string value to append to \fIobjPtr\fR.
.AP va_list argList in
An argument list which must have been initialized using
\fBva_start\fR, and cleared using \fBva_end\fR.
.AP size_t limit in
.AP int limit in
Maximum number of bytes to be appended.
.AP "const char" *ellipsis in
Suffix to append when the limit leads to string truncation.
@@ -137,7 +140,7 @@ Format control string including % conversion specifiers.
The number of elements to format or concatenate.
.AP Tcl_Obj *objv[] in
The array of values to format or concatenate.
.AP size_t newLength in
.AP int newLength in
New length for the string value of \fIobjPtr\fR, not including the
final null character.
.BE
@@ -244,6 +247,12 @@ values may contain internal null characters). Any number of
\fIstring\fR arguments may be provided, but the last argument
must be a NULL pointer to indicate the end of the list.
.PP
\fBTcl_AppendStringsToObjVA\fR is the same as \fBTcl_AppendStringsToObj\fR
except that instead of taking a variable number of arguments it takes an
argument list. Interfaces using argument lists have been found to be
nonportable in practice. This function is deprecated and will be removed
in Tcl 9.0.
.PP
\fBTcl_AppendLimitedToObj\fR is similar to \fBTcl_AppendToObj\fR
except that it imposes a limit on how many bytes are appended.
This can be handy when the string to be appended might be
+8 -8
View File
@@ -1,6 +1,6 @@
'\"
'\" Copyright (c) 1992-1999 Karl Lehenbauer and Mark Diekhans.
'\" Copyright (c) 2000 by Scriptics Corporation.
'\" Copyright (c) 1992-1999 Karl Lehenbauer & Mark Diekhans.
'\" Copyright (c) 2000 Scriptics Corporation.
'\" All rights reserved.
'\"
.TH TCL_MEM_DEBUG 3 8.1 Tcl "Tcl Library Procedures"
@@ -34,7 +34,7 @@ and the Tcl \fBmemory\fR command can be used to validate and examine
memory usage.
.SH "GUARD ZONES"
.PP
When memory debugging is enabled, whenever a call to \fBTcl_Alloc\fR is
When memory debugging is enabled, whenever a call to \fBckalloc\fR is
made, slightly more memory than requested is allocated so the memory
debugging code can keep track of the allocated memory, and eight-byte
.QW "guard zones"
@@ -44,7 +44,7 @@ C #define \fBLOW_GUARD_SIZE\fR and #define \fBHIGH_GUARD_SIZE\fR
in the file \fIgeneric/tclCkalloc.c\fR \(em it can
be extended if you suspect large overwrite problems, at some cost in
performance.) A known pattern is written into the guard zones and, on
a call to \fBTcl_Free\fR, the guard zones of the space being freed are
a call to \fBckfree\fR, the guard zones of the space being freed are
checked to see if either zone has been modified in any way. If one
has been, the guard bytes and their new contents are identified, and a
.QW "low guard failed"
@@ -53,7 +53,7 @@ or
message is issued. The
.QW "guard failed"
message includes the address of the memory packet and
the file name and line number of the code that called \fBTcl_Free\fR.
the file name and line number of the code that called \fBckfree\fR.
This allows you to detect the common sorts of one-off problems, where
not enough space was allocated to contain the data written, for
example.
@@ -66,15 +66,15 @@ suspect (or know) that corruption is occurring before the Tcl
interpreter comes up far enough for you to issue commands, you can set
\fBMEM_VALIDATE\fR define, recompile tclCkalloc.c and rebuild Tcl.
This will enable memory validation from the first call to
\fBTcl_Alloc\fR, again, at a large performance impact.
\fBckalloc\fR, again, at a large performance impact.
.PP
If you are desperate and validating memory on every call to
\fBTcl_Alloc\fR and \fBTcl_Free\fR is not enough, you can explicitly call
\fBckalloc\fR and \fBckfree\fR is not enough, you can explicitly call
\fBTcl_ValidateAllMemory\fR directly at any point. It takes a \fIchar
*\fR and an \fIint\fR which are normally the filename and line number
of the caller, but they can actually be anything you want. Remember
to remove the calls after you find the problem.
.SH "SEE ALSO"
Tcl_Alloc, memory, Tcl_ValidateAllMemory, Tcl_DumpActiveMemory
ckalloc, memory, Tcl_ValidateAllMemory, Tcl_DumpActiveMemory
.SH KEYWORDS
memory, debug
+1 -1
View File
@@ -224,7 +224,7 @@ is reached. The upper bits of the Unicode character will be 0.
.RS
.PP
The range U+00D800\(enU+00DFFF is reserved for surrogates, which
are illegal on its own. Therefore, such sequences will result in
are illegal on their own. Therefore, such sequences will result in
the replacement character U+FFFD. Surrogate pairs should be
encoded as single \e\fBU\fIhhhhhhhh\fR character.
.RE
+4 -4
View File
@@ -88,7 +88,7 @@ The initial value for the checksum algorithm.
.AP "unsigned char" *bytes in
An array of bytes to run the checksum algorithm over, or NULL to get the
recommended initial value for the checksum algorithm.
.AP size_t length in
.AP int length in
The number of bytes in the array.
.AP int mode in
What mode to operate the stream in. Should be either
@@ -107,9 +107,9 @@ if the currently compressed data must be made available for access using
into a state where the decompressor can recover from on corruption, or
\fBTCL_ZLIB_FINALIZE\fR to ensure that the stream is finished and that any
trailer demanded by the format is written.
.AP size_t count in
The maximum number of bytes to get from the stream, or TCL_INDEX_NONE to get
all remaining bytes from the stream's buffers.
.AP int count in
The maximum number of bytes to get from the stream, or -1 to get all remaining
bytes from the stream's buffers.
.AP Tcl_Obj *compDict in
A byte array value that is the compression dictionary to use with the stream.
Note that this is \fInot a Tcl dictionary\fR, and it is recommended that this
+11 -1
View File
@@ -10,13 +10,17 @@
.so man.macros
.BS
.SH NAME
Tcl_Main, Tcl_SetStartupScript, Tcl_GetStartupScript, Tcl_SetMainLoop \- main program, startup script, and event loop definition for Tcl-based applications
Tcl_Main, Tcl_MainEx, Tcl_MainExW, Tcl_SetStartupScript, Tcl_GetStartupScript, Tcl_SetMainLoop \- main program, startup script, and event loop definition for Tcl-based applications
.SH SYNOPSIS
.nf
\fB#include <tcl.h>\fR
.sp
\fBTcl_Main\fR(\fIargc, argv, appInitProc\fR)
.sp
\fBTcl_MainEx\fR(\fIargc, charargv, appInitProc, interp\fR)
.sp
\fBTcl_MainExW\fR(\fIargc, wideargv, appInitProc, interp\fR)
.sp
\fBTcl_SetStartupScript\fR(\fIpath, encoding\fR)
.sp
Tcl_Obj *
@@ -30,6 +34,10 @@ Number of elements in \fIargv\fR.
.AP char *argv[] in
Array of strings containing command-line arguments. On Windows, when
using -DUNICODE, the parameter type changes to wchar_t *.
.AP char *charargv[] in
As argv, but does not change type to wchar_t.
.AP char *wideargv[] in
As argv, but type is always wchar_t.
.AP Tcl_AppInitProc *appInitProc in
Address of an application-specific initialization procedure.
The value for this argument is usually \fBTcl_AppInit\fR.
@@ -42,6 +50,8 @@ If non-NULL, location to write a copy of the (const char *)
pointing to the encoding name.
.AP Tcl_MainLoopProc *mainLoopProc in
Address of an application-specific event loop procedure.
.AP Tcl_Interp *interp in
Already created Tcl Interpreter.
.BE
.SH DESCRIPTION
.PP
+3 -3
View File
@@ -67,7 +67,7 @@ Id of the thread waited upon.
.AP Tcl_ThreadCreateProc *proc in
This procedure will act as the \fBmain()\fR of the newly created
thread. The specified \fIclientData\fR will be its sole argument.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary information. Passed as sole argument to the \fIproc\fR.
.AP int stackSize in
The size of the stack given to the new thread.
@@ -208,7 +208,7 @@ value and then finishes.
.CS
static \fBTcl_ThreadCreateType\fR
MyThreadImplFunc(
void *clientData)
ClientData clientData)
{
int i, limit = (int) clientData;
for (i=0 ; i<limit ; i++) {
@@ -223,7 +223,7 @@ would do this:
.PP
.CS
int limit = 1000000000;
void *limitData = (void*)((intptr_t) limit);
ClientData limitData = (void*)((intptr_t) limit);
Tcl_ThreadId id; \fI/* holds identity of thread created */\fR
int result;
+1 -1
View File
@@ -1,5 +1,5 @@
'\"
'\" Copyright (c) 1997 by Sun Microsystems, Inc.
'\" Copyright (c) 1997 Sun Microsystems, Inc.
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+5 -5
View File
@@ -13,7 +13,7 @@ Tcl_CommandTraceInfo, Tcl_TraceCommand, Tcl_UntraceCommand \- monitor renames an
.nf
\fB#include <tcl.h>\fR
.sp
void *
ClientData
\fBTcl_CommandTraceInfo(\fIinterp, cmdName, flags, proc, prevClientData\fB)\fR
.sp
int
@@ -32,9 +32,9 @@ OR'ed collection of the values \fBTCL_TRACE_RENAME\fR and
\fBTCL_TRACE_DELETE\fR.
.AP Tcl_CommandTraceProc *proc in
Procedure to call when specified operations occur to \fIcmdName\fR.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary argument to pass to \fIproc\fR.
.AP void *prevClientData in
.AP ClientData prevClientData in
If non-NULL, gives last value returned by \fBTcl_CommandTraceInfo\fR,
so this call will return information about next trace. If NULL, this
call will return information about first trace.
@@ -65,7 +65,7 @@ match the type \fBTcl_CommandTraceProc\fR:
.PP
.CS
typedef void \fBTcl_CommandTraceProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR,
const char *\fIoldName\fR,
const char *\fInewName\fR,
@@ -74,7 +74,7 @@ typedef void \fBTcl_CommandTraceProc\fR(
.PP
The \fIclientData\fR and \fIinterp\fR parameters will have the same
values as those passed to \fBTcl_TraceCommand\fR when the trace was
created. \fIclientData\fR typically points to an application-specific
created. \fIClientData\fR typically points to an application-specific
data structure that describes what to do when \fIproc\fR is invoked.
\fIOldName\fR gives the name of the command being renamed, and
\fInewName\fR gives the name that the command is being renamed to (or
+11 -12
View File
@@ -5,7 +5,7 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
.TH Tcl_TraceVar 3 9.0 Tcl "Tcl Library Procedures"
.TH Tcl_TraceVar 3 8.7 Tcl "Tcl Library Procedures"
.so man.macros
.BS
.SH NAME
@@ -24,13 +24,13 @@ int
.sp
\fBTcl_UntraceVar2(\fIinterp, name1, name2, flags, proc, clientData\fB)\fR
.sp
void *
ClientData
\fBTcl_VarTraceInfo(\fIinterp, varName, flags, proc, prevClientData\fB)\fR
.sp
void *
ClientData
\fBTcl_VarTraceInfo2(\fIinterp, name1, name2, flags, proc, prevClientData\fB)\fR
.SH ARGUMENTS
.AS void *prevClientData
.AS Tcl_VarTraceProc prevClientData
.AP Tcl_Interp *interp in
Interpreter containing variable.
.AP "const char" *varName in
@@ -46,7 +46,7 @@ Not all flags are used by all
procedures. See below for more information.
.AP Tcl_VarTraceProc *proc in
Procedure to invoke whenever one of the traced operations occurs.
.AP void *clientData in
.AP ClientData clientData in
Arbitrary one-word value to pass to \fIproc\fR.
.AP "const char" *name1 in
Name of scalar or array variable (without array index).
@@ -54,7 +54,7 @@ Name of scalar or array variable (without array index).
For a trace on an element of an array, gives the index of the
element. For traces on scalar variables or on whole arrays,
is NULL.
.AP void *prevClientData in
.AP ClientData prevClientData in
If non-NULL, gives last value returned by \fBTcl_VarTraceInfo\fR or
\fBTcl_VarTraceInfo2\fR, so this call will return information about
next trace. If NULL, this call will return information about first
@@ -107,7 +107,7 @@ before an array set, but that will trigger write traces.
\fBTCL_TRACE_RESULT_DYNAMIC\fR
The result of invoking the \fIproc\fR is a dynamically allocated
string that will be released by the Tcl library via a call to
\fBTcl_Free\fR. Must not be specified at the same time as
\fBckfree\fR. Must not be specified at the same time as
\fBTCL_TRACE_RESULT_OBJECT\fR.
.TP
\fBTCL_TRACE_RESULT_OBJECT\fR
@@ -124,7 +124,7 @@ It should have arguments and result that match the type
.PP
.CS
typedef char *\fBTcl_VarTraceProc\fR(
void *\fIclientData\fR,
ClientData \fIclientData\fR,
Tcl_Interp *\fIinterp\fR,
char *\fIname1\fR,
char *\fIname2\fR,
@@ -134,7 +134,7 @@ typedef char *\fBTcl_VarTraceProc\fR(
The \fIclientData\fR and \fIinterp\fR parameters will
have the same values as those passed to \fBTcl_TraceVar\fR when the
trace was created.
\fIclientData\fR typically points to an application-specific
\fIClientData\fR typically points to an application-specific
data structure that describes what to do when \fIproc\fR
is invoked.
\fIName1\fR and \fIname2\fR give the name of the traced variable
@@ -308,7 +308,7 @@ The return value must be a pointer to a static character string
containing an error message,
unless (\fIexactly\fR one of) the \fBTCL_TRACE_RESULT_DYNAMIC\fR and
\fBTCL_TRACE_RESULT_OBJECT\fR flags is set, which specify that the result is
either a dynamic string (to be released with \fBTcl_Free\fR) or a
either a dynamic string (to be released with \fBckfree\fR) or a
Tcl_Obj* (cast to char* and to be released with
\fBTcl_DecrRefCount\fR) containing the error message.
If a trace procedure returns an error, no further traces are
@@ -333,8 +333,7 @@ The routine \fBTcl_InterpDeleted\fR is an important tool for this.
When \fBTcl_InterpDeleted\fR returns 1, \fIproc\fR will not be able
to invoke any scripts in \fIinterp\fR. You may encounter old code using
a deprecated flag value \fBTCL_INTERP_DESTROYED\fR to signal this
condition, but Tcl 9 no longer supports this. Any supported code
must be converted to stop using it.
condition, but any supported code should be converted to stop using it.
.PP
A trace procedure can be called at any time, even when there
are partially formed results stored in the interpreter. If
+26 -20
View File
@@ -49,19 +49,19 @@ int
\fBTcl_UniCharLen\fR(\fIuniStr\fR)
.sp
int
\fBTcl_UniCharNcmp\fR(\fIucs, uct, uniLength\fR)
\fBTcl_UniCharNcmp\fR(\fIucs, uct, numChars\fR)
.sp
int
\fBTcl_UniCharNcasecmp\fR(\fIucs, uct, uniLength\fR)
\fBTcl_UniCharNcasecmp\fR(\fIucs, uct, numChars\fR)
.sp
int
\fBTcl_UniCharCaseMatch\fR(\fIuniStr, uniPattern, nocase\fR)
.sp
int
\fBTcl_UtfNcmp\fR(\fIcs, ct, length\fR)
\fBTcl_UtfNcmp\fR(\fIcs, ct, numChars\fR)
.sp
int
\fBTcl_UtfNcasecmp\fR(\fIcs, ct, length\fR)
\fBTcl_UtfNcasecmp\fR(\fIcs, ct, numChars\fR)
.sp
int
\fBTcl_UtfCharComplete\fR(\fIsrc, length\fR)
@@ -87,7 +87,7 @@ int
const char *
\fBTcl_UtfAtIndex\fR(\fIsrc, index\fR)
.sp
size_t
int
\fBTcl_UtfBackslash\fR(\fIsrc, readPtr, dst\fR)
.SH ARGUMENTS
.AS "const Tcl_UniChar" *uniPattern in/out
@@ -126,16 +126,18 @@ A null-terminated utf-16 string.
A null-terminated utf-16 string.
.AP "const unsigned short" *utf16Pattern in
A null-terminated utf-16 string.
.AP size_t length in
.AP int length in
The length of the UTF-8 string in bytes (not UTF-8 characters). If
negative, all bytes up to the first null byte are used.
.AP size_t uniLength in
.AP int uniLength in
The length of the Unicode string in characters.
.AP "Tcl_DString" *dsPtr in/out
A pointer to a previously initialized \fBTcl_DString\fR.
.AP "unsigned long" numChars in
The number of characters to compare.
.AP "const char" *start in
Pointer to the beginning of a UTF-8 string.
.AP size_t index in
.AP int index in
The index of a character (not byte) in the UTF-8 string.
.AP int *readPtr out
If non-NULL, filled with the number of bytes in the backslash sequence,
@@ -203,7 +205,7 @@ the number of Unicode characters (not bytes) in that string.
\fBTcl_UniCharNcmp\fR and \fBTcl_UniCharNcasecmp\fR correspond to
\fBstrncmp\fR and \fBstrncasecmp\fR, respectively, for Unicode characters.
They accept two null-terminated Unicode strings and the number of characters
to compare. Both strings are assumed to be at least \fIuniLength\fR characters
to compare. Both strings are assumed to be at least \fInumChars\fR characters
long. \fBTcl_UniCharNcmp\fR compares the two strings character-by-character
according to the Unicode character ordering. It returns an integer greater
than, equal to, or less than 0 if the first string is greater than, equal
@@ -217,7 +219,7 @@ be case sensitive and returns whether the string matches the pattern.
.PP
\fBTcl_UtfNcmp\fR corresponds to \fBstrncmp\fR for UTF-8 strings. It
accepts two null-terminated UTF-8 strings and the number of characters
to compare. (Both strings are assumed to be at least \fIlength\fR
to compare. (Both strings are assumed to be at least \fInumChars\fR
characters long.) \fBTcl_UtfNcmp\fR compares the two strings
character-by-character according to the Unicode character ordering.
It returns an integer greater than, equal to, or less than 0 if the
@@ -231,10 +233,10 @@ characters.
.PP
\fBTcl_UtfCharComplete\fR returns 1 if the source UTF-8 string \fIsrc\fR
of \fIlength\fR bytes is long enough to be decoded by
\fBTcl_UtfToUniChar\fR, or 0 otherwise. This function does not guarantee
that the UTF-8 string is properly formed. This routine is used by
procedures that are operating on a byte at a time and need to know if a
full Unicode character has been seen.
\fBTcl_UtfToUniChar\fR/\fBTcl_UtfNext\fR, or 0 otherwise. This function
does not guarantee that the UTF-8 string is properly formed. This routine
is used by procedures that are operating on a byte at a time and need to
know if a full Unicode character has been seen.
.PP
\fBTcl_NumUtfChars\fR corresponds to \fBstrlen\fR for UTF-8 strings. It
returns the number of Tcl_UniChars that are represented by the UTF-8 string
@@ -255,7 +257,8 @@ Given \fIsrc\fR, a pointer to some location in a UTF-8 string,
\fBTcl_UtfNext\fR returns a pointer to the next UTF-8 character in the
string. The caller must not ask for the next character after the last
character in the string if the string is not terminated by a null
character.
character. \fBTcl_UtfCharComplete\fR can be used in that case to
make sure enough bytes are available before calling \fBTcl_UtfNext\fR.
.PP
\fBTcl_UtfPrev\fR is used to step backward through but not beyond the
UTF-8 string that begins at \fIstart\fR. If the UTF-8 string is made
@@ -272,25 +275,28 @@ always a pointer to a location in the string. It always returns a pointer to
a byte that begins a character when scanning for characters beginning
from \fIstart\fR. When \fIsrc\fR is greater than \fIstart\fR, it
always returns a pointer less than \fIsrc\fR and greater than or
equal to (\fIsrc\fR - \fBTCL_UTF_MAX\fR). The character that begins
equal to (\fIsrc\fR - 4). The character that begins
at the returned pointer is the first one that either includes the
byte \fIsrc[-1]\fR, or might include it if the right trail bytes are
present at \fIsrc\fR and greater. \fBTcl_UtfPrev\fR never reads the
byte \fIsrc[0]\fR nor the byte \fIstart[-1]\fR nor the byte
\fIsrc[-\fBTCL_UTF_MAX\fI-1]\fR.
\fIsrc[-5]\fR.
.PP
\fBTcl_UniCharAtIndex\fR corresponds to a C string array dereference or the
Pascal Ord() function. It returns the Unicode character represented at the
specified character (not byte) \fIindex\fR in the UTF-8 string
\fIsrc\fR. The source string must contain at least \fIindex\fR
characters. If \fIindex\fR is TCL_INDEX_NONE or \fIindex\fR points
characters. If a negative \fIindex\fR is given or \fIindex\fR points
to the second half of a surrogate pair, it returns -1.
.PP
\fBTcl_UtfAtIndex\fR returns a pointer to the specified character (not
byte) \fIindex\fR in the UTF-8 string \fIsrc\fR. The source string must
contain at least \fIindex\fR characters. This is equivalent to calling
\fBTcl_UtfToUniChar\fR \fIindex\fR times. If \fIindex\fR is TCL_INDEX_NONE,
the return pointer points to the first character in the source string.
\fBTcl_UtfToUniChar\fR \fIindex\fR times, except if that would return
a pointer to the second byte of a valid 4-byte UTF-8 sequence, in which
case, \fBTcl_UtfToUniChar\fR will be called once more to find the end
of the sequence. If a negative \fIindex\fR is given, the returned pointer
points to the first character in the source string.
.PP
\fBTcl_UtfBackslash\fR is a utility procedure used by several of the Tcl
commands. It parses a backslash sequence and stores the properly formed
+1 -1
View File
@@ -12,7 +12,7 @@
oo::abstract \- a class that does not allow direct instances of itself
.SH SYNOPSIS
.nf
package require TclOO
package require tcl::oo
\fBoo::abstract\fI method \fR?\fIarg ...\fR?
.fi
+11 -2
View File
@@ -1,6 +1,6 @@
'\"
'\" Copyright (c) 1997 by Sun Microsystems, Inc.
'\" Copyright (c) 2008 by Donal K. Fellows
'\" Copyright (c) 1997 Sun Microsystems, Inc.
'\" Copyright (c) 2008 Donal K. Fellows
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
@@ -762,6 +762,15 @@ high-to-low order within each byte. For example,
will return \fB2\fR with \fB01110\fR stored in \fIvar1\fR and
\fB1000011100000101\fR stored in \fIvar2\fR.
.RE
.IP \fBC\fR 5
This form is similar to \fBA\fR, except that it scans the data from start
and terminates at the first null (C string semantics). For example,
.RS
.CS
\fBbinary scan\fR "abc\e000efghi" C* var1
.CE
will return \fB1\fR with \fBabc\fR stored in \fIvar1\fR.
.RE
.IP \fBH\fR 5
The data is turned into a string of \fIcount\fR hexadecimal digits in
high-to-low order represented as a sequence of characters in the set
+1 -1
View File
@@ -12,7 +12,7 @@
callback, mymethod \- generate callbacks to methods
.SH SYNOPSIS
.nf
package require TclOO
package require tcl::oo
\fBcallback\fR \fImethodName\fR ?\fIarg ...\fR?
\fBmymethod\fR \fImethodName\fR ?\fIarg ...\fR?
+60
View File
@@ -0,0 +1,60 @@
'\"
'\" Copyright (c) 1993 The Regents of the University of California.
'\" Copyright (c) 1994-1996 Sun Microsystems, Inc.
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
.TH case n 7.0 Tcl "Tcl Built-In Commands"
.so man.macros
.BS
'\" Note: do not modify the .SH NAME line immediately below!
.SH NAME
case \- Evaluate one of several scripts, depending on a given value
.SH SYNOPSIS
\fBcase\fI string \fR?\fBin\fR? \fIpatList body \fR?\fIpatList body \fR...?
.sp
\fBcase\fI string \fR?\fBin\fR? {\fIpatList body \fR?\fIpatList body \fR...?}
.BE
.SH DESCRIPTION
.PP
\fINote: the \fBcase\fI command is obsolete and is supported only
for backward compatibility. At some point in the future it may be
removed entirely. You should use the \fBswitch\fI command instead.\fR
.PP
The \fBcase\fR command matches \fIstring\fR against each of
the \fIpatList\fR arguments in order.
Each \fIpatList\fR argument is a list of one or
more patterns. If any of these patterns matches \fIstring\fR then
\fBcase\fR evaluates the following \fIbody\fR argument
by passing it recursively to the Tcl interpreter and returns the result
of that evaluation.
Each \fIpatList\fR argument consists of a single
pattern or list of patterns. Each pattern may contain any of the wild-cards
described under \fBstring match\fR. If a \fIpatList\fR
argument is \fBdefault\fR, the corresponding body will be evaluated
if no \fIpatList\fR matches \fIstring\fR. If no \fIpatList\fR argument
matches \fIstring\fR and no default is given, then the \fBcase\fR
command returns an empty string.
.PP
Two syntaxes are provided for the \fIpatList\fR and \fIbody\fR arguments.
The first uses a separate argument for each of the patterns and commands;
this form is convenient if substitutions are desired on some of the
patterns or commands.
The second form places all of the patterns and commands together into
a single argument; the argument must have proper list structure, with
the elements of the list being the patterns and commands.
The second form makes it easy to construct multi-line case commands,
since the braces around the whole list make it unnecessary to include a
backslash at the end of each line.
Since the \fIpatList\fR arguments are in braces in the second form,
no command or variable substitutions are performed on them; this makes
the behavior of the second form different than the first form in some
cases.
.SH "SEE ALSO"
switch(n)
.SH KEYWORDS
case, match, regular expression
+2 -2
View File
@@ -175,7 +175,7 @@ operating system, as returned by \fBencoding system\fR.
.TP
\fB\-eofchar\fR \fB{\fIinChar outChar\fB}\fR
.
This option supports DOS file systems that use Control-z (\ex1a) as an
This option supports DOS file systems that use Control-z (\ex1A) as an
end of file marker. If \fIchar\fR is not an empty string, then this
character signals end-of-file when it is encountered during input.
For output, the end-of-file character is output when the channel is
@@ -188,7 +188,7 @@ will apply to both reading and writing. When querying the end-of-file
character of a read-write channel, a two-element list will always be
returned. The default value for \fB\-eofchar\fR is the empty string
in all cases except for files under Windows. In that case the
\fB\-eofchar\fR is Control-z (\ex1a) for reading and the empty string
\fB\-eofchar\fR is Control-z (\ex1A) for reading and the empty string
for writing.
The acceptable range for \fB\-eofchar\fR values is \ex01 - \ex7f;
attempting to set \fB\-eofchar\fR to a value outside of this range will
+1 -1
View File
@@ -12,7 +12,7 @@
oo::class \- class of all classes
.SH SYNOPSIS
.nf
package require TclOO
package require tcl::oo
\fBoo::class\fI method \fR?\fIarg ...\fR?
.fi
+1 -1
View File
@@ -13,7 +13,7 @@
classvariable \- create link from local variable to variable in class
.SH SYNOPSIS
.nf
package require TclOO
package require tcl::oo
\fBclassvariable\fR \fIvariableName\fR ?\fI...\fR?
.fi
+2 -2
View File
@@ -8,7 +8,7 @@
.SH NAME
clock \- Obtain and manipulate dates and times
.SH "SYNOPSIS"
package require \fBTcl 8.5\fR
package require \fBTcl 8.5-\fR
.sp
\fBclock add\fR \fItimeVal\fR ?\fIcount unit...\fR? ?\fI\-option value\fR?
.sp
@@ -951,7 +951,7 @@ msgcat(n)
.SH KEYWORDS
clock, date, time
.SH "COPYRIGHT"
Copyright (c) 2004 Kevin B. Kenny <kennykb@acm.org>. All rights reserved.
Copyright \(co 2004 Kevin B. Kenny <kennykb@acm.org>. All rights reserved.
'\" Local Variables:
'\" mode: nroff
'\" End:
+1 -1
View File
@@ -12,7 +12,7 @@
oo::copy \- create copies of objects and classes
.SH SYNOPSIS
.nf
package require TclOO
package require tcl::oo
\fBoo::copy\fI sourceObject \fR?\fItargetObject\fR? ?\fItargetNamespace\fR?
.fi

Some files were not shown because too many files have changed in this diff Show More