From 20664f1fa1563c7ad9992f369427f1cd841faf6d Mon Sep 17 00:00:00 2001 From: dkf Date: Tue, 10 Nov 2020 09:26:10 +0000 Subject: Cleaning up the actions and trying to make them behave more usefully on Windows. --- .github/workflows/linux-build.yml | 11 ++++------- .github/workflows/win-build.yml | 7 ++++--- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/.github/workflows/linux-build.yml b/.github/workflows/linux-build.yml index db46cfd..8bb0141 100644 --- a/.github/workflows/linux-build.yml +++ b/.github/workflows/linux-build.yml @@ -3,35 +3,32 @@ on: [push] jobs: build: runs-on: ubuntu-latest + defaults: + run: + shell: bash + working-directory: unix steps: - name: Checkout uses: actions/checkout@v2 - name: Configure - working-directory: unix run: | mkdir "${HOME}/install dir" ./configure ${CFGOPT} "--prefix=$HOME/install dir" || (cat config.log && exit 1) - name: Build - working-directory: unix run: | make all - name: Build Test Harness - working-directory: unix run: | make tcltest - name: Run Tests - working-directory: unix run: | make test - name: Test-Drive Installation - working-directory: unix run: | make install - name: Create Distribution Package - working-directory: unix run: | make dist - name: Convert Documentation to HTML - working-directory: unix run: | make html-tcl diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml index 652b34a..9c4b6f5 100644 --- a/.github/workflows/win-build.yml +++ b/.github/workflows/win-build.yml @@ -3,20 +3,21 @@ on: [push] jobs: build: runs-on: windows-latest + defaults: + run: + shell: bash + working-directory: win steps: - name: Checkout uses: actions/checkout@v2 - name: Init MSVC uses: ilammy/msvc-dev-cmd@v1 - name: Build - working-directory: win run: | nmake -f makefile.vc all - name: Build Test Harness - working-directory: win run: | nmake -f makefile.vc tcltest - name: Run Tests - working-directory: win run: | nmake -f makefile.vc test -- cgit v0.12 From 8e61a58c14167041d08246a34671480c02e8427e Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Fri, 13 Nov 2020 16:55:36 +0000 Subject: Backport [fc1e203728]: backout e56a9f214a. If it was wrong in core-8-branch, it's wrong here too. --- macosx/GNUmakefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/macosx/GNUmakefile b/macosx/GNUmakefile index 9c8b0e2..cdeb099 100644 --- a/macosx/GNUmakefile +++ b/macosx/GNUmakefile @@ -13,7 +13,7 @@ #------------------------------------------------------------------------------------------------------- # customizable settings -DESTDIR ?= ${CURDIR}/../../build +DESTDIR ?= INSTALL_ROOT ?= ${DESTDIR} BUILD_DIR ?= ${CURDIR}/../../build -- cgit v0.12 From a22953bb77fe0c1b7c1ecaa9397dfc12cf5d0a54 Mon Sep 17 00:00:00 2001 From: dkf Date: Sat, 14 Nov 2020 09:31:49 +0000 Subject: Back to powershell --- .github/workflows/win-build.yml | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml index 9c4b6f5..f7d4ef1 100644 --- a/.github/workflows/win-build.yml +++ b/.github/workflows/win-build.yml @@ -5,8 +5,9 @@ jobs: runs-on: windows-latest defaults: run: - shell: bash + shell: powershell working-directory: win + # Using powershell means we need to explicitly stop on failure steps: - name: Checkout uses: actions/checkout@v2 @@ -14,10 +15,19 @@ jobs: uses: ilammy/msvc-dev-cmd@v1 - name: Build run: | - nmake -f makefile.vc all + &nmake -f makefile.vc all + if ($lastexitcode -ne 0) { + throw "nmake exit code: $lastexitcode" + } - name: Build Test Harness run: | - nmake -f makefile.vc tcltest + &nmake -f makefile.vc tcltest + if ($lastexitcode -ne 0) { + throw "nmake exit code: $lastexitcode" + } - name: Run Tests run: | - nmake -f makefile.vc test + &nmake -f makefile.vc test + if ($lastexitcode -ne 0) { + throw "nmake exit code: $lastexitcode" + } -- cgit v0.12 From b3e4fc2a04cb66d7fb0e7e2acd6c078f7489364b Mon Sep 17 00:00:00 2001 From: dkf Date: Sat, 14 Nov 2020 12:25:38 +0000 Subject: Fixed some tests, added trial macOS build --- .github/workflows/mac-build.yml | 55 +++++++++++++++++++++++++++++++++++++++++ tests/async.test | 4 +-- tests/chanio.test | 7 +++--- tests/exec.test | 7 ++++-- tests/fileSystem.test | 6 +++-- tests/format.test | 14 +++++++---- tests/io.test | 11 ++++++--- tests/socket.test | 4 ++- tests/winFCmd.test | 14 ++++++----- tests/winTime.test | 6 +++-- 10 files changed, 101 insertions(+), 27 deletions(-) create mode 100644 .github/workflows/mac-build.yml diff --git a/.github/workflows/mac-build.yml b/.github/workflows/mac-build.yml new file mode 100644 index 0000000..bd45c89 --- /dev/null +++ b/.github/workflows/mac-build.yml @@ -0,0 +1,55 @@ +name: macOS Build and Test +on: [push] +jobs: + with-Xcode: + runs-on: macos-latest + defaults: + run: + shell: bash + working-directory: macosx + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Prepare + run: touch tclStubInit.c tclOOStubInit.c + working-directory: generic + - name: Build + run: make all + - name: Run Tests + run: make test styles=develop + env: + ERROR_ON_FAILURES: 1 + MAC_CI: 1 + Unix-like: + runs-on: macos-latest + strategy: + matrix: + config_options: [ "--enable-dtrace", "--enable-debug=mem" ] + defaults: + run: + shell: bash + working-directory: unix + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Prepare + run: | + touch tclStubInit.c tclOOStubInit.c + mkdir "$HOME/install dir" + working-directory: generic + - name: Configure + run: ./configure ${CFGOPT} "--prefix=$HOME/install dir" || (cat config.log && exit 1) + env: + CFGOPT: ${{ matrix.config_options }} + - name: Build + run: | + make all tcltest + - name: Run Tests + run: | + make test + env: + ERROR_ON_FAILURES: 1 + MAC_CI: 1 + - name: Trial Installation + run: | + make install diff --git a/tests/async.test b/tests/async.test index 1aef907..86527bf 100644 --- a/tests/async.test +++ b/tests/async.test @@ -21,7 +21,7 @@ catch [list package require -exact Tcltest [info patchlevel]] testConstraint testasync [llength [info commands testasync]] testConstraint threaded [::tcl::pkgconfig get threaded] -testConstraint knownMsvcBug [expr {![info exists ::env(TRAVIS_OS_NAME)] || ![string match windows $::env(TRAVIS_OS_NAME)]}] +testConstraint notWinCI [expr {$::tcl_platform(platform) != "windows" || ![info exists ::env(CI)]}] proc async1 {result code} { global aresult acode @@ -204,7 +204,7 @@ test async-4.2 {async interrupting straight bytecode sequence} -constraints { testasync delete $hm } test async-4.3 {async interrupting loop-less bytecode sequence} -constraints { - testasync threaded knownMsvcBug + testasync threaded notWinCI } -setup { set hm [testasync create async3] } -body { diff --git a/tests/chanio.test b/tests/chanio.test index 58116ba..1f9e19b 100644 --- a/tests/chanio.test +++ b/tests/chanio.test @@ -42,7 +42,8 @@ namespace eval ::tcl::test::io { testConstraint testchannelevent [llength [info commands testchannelevent]] testConstraint testmainthread [llength [info commands testmainthread]] testConstraint testservicemode [llength [info commands testservicemode]] - testConstraint knownMsvcBug [expr {![info exists ::env(TRAVIS_OS_NAME)] || ![string match windows $::env(TRAVIS_OS_NAME)]}] + testConstraint notWinCI [expr { + $::tcl_platform(platform) ne "windows" || ![info exists ::env(CI)]}] testConstraint notOSX [expr {$::tcl_platform(os) ne "Darwin"}] # You need a *very* special environment to do some tests. In particular, @@ -1881,7 +1882,7 @@ test chan-io-20.3 {Tcl_CreateChannel: initial settings} -constraints {unix} -bod } -result {{{} {}} {auto lf}} test chan-io-20.5 {Tcl_CreateChannel: install channel in empty slot} -setup { set path(stdout) [makeFile {} stdout] -} -constraints {stdio knownMsvcBug} -body { +} -constraints {stdio notWinCI} -body { set f [open $path(script) w] chan puts -nonewline $f { chan close stdout @@ -2791,7 +2792,7 @@ test chan-io-29.34 {Tcl_Chan Close, async flush on chan close, using sockets} -s chan puts $s $l } } -} -constraints {socket tempNotMac fileevent knownMsvcBug} -body { +} -constraints {socket tempNotMac fileevent notWinCI} -body { proc accept {s a p} { variable x chan event $s readable [namespace code [list readit $s]] diff --git a/tests/exec.test b/tests/exec.test index b07099b..af7aae5 100644 --- a/tests/exec.test +++ b/tests/exec.test @@ -24,7 +24,8 @@ package require tcltests # All tests require the "exec" command. # Skip them if exec is not defined. testConstraint exec [llength [info commands exec]] -testConstraint noosx [expr {![info exists ::env(TRAVIS_OSX_IMAGE)] || ![string match xcode* $::env(TRAVIS_OSX_IMAGE)]}] +# Some skips when running in a macOS CI environment +testConstraint noosxCI [expr {![info exists ::env(MAC_CI)]}] unset -nocomplain path @@ -671,7 +672,9 @@ test exec-18.2 {exec cat deals with weird file names} -body { # Note that this test cannot be adapted to work on Windows; that platform has # no kernel support for an analog of O_APPEND. OTOH, that means we can assume # that there is a POSIX shell... -test exec-19.1 {exec >> uses O_APPEND} -constraints {exec unix notValgrind noosx} -setup { +# +# This test also fails in some cases when building with macOS +test exec-19.1 {exec >> uses O_APPEND} -constraints {exec unix notValgrind noosxCI} -setup { set tmpfile [makeFile {0} tmpfile.exec-19.1] } -body { # Note that we have to allow for the current contents of the temporary diff --git a/tests/fileSystem.test b/tests/fileSystem.test index c1deb1b..0d7b183 100644 --- a/tests/fileSystem.test +++ b/tests/fileSystem.test @@ -38,7 +38,9 @@ catch { testConstraint testfilesystem [llength [info commands ::testfilesystem]] testConstraint testsetplatform [llength [info commands ::testsetplatform]] testConstraint testsimplefilesystem [llength [info commands ::testsimplefilesystem]] -testConstraint knownMsvcBug [expr {![info exists ::env(TRAVIS_OS_NAME)] || ![string match windows $::env(TRAVIS_OS_NAME)]}] +# Some things fail under all Continuous Integration systems for subtle reasons +# such as CI often running with elevated privileges in a container. +testConstraint notInCIenv [expr {![info exists ::env(CI)]}] cd [tcltest::temporaryDirectory] makeFile "test file" gorp.file @@ -317,7 +319,7 @@ test filesystem-1.37 {file normalisation with '/./'} -body { } -match regexp -result {^(?:[^/]|/(?:[^/]|$))+$} test filesystem-1.38 {file normalisation with volume relative} -setup { set dir [pwd] -} -constraints {win moreThanOneDrive knownMsvcBug} -body { +} -constraints {win moreThanOneDrive notInCIenv} -body { set path "[string range [lindex $drives 0] 0 1]foo" cd [lindex $drives 1] file norm $path diff --git a/tests/format.test b/tests/format.test index ea0e929..11cb4b7 100644 --- a/tests/format.test +++ b/tests/format.test @@ -18,10 +18,14 @@ if {"::tcltest" ni [namespace children]} { # %u output depends on word length, so this test is not portable. testConstraint longIs32bit [expr {int(0x80000000) < 0}] testConstraint longIs64bit [expr {int(0x8000000000000000) < 0}] -testConstraint wideIs64bit \ - [expr {(wide(0x80000000) > 0) && (wide(0x8000000000000000) < 0)}] +testConstraint wideIs64bit [expr { + (wide(0x80000000) > 0) && (wide(0x8000000000000000) < 0)}] testConstraint wideBiggerThanInt [expr {wide(0x80000000) != int(0x80000000)}] -testConstraint knownMsvcBug [expr {![info exists ::env(TRAVIS_OS_NAME)] || ![string match windows $::env(TRAVIS_OS_NAME)]}] +# MSVC uses a broken libc that gets sprintf("%g") wrong. This is a pain +# particularly in Continuous Integration, and there isn't anything much we can +# do about it. +testConstraint notWinCI [expr { + ($::tcl_platform(platform) ne "windows") || ![info exists ::env(CI)]}] test format-1.1 {integer formatting} { format "%*d %d %d %d" 6 34 16923 -12 -1 @@ -274,13 +278,13 @@ test format-6.1 {floating-point zeroes} {eformat} { test format-6.2 {floating-point zeroes} {eformat} { format "%.4e %.4f %.4g" 0.0 0.0 0.0 0.0 } {0.0000e+00 0.0000 0} -test format-6.3 {floating-point zeroes} {eformat knownMsvcBug} { +test format-6.3 {floating-point zeroes} {eformat notWinCI} { format "%#.4e %#.4f %#.4g" 0.0 0.0 0.0 0.0 } {0.0000e+00 0.0000 0.000} test format-6.4 {floating-point zeroes} {eformat} { format "%.0e %.0f %.0g" 0.0 0.0 0.0 0.0 } {0e+00 0 0} -test format-6.5 {floating-point zeroes} {eformat knownMsvcBug} { +test format-6.5 {floating-point zeroes} {eformat notWinCI} { format "%#.0e %#.0f %#.0g" 0.0 0.0 0.0 0.0 } {0.e+00 0. 0.} test format-6.6 {floating-point zeroes} { diff --git a/tests/io.test b/tests/io.test index baf9b1c..e45b5ef 100644 --- a/tests/io.test +++ b/tests/io.test @@ -43,7 +43,10 @@ testConstraint testchannelevent [llength [info commands testchannelevent]] testConstraint testmainthread [llength [info commands testmainthread]] testConstraint testobj [llength [info commands testobj]] testConstraint testservicemode [llength [info commands testservicemode]] -testConstraint knownMsvcBug [expr {![info exists ::env(TRAVIS_OS_NAME)] || ![string match windows $::env(TRAVIS_OS_NAME)]}] +# Some things fail under Windows in Continuous Integration systems for subtle +# reasons such as CI often running with elevated privileges in a container. +testConstraint notWinCI [expr { + $::tcl_platform(platform) ne "windows" || ![info exists ::env(CI)]}] testConstraint notOSX [expr {$::tcl_platform(os) ne "Darwin"}] # You need a *very* special environment to do some tests. In @@ -2230,7 +2233,7 @@ test io-27.5 {FlushChannel, implicit flush when buffer fills and on close} \ set path(pipe) [makeFile {} pipe] set path(output) [makeFile {} output] test io-27.6 {FlushChannel, async flushing, async close} \ - {stdio asyncPipeClose knownMsvcBug} { + {stdio asyncPipeClose notWinCI} { # This test may fail on old Unix systems (seen on IRIX64 6.5) with # obsolete gettimeofday() calls. See Tcl Bugs 3530533, 1942197. file delete $path(pipe) @@ -2834,7 +2837,7 @@ test io-29.31 {Tcl_WriteChars, background flush} stdio { set result } ok test io-29.32 {Tcl_WriteChars, background flush to slow reader} \ - {stdio asyncPipeClose knownMsvcBug} { + {stdio asyncPipeClose notWinCI} { # This test may fail on old Unix systems (seen on IRIX64 6.5) with # obsolete gettimeofday() calls. See Tcl Bugs 3530533, 1942197. file delete $path(pipe) @@ -8068,7 +8071,7 @@ test io-53.17 {[7c187a3773] MBWrite: proper inQueueTail handling} -setup { removeFile out } -result {line 100 line} -test io-54.1 {Recursive channel events} {socket fileevent knownMsvcBug} { +test io-54.1 {Recursive channel events} {socket fileevent notWinCI} { # This test checks to see if file events are delivered during recursive # event loops when there is buffered data on the channel. diff --git a/tests/socket.test b/tests/socket.test index 2060f35..d5f9c94 100644 --- a/tests/socket.test +++ b/tests/socket.test @@ -67,7 +67,9 @@ if {"::tcltest" ni [namespace children]} { ::tcltest::loadTestedCommands -if {[info exists ::env(TRAVIS_OSX_IMAGE)] && [string match xcode* $::env(TRAVIS_OSX_IMAGE)]} { +# A bad interaction between socket creation, macOS, and unattended CI +# environments make this whole file impractical to run; too many weird hangs. +if {[info exists ::env(MAC_CI)]} { return } diff --git a/tests/winFCmd.test b/tests/winFCmd.test index 7c81e81..04c4fd9 100644 --- a/tests/winFCmd.test +++ b/tests/winFCmd.test @@ -29,7 +29,9 @@ testConstraint testchmod [llength [info commands testchmod]] testConstraint cdrom 0 testConstraint exdev 0 testConstraint longFileNames 0 -testConstraint knownMsvcBug [expr {![info exists ::env(TRAVIS_OS_NAME)] || ![string match windows $::env(TRAVIS_OS_NAME)]}] +# Some things fail under all Continuous Integration systems for subtle reasons +# such as CI often running with elevated privileges in a container. +testConstraint notInCIenv [expr {![info exists ::env(CI)]}] proc createfile {file {string a}} { set f [open $file w] @@ -411,7 +413,7 @@ proc MakeFiles {dirname} { test winFCmd-1.38 {TclpRenameFile: check rename of conflicting inodes} -setup { cleanup -} -constraints {win winNonZeroInodes knownMsvcBug} -body { +} -constraints {win winNonZeroInodes notInCIenv} -body { file mkdir td1 foreach {a b} [MakeFiles td1] break file rename -force $a $b @@ -661,7 +663,7 @@ test winFCmd-5.1 {TclpCopyDirectory: calls TraverseWinTree} -setup { test winFCmd-6.1 {TclpRemoveDirectory: errno: EACCES} -setup { cleanup -} -constraints {winVista testfile testchmod knownMsvcBug} -body { +} -constraints {winVista testfile testchmod notInCIenv} -body { file mkdir td1 testchmod 0 td1 testfile rmdir td1 @@ -715,7 +717,7 @@ test winFCmd-6.8 {TclpRemoveDirectory: RemoveDirectory fails} -setup { } -result {1 {tf1 ENOTDIR}} test winFCmd-6.9 {TclpRemoveDirectory: errno == EACCES} -setup { cleanup -} -constraints {winVista testfile testchmod knownMsvcBug} -body { +} -constraints {winVista testfile testchmod notInCIenv} -body { file mkdir td1 testchmod 0 td1 testfile rmdir td1 @@ -733,7 +735,7 @@ test winFCmd-6.11 {TclpRemoveDirectory: attr == -1} -setup { } -returnCodes error -match regexp -result {^/ E(ACCES|EXIST)$} test winFCmd-6.13 {TclpRemoveDirectory: write-protected} -setup { cleanup -} -constraints {winVista testfile testchmod knownMsvcBug} -body { +} -constraints {winVista testfile testchmod notInCIenv} -body { file mkdir td1 testchmod 0 td1 testfile rmdir td1 @@ -962,7 +964,7 @@ test winFCmd-9.1 {TraversalDelete: DOTREE_F} -setup { } -result {} test winFCmd-9.3 {TraversalDelete: DOTREE_PRED} -setup { cleanup -} -constraints {winVista testfile testchmod knownMsvcBug} -body { +} -constraints {winVista testfile testchmod notInCIenv} -body { file mkdir td1/td2 testchmod 0 td1 testfile rmdir -force td1 diff --git a/tests/winTime.test b/tests/winTime.test index 19e4c58..68be966 100644 --- a/tests/winTime.test +++ b/tests/winTime.test @@ -19,7 +19,9 @@ if {"::tcltest" ni [namespace children]} { catch [list package require -exact Tcltest [info patchlevel]] testConstraint testwinclock [llength [info commands testwinclock]] -testConstraint knownMsvcBug [expr {![info exists ::env(TRAVIS_OS_NAME)] || ![string match windows $::env(TRAVIS_OS_NAME)]}] +# Some things fail under all Continuous Integration systems for subtle reasons +# such as CI often running with elevated privileges in a container. +testConstraint notInCIenv [expr {![info exists ::env(CI)]}] # The next two tests will crash on Windows if the check for negative # clock values is not done properly. @@ -41,7 +43,7 @@ test winTime-1.2 {TclpGetDate} {win} { # with the Windows clock. 30 sec really isn't enough, # but how much time does a tester have patience for? -test winTime-2.1 {Synchronization of Tcl and Windows clocks} {testwinclock knownMsvcBug} { +test winTime-2.1 {Synchronization of Tcl and Windows clocks} {testwinclock notInCIenv} { # May fail due to OS/hardware discrepancies. See: # http://support.microsoft.com/default.aspx?scid=kb;en-us;274323 set failed {} -- cgit v0.12 From 346721f3f06a873a372934d4764eb2533aaca105 Mon Sep 17 00:00:00 2001 From: dkf Date: Sun, 15 Nov 2020 08:35:49 +0000 Subject: Fix minor errors --- .github/workflows/linux-build.yml | 3 +++ .github/workflows/win-build.yml | 6 +++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/linux-build.yml b/.github/workflows/linux-build.yml index 8bb0141..04420dd 100644 --- a/.github/workflows/linux-build.yml +++ b/.github/workflows/linux-build.yml @@ -14,6 +14,9 @@ jobs: run: | mkdir "${HOME}/install dir" ./configure ${CFGOPT} "--prefix=$HOME/install dir" || (cat config.log && exit 1) + - name: Prepare + run: touch tclStubInit.c tclOOStubInit.c + working-directory: generic - name: Build run: | make all diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml index f7d4ef1..809003b 100644 --- a/.github/workflows/win-build.yml +++ b/.github/workflows/win-build.yml @@ -17,17 +17,17 @@ jobs: run: | &nmake -f makefile.vc all if ($lastexitcode -ne 0) { - throw "nmake exit code: $lastexitcode" + throw "nmake exit code: $lastexitcode" } - name: Build Test Harness run: | &nmake -f makefile.vc tcltest if ($lastexitcode -ne 0) { - throw "nmake exit code: $lastexitcode" + throw "nmake exit code: $lastexitcode" } - name: Run Tests run: | &nmake -f makefile.vc test if ($lastexitcode -ne 0) { - throw "nmake exit code: $lastexitcode" + throw "nmake exit code: $lastexitcode" } -- cgit v0.12 From 3ef704b39c1f9ec4caf502f42325803d2e380f3a Mon Sep 17 00:00:00 2001 From: dkf Date: Sun, 15 Nov 2020 08:38:14 +0000 Subject: Updated README --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index 25367ce..fd4ef2a 100644 --- a/README.md +++ b/README.md @@ -8,14 +8,17 @@ site](https://sourceforge.net/projects/tcl/files/Tcl/). 8.6.10 [![Build Status](https://github.com/tcltk/tcl/workflows/Linux%20Build%20and%20Test/badge.svg?branch=core-8-6-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Linux+Build+and+Test%22+branch%3Acore-8-6-branch) [![Build Status](https://github.com/tcltk/tcl/workflows/Windows%20Build%20and%20Test/badge.svg?branch=core-8-6-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Windows+Build+and+Test%22+branch%3Acore-8-6-branch) +[![Build Status](https://github.com/tcltk/tcl/workflows/macOS%20Build%20and%20Test/badge.svg?branch=core-8-6-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22macOS+Build+and+Test%22+branch%3Acore-8-6-branch)
8.7a4 [![Build Status](https://github.com/tcltk/tcl/workflows/Linux%20Build%20and%20Test/badge.svg?branch=core-8-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Linux+Build+and+Test%22+branch%3Acore-8-branch) [![Build Status](https://github.com/tcltk/tcl/workflows/Windows%20Build%20and%20Test/badge.svg?branch=core-8-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Windows+Build+and+Test%22+branch%3Acore-8-branch) +[![Build Status](https://github.com/tcltk/tcl/workflows/macOS%20Build%20and%20Test/badge.svg?branch=core-8-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22macOS+Build+and+Test%22+branch%3Acore-8-branch)
9.0a2 [![Build Status](https://github.com/tcltk/tcl/workflows/Linux%20Build%20and%20Test/badge.svg?branch=main)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Linux+Build+and+Test%22+branch%3Amain) [![Build Status](https://github.com/tcltk/tcl/workflows/Windows%20Build%20and%20Test/badge.svg?branch=main)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Windows+Build+and+Test%22+branch%3Amain) +[![Build Status](https://github.com/tcltk/tcl/workflows/macOS%20Build%20and%20Test/badge.svg?branch=main)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22macOS+Build+and+Test%22+branch%3Amain) ## Contents 1. [Introduction](#intro) -- cgit v0.12 From 807ed7b13c7dc61b771929a4abbcaa6818c8fae6 Mon Sep 17 00:00:00 2001 From: dkf Date: Sun, 15 Nov 2020 09:17:41 +0000 Subject: Added MSYS/gcc build for Windows, renamed Linux build step --- .github/workflows/linux-build.yml | 2 +- .github/workflows/win-build.yml | 37 ++++++++++++++++++++++++++++++++++++- 2 files changed, 37 insertions(+), 2 deletions(-) diff --git a/.github/workflows/linux-build.yml b/.github/workflows/linux-build.yml index 04420dd..a2b2a64 100644 --- a/.github/workflows/linux-build.yml +++ b/.github/workflows/linux-build.yml @@ -1,7 +1,7 @@ name: Linux Build and Test on: [push] jobs: - build: + gcc: runs-on: ubuntu-latest defaults: run: diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml index 809003b..22d40be 100644 --- a/.github/workflows/win-build.yml +++ b/.github/workflows/win-build.yml @@ -1,7 +1,7 @@ name: Windows Build and Test on: [push] jobs: - build: + MSVC: runs-on: windows-latest defaults: run: @@ -31,3 +31,38 @@ jobs: if ($lastexitcode -ne 0) { throw "nmake exit code: $lastexitcode" } + env: + ERROR_ON_FAILURES: 1 + MSYS-gcc: + runs-on: windows-latest + defaults: + run: + shell: bash + working-directory: win + strategy: + matrix: + config_options: [ "--disable-debug", "--enable-debug=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 + mkdir "${HOME}/install dir" + working-directory: generic + - name: Configure + run: | + ./configure ${CFGOPT} "--prefix=$HOME/install dir" || (cat config.log && exit 1) + env: + CFGOPT: --enable-64bit ${{ matrix.config_options }} + - name: Build + run: make all + - name: Build Test Harness + run: make tcltest + - name: Run Tests + run: make test + env: + ERROR_ON_FAILURES: 1 -- cgit v0.12 From eff08da703a7f85e7c2c34ee624d0b6ae0cea947 Mon Sep 17 00:00:00 2001 From: dkf Date: Sun, 15 Nov 2020 15:48:43 +0000 Subject: Rethinking how to do a build matrix on several platforms --- .github/workflows/linux-build.yml | 10 +++++++++- .github/workflows/mac-build.yml | 14 ++++++++++---- .github/workflows/win-build.yml | 9 ++++++--- 3 files changed, 25 insertions(+), 8 deletions(-) diff --git a/.github/workflows/linux-build.yml b/.github/workflows/linux-build.yml index a2b2a64..a4fd7b3 100644 --- a/.github/workflows/linux-build.yml +++ b/.github/workflows/linux-build.yml @@ -3,6 +3,12 @@ on: [push] jobs: gcc: runs-on: ubuntu-latest + strategy: + matrix: + symbols: + - "no" + - "mem" + - "all" defaults: run: shell: bash @@ -10,10 +16,12 @@ jobs: steps: - name: Checkout uses: actions/checkout@v2 - - name: Configure + - name: Configure (symbols=${{ matrix.symbols }}) run: | mkdir "${HOME}/install dir" ./configure ${CFGOPT} "--prefix=$HOME/install dir" || (cat config.log && exit 1) + env: + CFGOPT: --enable-symbols=${{ matrix.symbols }} - name: Prepare run: touch tclStubInit.c tclOOStubInit.c working-directory: generic diff --git a/.github/workflows/mac-build.yml b/.github/workflows/mac-build.yml index bd45c89..c78f882 100644 --- a/.github/workflows/mac-build.yml +++ b/.github/workflows/mac-build.yml @@ -24,7 +24,12 @@ jobs: runs-on: macos-latest strategy: matrix: - config_options: [ "--enable-dtrace", "--enable-debug=mem" ] + symbols: + - "no" + - "mem" + dtrace: + - "no" + - "yes" defaults: run: shell: bash @@ -37,10 +42,11 @@ jobs: touch tclStubInit.c tclOOStubInit.c mkdir "$HOME/install dir" working-directory: generic - - name: Configure - run: ./configure ${CFGOPT} "--prefix=$HOME/install dir" || (cat config.log && exit 1) + - name: Configure (symbols=${{ matrix.symbols }} dtrace=${{ matrix.dtrace }}) + # Note that macOS is always a 64 bit platform + run: ./configure --enable-64bit ${CFGOPT} "--prefix=$HOME/install dir" || (cat config.log && exit 1) env: - CFGOPT: ${{ matrix.config_options }} + CFGOPT: --enable-symbols=${{ matrix.symbols }} --enable-dtrace=${{ matrix.dtrace }} - name: Build run: | make all tcltest diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml index 22d40be..e938609 100644 --- a/.github/workflows/win-build.yml +++ b/.github/workflows/win-build.yml @@ -41,7 +41,10 @@ jobs: working-directory: win strategy: matrix: - config_options: [ "--disable-debug", "--enable-debug=mem" ] + symbols: + - "no" + - "mem" + - "all" # Using powershell means we need to explicitly stop on failure steps: - name: Checkout @@ -53,11 +56,11 @@ jobs: touch tclStubInit.c tclOOStubInit.c mkdir "${HOME}/install dir" working-directory: generic - - name: Configure + - name: Configure (symbols=${{ matrix.symbols }}) run: | ./configure ${CFGOPT} "--prefix=$HOME/install dir" || (cat config.log && exit 1) env: - CFGOPT: --enable-64bit ${{ matrix.config_options }} + CFGOPT: --enable-64bit --enable-symbols=${{ matrix.symbols }} - name: Build run: make all - name: Build Test Harness -- cgit v0.12 From ffa8d1d461a8bbc533e6f978478165c2be425a4e Mon Sep 17 00:00:00 2001 From: dkf Date: Mon, 16 Nov 2020 09:24:33 +0000 Subject: Disable test that fails in CI environments --- tests/fCmd.test | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/fCmd.test b/tests/fCmd.test index bb8fb4a..09f91f7 100644 --- a/tests/fCmd.test +++ b/tests/fCmd.test @@ -80,6 +80,7 @@ testConstraint darwin9 [expr { && [package vsatisfies 1.$::tcl_platform(osVersion) 1.9] }] testConstraint notDarwin9 [expr {![testConstraint darwin9]}] +testConstraint notContinuousIntegration [expr {![info exists ::env(CI)]}] testConstraint fileSharing 0 testConstraint notFileSharing 1 @@ -2582,7 +2583,11 @@ test fCmd-30.2 {file readable on 'NTUSER.DAT'} -constraints {win} -body { && [file exists $env(USERPROFILE)/NTUSER.DAT] && [file readable $env(USERPROFILE)/NTUSER.DAT]} } -result {1} -test fCmd-30.3 {file readable on 'pagefile.sys'} -constraints {win} -body { +# At least one CI environment (GitHub Actions) is set up with the page file in +# an unusual location; skip the test if that is so. +test fCmd-30.3 {file readable on 'pagefile.sys'} -constraints { + win notContinuousIntegration +} -body { set r {} if {[info exists env(SystemDrive)]} { set path $env(SystemDrive)/pagefile.sys -- cgit v0.12 From 0943b7181074269ccea4e40288d91575ae211a0a Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Mon, 16 Nov 2020 12:48:00 +0000 Subject: 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 --- generic/tclTest.c | 6 ++++-- tests/utf.test | 8 ++++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/generic/tclTest.c b/generic/tclTest.c index f1e3fac..2c29cda 100644 --- a/generic/tclTest.c +++ b/generic/tclTest.c @@ -6825,8 +6825,10 @@ TestUtfNextCmd( /* Run Tcl_UtfNext with many more possible bytes at src[end], all should give the same result */ result = Tcl_UtfNext(buffer + 1); if (first != result) { - first = buffer; - break; + Tcl_SetObjResult(interp, Tcl_ObjPrintf( + "Tcl_UtfNext is not supposed to read src[end]\n" + "Different result when src[end] is %#x", UCHAR(p[-1]))); + return TCL_ERROR; } } diff --git a/tests/utf.test b/tests/utf.test index 6839860..f5b4da8 100644 --- a/tests/utf.test +++ b/tests/utf.test @@ -252,8 +252,8 @@ test utf-6.22 {Tcl_UtfNext} {testutfnext testbytestring} { testutfnext [testbytestring \xD0\xF8] } 1 test utf-6.23 {Tcl_UtfNext} {testutfnext testbytestring} { - testutfnext [testbytestring \xE8] -} -1 + testutfnext [testbytestring \xE8\x00] +} 1 test utf-6.24 {Tcl_UtfNext} {testutfnext testbytestring} { testutfnext [testbytestring \xE8]G } 1 @@ -545,9 +545,11 @@ test utf-6.108 {Tcl_UtfNext, read limits} {testutfnext testbytestring} { test utf-6.109 {Tcl_UtfNext, read limits} {testutfnext testbytestring} { testutfnext \u8820[testbytestring \xA0] 3 } 3 +# This testcase actually tests Tcl_UtfCharComplete, not Tcl_UtfNext test utf-6.110 {Tcl_UtfNext, read limits} {testutfnext testbytestring} { testutfnext [testbytestring \xF2\xA0\xA0\xA0]G 1 } 0 +# This testcase actually tests Tcl_UtfCharComplete, not Tcl_UtfNext test utf-6.111 {Tcl_UtfNext, read limits} {testutfnext testbytestring} { testutfnext [testbytestring \xF2\xA0\xA0\xA0]G 2 } 0 @@ -563,9 +565,11 @@ test utf-6.113.0 {Tcl_UtfNext, read limits} {testutfnext testbytestring ucs2} { test utf-6.113.1 {Tcl_UtfNext, read limits} {testutfnext testbytestring fullutf} { testutfnext [testbytestring \xF2\xA0\xA0\xA0]G 4 } 4 +# This testcase actually tests Tcl_UtfCharComplete, not Tcl_UtfNext test utf-6.114 {Tcl_UtfNext, read limits} {testutfnext testbytestring} { testutfnext [testbytestring \xF2\xA0\xA0\xA0\xA0] 1 } 0 +# This testcase actually tests Tcl_UtfCharComplete, not Tcl_UtfNext test utf-6.115 {Tcl_UtfNext, read limits} {testutfnext testbytestring} { testutfnext [testbytestring \xF2\xA0\xA0\xA0\xA0] 2 } 0 -- cgit v0.12 From 0589f3b799a755af312815888840a99a0733e725 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Mon, 16 Nov 2020 13:12:26 +0000 Subject: Fix 2 testcases which failed when compiled with TCL_UTF_MAX>3 --- tests/utf.test | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/utf.test b/tests/utf.test index f5b4da8..ab98294 100644 --- a/tests/utf.test +++ b/tests/utf.test @@ -276,8 +276,8 @@ test utf-6.30.0 {Tcl_UtfNext} {testutfnext testbytestring ucs2} { testutfnext [testbytestring \xF2] } 1 test utf-6.30.1 {Tcl_UtfNext} {testutfnext testbytestring fullutf} { - testutfnext [testbytestring \xF2] -} -1 + testutfnext [testbytestring \xF2\x00] +} 1 test utf-6.31 {Tcl_UtfNext} {testutfnext testbytestring} { testutfnext [testbytestring \xF2]G } 1 @@ -285,8 +285,8 @@ test utf-6.32.0 {Tcl_UtfNext} {testutfnext testbytestring ucs2} { testutfnext [testbytestring \xF2\xA0] } 1 test utf-6.32.1 {Tcl_UtfNext} {testutfnext testbytestring fullutf} { - testutfnext [testbytestring \xF2\xA0] -} -1 + testutfnext [testbytestring \xF2\xA0\x00] +} 1 test utf-6.33 {Tcl_UtfNext} {testutfnext testbytestring} { testutfnext [testbytestring \xF2\xD0] } 1 -- cgit v0.12 From 71a412b8daa48172c15652a8fb18a5bf2cc148c1 Mon Sep 17 00:00:00 2001 From: oehhar Date: Mon, 16 Nov 2020 13:55:33 +0000 Subject: Ticket [d8ae5d5f4c]: Documentation of dict filter script: script results, not returns a boolean --- doc/dict.n | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/dict.n b/doc/dict.n index cd7e94c..db4b656 100644 --- a/doc/dict.n +++ b/doc/dict.n @@ -58,7 +58,7 @@ of the given patterns (in the style of \fBstring match\fR.) . The script rule tests for matching by assigning the key to the \fIkeyVariable\fR and the value to the \fIvalueVariable\fR, and then evaluating -the given script which should return a boolean value (with the +the given script which should result in a boolean value (with the key/value pair only being included in the result of the \fBdict filter\fR when a true value is returned.) Note that the first argument after the rule selection word is a two-element list. If the -- cgit v0.12 From 413ce795e023b9fc40a39e3a0516bacc566292d7 Mon Sep 17 00:00:00 2001 From: oehhar Date: Mon, 16 Nov 2020 14:06:50 +0000 Subject: Ticket [93551c1230]: Document that http::geturl processes the event loop without -command --- doc/http.n | 3 +++ 1 file changed, 3 insertions(+) diff --git a/doc/http.n b/doc/http.n index 26bf943..ae298b2 100644 --- a/doc/http.n +++ b/doc/http.n @@ -78,6 +78,9 @@ when the transaction completes. For this to work, the Tcl event loop must be active. In Tk applications this is always true. For pure-Tcl applications, the caller can use \fB::http::wait\fR after calling \fB::http::geturl\fR to start the event loop. +.PP +\fBNote:\fR The event queue is even used without the \fB-command\fR option. +As a side effect, arbitrary commands may be processed while \fBhttp::geturl\fR is running. .SH COMMANDS .TP \fB::http::config\fR ?\fIoptions\fR? -- cgit v0.12 From 7fa0505ae881f84ff691141af719e62e654a028e Mon Sep 17 00:00:00 2001 From: oehhar Date: Mon, 16 Nov 2020 14:14:36 +0000 Subject: Ticket [4f511270af7]: http documentation: -query data may be any data --- doc/http.n | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/doc/http.n b/doc/http.n index ae298b2..cbef2ab 100644 --- a/doc/http.n +++ b/doc/http.n @@ -319,9 +319,11 @@ otherwise complain about HTTP/1.1. \fB\-query\fR \fIquery\fR . This flag causes \fB::http::geturl\fR to do a POST request that passes the -\fIquery\fR to the server. The \fIquery\fR must be an x-url-encoding -formatted query. The \fB::http::formatQuery\fR procedure can be used to -do the formatting. +\fIquery\fR as payload verbatim to the server. +The content format (and encoding) of \fIquery\fR is announced by the header +field \fBcontent-type\fR set by the option \fB-type\fR. +\fIquery\fR is an x-url-encoding formatted query, if used for html forms. +The \fB::http::formatQuery\fR procedure can be used to do the formatting. .TP \fB\-queryblocksize\fR \fIsize\fR . -- cgit v0.12 From 45aa98890539609f2fe97681d7bf1a9a8620ae04 Mon Sep 17 00:00:00 2001 From: oehhar Date: Mon, 16 Nov 2020 14:37:00 +0000 Subject: Ticket [361303]: http doc: status values incomplete --- doc/http.n | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/doc/http.n b/doc/http.n index cbef2ab..aa852b3 100644 --- a/doc/http.n +++ b/doc/http.n @@ -547,6 +547,12 @@ is raised, but the status of the transaction will be \fBeof\fR. . The error message will also be stored in the \fBerror\fR status array element, accessible via \fB::http::error\fR. +.TP\fR +.\fBtimeout +A timeout occurred before the transaction could complete +.TP\fR +.\fBreset +user-reset .PP Another error possibility is that \fB::http::geturl\fR is unable to write all the post query data to the server before the server @@ -662,10 +668,9 @@ the post query data to the server. .TP \fBstatus\fR . -Either \fBok\fR, for successful completion, \fBreset\fR for -user-reset, \fBtimeout\fR if a timeout occurred before the transaction -could complete, or \fBerror\fR for an error condition. During the -transaction this value is the empty string. +See description in the chapter \fBERRORS\fR above for a +list and description of \fBstatus\fR. +During the transaction this value is the empty string. .TP \fBtotalsize\fR . -- cgit v0.12 From 969ef21225d3b195d58f9bb37d8b1f8f3c8b6d99 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Tue, 17 Nov 2020 08:39:19 +0000 Subject: Extend tcltk-man2html-utils.tcl, so it can handle the TIP #588 man-page. Also fix 2 (minor) syntax errors in man-pages --- doc/http.n | 10 +++--- doc/re_syntax.n | 6 ++-- tools/tcltk-man2html-utils.tcl | 70 ++++++++++++++++++++++++++++++++++-------- 3 files changed, 67 insertions(+), 19 deletions(-) diff --git a/doc/http.n b/doc/http.n index aa852b3..ce07d30 100644 --- a/doc/http.n +++ b/doc/http.n @@ -547,11 +547,13 @@ is raised, but the status of the transaction will be \fBeof\fR. . The error message will also be stored in the \fBerror\fR status array element, accessible via \fB::http::error\fR. -.TP\fR -.\fBtimeout +.TP +\fBtimeout\fR +. A timeout occurred before the transaction could complete -.TP\fR -.\fBreset +.TP +\fBreset\fR +. user-reset .PP Another error possibility is that \fB::http::geturl\fR is unable to diff --git a/doc/re_syntax.n b/doc/re_syntax.n index 7988071..8d732ed 100644 --- a/doc/re_syntax.n +++ b/doc/re_syntax.n @@ -293,12 +293,12 @@ treatment is as if the enclosing delimiters were .QW \fB[.\fR \& and .QW \fB.]\fR .) -For example, if \fBo\fR and \fB\*(qo\fR are the members of an +For example, if \fBo\fR and \fB\[^o]\fR are the members of an equivalence class, then .QW \fB[[=o=]]\fR , -.QW \fB[[=\*(qo=]]\fR , +.QW \fB[[=\[^o]=]]\fR , and -.QW \fB[o\*(qo]\fR \& +.QW \fB[o\[^o]]\fR \& are all synonymous. An equivalence class may not be an endpoint of a range. .RS .PP diff --git a/tools/tcltk-man2html-utils.tcl b/tools/tcltk-man2html-utils.tcl index 65d81de..0aa1d5c 100644 --- a/tools/tcltk-man2html-utils.tcl +++ b/tools/tcltk-man2html-utils.tcl @@ -130,8 +130,8 @@ proc htmlize-text {text {charmap {}}} { \" {"} \ {<} {<} \ {>} {>} \ - \u201c "“" \ - \u201d "”" + \u201c "“" \ + \u201d "”" return [string map $charmap $text] } @@ -144,20 +144,62 @@ proc process-text {text} { {\&} "\t" \ {\%} {} \ "\\\n" "\n" \ - {\(+-} "±" \ + {\(r!} "¡" \ + {\(ct} "¢" \ + {\(Po} "£" \ + {\(Cs} "¤" \ + {\(Ye} "¥" \ + {\(bb} "¦" \ + {\(sc} "§" \ + {\(ad} "¨" \ {\(co} "©" \ - {\(em} "—" \ - {\(en} "–" \ - {\(fm} "′" \ - {\(mc} "µ" \ - {\(mu} "×" \ - {\(mi} "−" \ - {\(->} "" \ + {\(Of} "ª" \ + {\(Fo} "«" \ + {\(no} "¬" \ + {\(rg} "®" \ + {\(a-} "¯" \ + {\(de} "°" \ + {\(+-} "±" \ + {\(S2} "²" \ + {\(S3} "³" \ + {\(aa} "´" \ + {\(mc} "µ" \ + {\(ps} "¶" \ + {\(pc} "·" \ + {\(ac} "¸" \ + {\(S1} "¹" \ + {\(Om} "º" \ + {\(Fc} "»" \ + {\(14} "¼" \ + {\(12} "½" \ + {\(34} "¾" \ + {\(r?} "¿" \ + {\(AE} "Æ" \ + {\(-D} "Ð" \ + {\(mu} "×" \ + {\(TP} "Þ" \ + {\(ss} "ß" \ + {\(ae} "æ" \ + {\(Sd} "ð" \ + {\(di} "÷" \ + {\(Tp} "þ" \ + {\(em} "—" \ + {\(en} "–" \ + {\(bu} "•" \ + {\(fm} "′" \ + {\(mi} "−" \ + {\(->} "" \ {\fP} {\fR} \ {\.} . \ - {\(bu} "•" \ - {\*(qo} "ô" \ ] + # This might make a few invalid mappings, but we don't use them + foreach c {a c e i n o u y A C E I N O U Y} { + foreach {prefix suffix} { + o ring / slash : uml ' acute ^ circ ` grave ~ tilde , cedilla + } { + lappend charmap "\\\[${prefix}${c}\]" "&${c}${suffix};" + } + } lappend charmap {\-\|\-} -- ; # two hyphens lappend charmap {\-} - ; # a hyphen @@ -1559,6 +1601,10 @@ proc make-manpage-section {outputDir sectionDescriptor} { puts stderr "" } + if {![llength $manual(wing-toc)]} { + fatal "not table of contents." + } + # # make the wing table of contents for the section # -- cgit v0.12 From ffda48d07b9324f64f02a34c0bdced10994cf6d2 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Tue, 17 Nov 2020 08:45:22 +0000 Subject: Extend tcltk-man2html-utils.tcl: Add euro-sign too --- tools/tcltk-man2html-utils.tcl | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/tcltk-man2html-utils.tcl b/tools/tcltk-man2html-utils.tcl index 0aa1d5c..1f49d8c 100644 --- a/tools/tcltk-man2html-utils.tcl +++ b/tools/tcltk-man2html-utils.tcl @@ -189,6 +189,7 @@ proc process-text {text} { {\(fm} "′" \ {\(mi} "−" \ {\(->} "" \ + {\(eu} "€" \ {\fP} {\fR} \ {\.} . \ ] -- cgit v0.12 From 4929dd61e1e28ba20ab70508d4d3421d8747a9ea Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Tue, 17 Nov 2020 09:11:09 +0000 Subject: Generated html still not 100% correct .... --- tools/tcltk-man2html-utils.tcl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/tcltk-man2html-utils.tcl b/tools/tcltk-man2html-utils.tcl index 1f49d8c..e207434 100644 --- a/tools/tcltk-man2html-utils.tcl +++ b/tools/tcltk-man2html-utils.tcl @@ -196,7 +196,7 @@ proc process-text {text} { # This might make a few invalid mappings, but we don't use them foreach c {a c e i n o u y A C E I N O U Y} { foreach {prefix suffix} { - o ring / slash : uml ' acute ^ circ ` grave ~ tilde , cedilla + o ring / slash : uml ' acute ^ circ ` grave ~ tilde , cedil } { lappend charmap "\\\[${prefix}${c}\]" "&${c}${suffix};" } -- cgit v0.12 From 32e54c35045cd5fccf41c90ecee81be122e750a0 Mon Sep 17 00:00:00 2001 From: oehhar Date: Tue, 17 Nov 2020 10:11:24 +0000 Subject: Ticket [ac661a684d]: Tcl_NotifyChannel man page: "no writable callback on pending flush" missing --- doc/CrtChannel.3 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/CrtChannel.3 b/doc/CrtChannel.3 index 929b1b8..0092cfb 100644 --- a/doc/CrtChannel.3 +++ b/doc/CrtChannel.3 @@ -259,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 -- cgit v0.12 From f88225f6fb8117aa9462dc7975e9babf2dcf60c9 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Tue, 17 Nov 2020 14:35:42 +0000 Subject: 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 --- doc/re_syntax.n | 6 +++--- tools/tcltk-man2html-utils.tcl | 13 +++++++++++-- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/doc/re_syntax.n b/doc/re_syntax.n index 8d732ed..4504a58 100644 --- a/doc/re_syntax.n +++ b/doc/re_syntax.n @@ -293,12 +293,12 @@ treatment is as if the enclosing delimiters were .QW \fB[.\fR \& and .QW \fB.]\fR .) -For example, if \fBo\fR and \fB\[^o]\fR are the members of an +For example, if \fBo\fR and \fB\(^o\fR are the members of an equivalence class, then .QW \fB[[=o=]]\fR , -.QW \fB[[=\[^o]=]]\fR , +.QW \fB[[=\(^o=]]\fR , and -.QW \fB[o\[^o]]\fR \& +.QW \fB[o\(^o]\fR \& are all synonymous. An equivalence class may not be an endpoint of a range. .RS .PP diff --git a/tools/tcltk-man2html-utils.tcl b/tools/tcltk-man2html-utils.tcl index e207434..5b2a831 100644 --- a/tools/tcltk-man2html-utils.tcl +++ b/tools/tcltk-man2html-utils.tcl @@ -188,17 +188,26 @@ proc process-text {text} { {\(bu} "•" \ {\(fm} "′" \ {\(mi} "−" \ + {\(.i} "ı" \ + {\(.j} "ȷ" \ + {\(Fn} "ƒ" \ + {\(OE} "Œ" \ + {\(oe} "œ" \ + {\(IJ} "IJ" \ + {\(ij} "ij" \ + {\(<-} "" \ {\(->} "" \ {\(eu} "€" \ {\fP} {\fR} \ {\.} . \ ] # This might make a few invalid mappings, but we don't use them - foreach c {a c e i n o u y A C E I N O U Y} { + foreach c {a c e g i l n o s t u y z A C E G I L N O S T U Y Z} { foreach {prefix suffix} { - o ring / slash : uml ' acute ^ circ ` grave ~ tilde , cedil + o ring / slash : uml ' acute ^ circ ` grave ~ tilde , cedil v caron } { lappend charmap "\\\[${prefix}${c}\]" "&${c}${suffix};" + lappend charmap "\\(${prefix}${c}" "&${c}${suffix};" } } lappend charmap {\-\|\-} -- ; # two hyphens -- cgit v0.12 From c4b8fd351a05b85eebddb6def0955884e6929e65 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Wed, 18 Nov 2020 09:15:31 +0000 Subject: Add github actions build. Use Titlecase in Tcl_StaticPackage --- .github/workflows/linux-build.yml | 45 +++++++++++++++++++++++++ .github/workflows/mac-build.yml | 61 +++++++++++++++++++++++++++++++++ .github/workflows/win-build.yml | 71 +++++++++++++++++++++++++++++++++++++++ README.md | 4 ++- library/dde/pkgIndex.tcl | 4 +-- library/reg/pkgIndex.tcl | 4 +-- tests/fileSystem.test | 2 +- tests/winDde.test | 18 +++++----- win/Makefile.in | 4 +-- win/makefile.vc | 4 +-- win/tclAppInit.c | 4 +-- 11 files changed, 200 insertions(+), 21 deletions(-) create mode 100644 .github/workflows/linux-build.yml create mode 100644 .github/workflows/mac-build.yml create mode 100644 .github/workflows/win-build.yml diff --git a/.github/workflows/linux-build.yml b/.github/workflows/linux-build.yml new file mode 100644 index 0000000..44a6332 --- /dev/null +++ b/.github/workflows/linux-build.yml @@ -0,0 +1,45 @@ +name: Linux +on: [push] +jobs: + gcc: + runs-on: ubuntu-latest + strategy: + matrix: + symbols: + - "no" + - "mem" + - "all" + defaults: + run: + shell: bash + working-directory: unix + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Configure (symbols=${{ matrix.symbols }}) + run: | + mkdir "${HOME}/install" + ./configure ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1) + env: + CFGOPT: --enable-symbols=${{ matrix.symbols }} + - name: Prepare + run: touch tclStubInit.c + working-directory: generic + - name: Build + run: | + make all + - name: Build Test Harness + run: | + make tcltest + - name: Run Tests + run: | + make test + - name: Test-Drive Installation + run: | + make install + - name: Create Distribution Package + run: | + make dist + - name: Convert Documentation to HTML + run: | + make html-tcl diff --git a/.github/workflows/mac-build.yml b/.github/workflows/mac-build.yml new file mode 100644 index 0000000..c3748c0 --- /dev/null +++ b/.github/workflows/mac-build.yml @@ -0,0 +1,61 @@ +name: macOS +on: [push] +jobs: + with-Xcode: + runs-on: macos-latest + defaults: + run: + shell: bash + working-directory: macosx + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Prepare + run: touch tclStubInit.c + working-directory: generic + - name: Build + run: make all + - name: Run Tests + run: make test styles=develop + env: + ERROR_ON_FAILURES: 1 + MAC_CI: 1 + Unix-like: + runs-on: macos-latest + strategy: + matrix: + symbols: + - "no" + - "mem" + dtrace: + - "no" + - "yes" + defaults: + run: + shell: bash + working-directory: unix + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Prepare + run: | + touch tclStubInit.c tclOOStubInit.c + mkdir "$HOME/install" + working-directory: generic + - name: Configure (symbols=${{ matrix.symbols }} dtrace=${{ matrix.dtrace }}) + # Note that macOS is always a 64 bit platform + run: ./configure --enable-64bit ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1) + env: + CFGOPT: --enable-symbols=${{ matrix.symbols }} --enable-dtrace=${{ matrix.dtrace }} + - name: Build + run: | + make all tcltest + - name: Run Tests + run: | + make test + env: + ERROR_ON_FAILURES: 1 + MAC_CI: 1 + - name: Trial Installation + run: | + make install diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml new file mode 100644 index 0000000..6232788 --- /dev/null +++ b/.github/workflows/win-build.yml @@ -0,0 +1,71 @@ +name: Windows +on: [push] +jobs: + MSVC: + runs-on: windows-latest + defaults: + run: + shell: powershell + working-directory: win + # 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 + run: | + &nmake -f makefile.vc all + if ($lastexitcode -ne 0) { + throw "nmake exit code: $lastexitcode" + } + - name: Build Test Harness + run: | + &nmake -f makefile.vc tcltest + if ($lastexitcode -ne 0) { + throw "nmake exit code: $lastexitcode" + } + - name: Run Tests + run: | + &nmake -f makefile.vc test + if ($lastexitcode -ne 0) { + throw "nmake exit code: $lastexitcode" + } + env: + ERROR_ON_FAILURES: 1 + MSYS-gcc: + runs-on: windows-latest + defaults: + run: + shell: bash + working-directory: win + strategy: + matrix: + symbols: + - "no" + - "mem" + - "all" + # 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 + mkdir "${HOME}/install" + working-directory: generic + - name: Configure (symbols=${{ matrix.symbols }}) + run: | + ./configure ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1) + env: + CFGOPT: --enable-64bit --enable-symbols=${{ matrix.symbols }} + - name: Build + run: make all + - name: Build Test Harness + run: make tcltest + - name: Run Tests + run: make test + env: + ERROR_ON_FAILURES: 1 diff --git a/README.md b/README.md index efad379..24871c0 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,9 @@ This is the **Tcl 8.5.19** 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=core-8-5-branch)](https://travis-ci.org/tcltk/tcl) +[![Build Status](https://github.com/tcltk/tcl/workflows/Linux/badge.svg?branch=core-8-5-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Linux%22+branch%3Acore-8-5-branch) +[![Build Status](https://github.com/tcltk/tcl/workflows/Windows/badge.svg?branch=core-8-5-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Windows%22+branch%3Acore-8-5-branch) +[![Build Status](https://github.com/tcltk/tcl/workflows/macOS/badge.svg?branch=core-8-5-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22macOS%22+branch%3Acore-8-5-branch) ## Contents 1. [Introduction](#intro) diff --git a/library/dde/pkgIndex.tcl b/library/dde/pkgIndex.tcl index b7187c0..1ca9c5a 100644 --- a/library/dde/pkgIndex.tcl +++ b/library/dde/pkgIndex.tcl @@ -1,7 +1,7 @@ if {![package vsatisfies [package provide Tcl] 8.5]} return if {[info sharedlibextension] != ".dll"} return if {[::tcl::pkgconfig get debug]} { - package ifneeded dde 1.4.3 [list load [file join $dir tcldde14g.dll] dde] + package ifneeded dde 1.4.3 [list load [file join $dir tcldde14g.dll] Dde] } else { - package ifneeded dde 1.4.3 [list load [file join $dir tcldde14.dll] dde] + package ifneeded dde 1.4.3 [list load [file join $dir tcldde14.dll] Dde] } diff --git a/library/reg/pkgIndex.tcl b/library/reg/pkgIndex.tcl index f2fb3b7..6603e3e 100644 --- a/library/reg/pkgIndex.tcl +++ b/library/reg/pkgIndex.tcl @@ -2,8 +2,8 @@ if {![package vsatisfies [package provide Tcl] 8.5]} return if {[info sharedlibextension] != ".dll"} return if {[::tcl::pkgconfig get debug]} { package ifneeded registry 1.3.5 \ - [list load [file join $dir tclreg13g.dll] registry] + [list load [file join $dir tclreg13g.dll] Registry] } else { package ifneeded registry 1.3.5 \ - [list load [file join $dir tclreg13.dll] registry] + [list load [file join $dir tclreg13.dll] Registry] } diff --git a/tests/fileSystem.test b/tests/fileSystem.test index e6ac9c5..35f2717 100644 --- a/tests/fileSystem.test +++ b/tests/fileSystem.test @@ -760,7 +760,7 @@ test filesystem-7.1 {load from vfs} {win testsimplefilesystem haveDdeDll} { set dde [lindex [glob *dde*[info sharedlib]] 0] testsimplefilesystem 1 # This loads dde via a complex copy-to-temp operation - load simplefs:/$dde dde + load simplefs:/$dde Dde testsimplefilesystem 0 cd $dir set res "ok" diff --git a/tests/winDde.test b/tests/winDde.test index acba304..063edd0 100644 --- a/tests/winDde.test +++ b/tests/winDde.test @@ -10,7 +10,7 @@ # of this file, and for a DISCLAIMER OF ALL WARRANTIES. if {"::tcltest" ni [namespace children]} { - package require tcltest 2 + package require tcltest 2.5 #tcltest::configure -verbose {pass start} namespace import -force ::tcltest::* } @@ -21,7 +21,7 @@ if {[testConstraint win]} { if {![catch { ::tcltest::loadTestedCommands set ::ddever [package require dde 1.4.3] - set ::ddelib [lindex [package ifneeded dde $::ddever] 1]}]} { + set ::ddelib [info loaded "" Dde]}]} { testConstraint dde 1 } } @@ -38,12 +38,12 @@ proc createChildProcess {ddeServerName args} { set f [open $::scriptName w+] puts $f [list set ddeServerName $ddeServerName] - puts $f [list load $::ddelib dde] + puts $f [list load $::ddelib Dde] puts $f { # DDE child server - # if {"::tcltest" ni [namespace children]} { - package require tcltest + package require tcltest 2.5 namespace import -force ::tcltest::* } @@ -111,7 +111,7 @@ test winDde-1.1 {Settings the server's topic name} -constraints dde -body { } -result {foobar foobar self} test winDde-2.1 {Checking for other services} -constraints dde -body { - expr [llength [dde services {} {}]] >= 0 + expr {[llength [dde services {} {}]] >= 0} } -result 1 test winDde-2.2 {Checking for existence, with service and topic specified} \ -constraints dde -body { @@ -119,11 +119,11 @@ test winDde-2.2 {Checking for existence, with service and topic specified} \ } -result 1 test winDde-2.3 {Checking for existence, with only the service specified} \ -constraints dde -body { - expr [llength [dde services TclEval {}]] >= 1 + expr {[llength [dde services TclEval {}]] >= 1} } -result 1 test winDde-2.4 {Checking for existence, with only the topic specified} \ -constraints dde -body { - expr [llength [dde services {} self]] >= 1 + expr {[llength [dde services {} self]] >= 1} } -result 1 # ------------------------------------------------------------------------- @@ -154,8 +154,8 @@ test winDde-3.5 {DDE request locally} -constraints dde -body { dde request -binary TclEval self \xe1 } -result "foo\x00" # Set variable a to A with diaeresis (unicode C4) by relying on the fact -# that utf8 is sent (e.g. "c3 84" on the wire) -test winDde-3.6 {DDE request utf8} -constraints dde -body { +# that utf-8 is sent (e.g. "c3 84" on the wire) +test winDde-3.6 {DDE request utf-8} -constraints dde -body { set \xe1 "not set" dde execute TclEval self "set \xe1 \xc4" scan [set \xe1] %c diff --git a/win/Makefile.in b/win/Makefile.in index 324d917..8835232 100644 --- a/win/Makefile.in +++ b/win/Makefile.in @@ -148,8 +148,8 @@ REG_DLL_FILE = tclreg$(REGVER)${DLLSUFFIX} REG_LIB_FILE = @LIBPREFIX@tclreg$(REGVER)${DLLSUFFIX}${LIBSUFFIX} TEST_EXE_FILE = tcltest${EXESUFFIX} TEST_LIB_FILE = @LIBPREFIX@tcltest$(VER)${DLLSUFFIX}${LIBSUFFIX} -TEST_LOAD_PRMS = package ifneeded dde 1.4.3 [list load [file normalize ${DDE_DLL_FILE}] dde];\ - package ifneeded registry 1.3.5 [list load [file normalize ${REG_DLL_FILE}] registry] +TEST_LOAD_PRMS = package ifneeded dde 1.4.3 [list load [file normalize ${DDE_DLL_FILE}] Dde];\ + package ifneeded registry 1.3.5 [list load [file normalize ${REG_DLL_FILE}] Registry] TEST_LOAD_FACILITIES = $(TEST_LOAD_PRMS) SHARED_LIBRARIES = $(TCL_DLL_FILE) diff --git a/win/makefile.vc b/win/makefile.vc index 1924e33..f8ac7e2 100644 --- a/win/makefile.vc +++ b/win/makefile.vc @@ -540,8 +540,8 @@ test-core: setup $(TCLTEST) dlls $(CAT32) set TCL_LIBRARY=$(ROOT:\=/)/library !if "$(OS)" == "Windows_NT" || "$(MSVCDIR)" == "IDE" $(DEBUGGER) $(TCLTEST) "$(ROOT:\=/)/tests/all.tcl" $(TESTFLAGS) -loadfile << - package ifneeded dde 1.4.3 [list load "$(TCLDDELIB:\=/)" dde] - package ifneeded registry 1.3.5 [list load "$(TCLREGLIB:\=/)" registry] + package ifneeded dde 1.4.3 [list load "$(TCLDDELIB:\=/)" Dde] + package ifneeded registry 1.3.5 [list load "$(TCLREGLIB:\=/)" Registry] << !else @echo Please wait while the tests are collected... diff --git a/win/tclAppInit.c b/win/tclAppInit.c index 251a610..b63a405 100644 --- a/win/tclAppInit.c +++ b/win/tclAppInit.c @@ -154,12 +154,12 @@ Tcl_AppInit( if (Registry_Init(interp) == TCL_ERROR) { return TCL_ERROR; } - Tcl_StaticPackage(interp, "registry", Registry_Init, NULL); + Tcl_StaticPackage(interp, "Registry", Registry_Init, NULL); if (Dde_Init(interp) == TCL_ERROR) { return TCL_ERROR; } - Tcl_StaticPackage(interp, "dde", Dde_Init, Dde_SafeInit); + Tcl_StaticPackage(interp, "Dde", Dde_Init, Dde_SafeInit); } #endif -- cgit v0.12 From f7b532246a185fd8f314fdf9969a4a58533f90bc Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Wed, 18 Nov 2020 09:49:08 +0000 Subject: 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 --- generic/tclTest.c | 6 ++++-- tests/utf.test | 12 ++++++------ 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/generic/tclTest.c b/generic/tclTest.c index 6923cd6..6408228 100644 --- a/generic/tclTest.c +++ b/generic/tclTest.c @@ -7184,8 +7184,10 @@ TestUtfNextCmd( /* Run Tcl_UtfNext with many more possible bytes at src[end], all should give the same result */ result = TclUtfNext(buffer + 1); if (first != result) { - first = buffer; - break; + Tcl_SetObjResult(interp, Tcl_ObjPrintf( + "Tcl_UtfNext is not supposed to read src[end]\n" + "Different result when src[end] is %#x", UCHAR(p[-1]))); + return TCL_ERROR; } } diff --git a/tests/utf.test b/tests/utf.test index a32b19e..c61082f 100644 --- a/tests/utf.test +++ b/tests/utf.test @@ -252,8 +252,8 @@ test utf-6.22 {Tcl_UtfNext} {testutfnext testbytestring} { testutfnext [testbytestring \xD0\xF8] } 1 test utf-6.23 {Tcl_UtfNext} {testutfnext testbytestring} { - testutfnext [testbytestring \xE8] -} -1 + testutfnext [testbytestring \xE8\x00] +} 1 test utf-6.24 {Tcl_UtfNext} {testutfnext testbytestring} { testutfnext [testbytestring \xE8]G } 1 @@ -276,8 +276,8 @@ test utf-6.30.0 {Tcl_UtfNext} {testutfnext testbytestring ucs2} { testutfnext [testbytestring \xF2] } 1 test utf-6.30.1 {Tcl_UtfNext} {testutfnext testbytestring fullutf} { - testutfnext [testbytestring \xF2] -} -1 + testutfnext [testbytestring \xF2\x00] +} 1 test utf-6.31 {Tcl_UtfNext} {testutfnext testbytestring} { testutfnext [testbytestring \xF2]G } 1 @@ -285,8 +285,8 @@ test utf-6.32.0 {Tcl_UtfNext} {testutfnext testbytestring ucs2} { testutfnext [testbytestring \xF2\xA0] } 1 test utf-6.32.1 {Tcl_UtfNext} {testutfnext testbytestring fullutf} { - testutfnext [testbytestring \xF2\xA0] -} -1 + testutfnext [testbytestring \xF2\xA0\x00] +} 1 test utf-6.33 {Tcl_UtfNext} {testutfnext testbytestring} { testutfnext [testbytestring \xF2\xD0] } 1 -- cgit v0.12 From d1dfef4884d442f7c3a8a0f5e6a5b0e1aed2a19d Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Thu, 19 Nov 2020 09:39:20 +0000 Subject: Handle github actions test failures. Backported from 8.6 --- tests/fCmd.test | 7 ++++++- tests/format.test | 17 ++++++++--------- tests/interp.test | 12 ++++++------ tests/main.test | 2 +- 4 files changed, 21 insertions(+), 17 deletions(-) diff --git a/tests/fCmd.test b/tests/fCmd.test index 9b6c21e..0fabc90 100644 --- a/tests/fCmd.test +++ b/tests/fCmd.test @@ -76,6 +76,7 @@ testConstraint darwin9 [expr { && [package vsatisfies 1.$::tcl_platform(osVersion) 1.9] }] testConstraint notDarwin9 [expr {![testConstraint darwin9]}] +testConstraint notContinuousIntegration [expr {![info exists ::env(CI)]}] testConstraint fileSharing 0 testConstraint notFileSharing 1 @@ -2578,7 +2579,11 @@ test fCmd-30.2 {file readable on 'NTUSER.DAT'} -constraints {win} -body { && [file exists $env(USERPROFILE)/NTUSER.DAT] && [file readable $env(USERPROFILE)/NTUSER.DAT]} } -result {1} -test fCmd-30.3 {file readable on 'pagefile.sys'} -constraints {win} -body { +# At least one CI environment (GitHub Actions) is set up with the page file in +# an unusual location; skip the test if that is so. +test fCmd-30.3 {file readable on 'pagefile.sys'} -constraints { + win notContinuousIntegration +} -body { set r {} if {[info exists env(SystemDrive)]} { set path $env(SystemDrive)/pagefile.sys diff --git a/tests/format.test b/tests/format.test index 442580e..f7191a6 100644 --- a/tests/format.test +++ b/tests/format.test @@ -21,8 +21,12 @@ testConstraint longIs64bit [expr {int(0x8000000000000000) < 0}] testConstraint wideIs64bit \ [expr {(wide(0x80000000) > 0) && (wide(0x8000000000000000) < 0)}] testConstraint wideBiggerThanInt [expr {wide(0x80000000) != int(0x80000000)}] -testConstraint knownMsvcBug [expr {![info exists ::env(TRAVIS_OS_NAME)] || ![string match windows $::env(TRAVIS_OS_NAME)]}] - +# MSVC uses a broken libc that gets sprintf("%g") wrong. This is a pain +# particularly in Continuous Integration, and there isn't anything much we can +# do about it. +testConstraint notWinCI [expr { + ($::tcl_platform(platform) ne "windows") || ![info exists ::env(CI)]}] + test format-1.1 {integer formatting} { format "%*d %d %d %d" 6 34 16923 -12 -1 } { 34 16923 -12 -1} @@ -252,13 +256,13 @@ test format-6.1 {floating-point zeroes} {eformat} { test format-6.2 {floating-point zeroes} {eformat} { format "%.4e %.4f %.4g" 0.0 0.0 0.0 0.0 } {0.0000e+00 0.0000 0} -test format-6.3 {floating-point zeroes} {eformat knownMsvcBug} { +test format-6.3 {floating-point zeroes} {eformat notWinCI} { format "%#.4e %#.4f %#.4g" 0.0 0.0 0.0 0.0 } {0.0000e+00 0.0000 0.000} test format-6.4 {floating-point zeroes} {eformat} { format "%.0e %.0f %.0g" 0.0 0.0 0.0 0.0 } {0e+00 0 0} -test format-6.5 {floating-point zeroes} {eformat knownMsvcBug} { +test format-6.5 {floating-point zeroes} {eformat notWinCI} { format "%#.0e %#.0f %#.0g" 0.0 0.0 0.0 0.0 } {0.e+00 0. 0.} test format-6.6 {floating-point zeroes} { @@ -532,14 +536,11 @@ test format-18.1 {do not demote existing numeric values} { # Ensure $a and $b are separate objects set b 0xaaaa append b aaaa - set result [expr {$a == $b}] format %08lx $b lappend result [expr {$a == $b}] - set b 0xaaaa append b aaaa - lappend result [expr {$a == $b}] format %08x $b lappend result [expr {$a == $b}] @@ -557,11 +558,9 @@ test format-19.1 { set x 0x8fedc654 list [expr { ~ $x }] [format %08x [expr { ~$x }]] } -match regexp -result {-2414724693 f*701239ab} - test format-19.2 {Bug 1867855} { format %llx 0 } 0 - test format-19.3 {Bug 2830354} { string length [format %340f 0] } 340 diff --git a/tests/interp.test b/tests/interp.test index b5632e1..8159c16 100644 --- a/tests/interp.test +++ b/tests/interp.test @@ -3189,7 +3189,7 @@ test interp-34.7 {limits with callbacks: deleting the handler interp} -setup { # Bug 1085023 test interp-34.8 {time limits trigger in vwaits} -body { set i [interp create] - interp limit $i time -seconds [expr {[clock seconds]+1}] -granularity 1 + interp limit $i time -seconds [expr {[clock seconds] + 1}] -granularity 1 $i eval { set x {} vwait x @@ -3237,8 +3237,8 @@ test interp-34.11 {time limit extension in callbacks} -setup { } -body { set i [interp create] set t0 [clock seconds] - $i limit time -seconds [expr {$t0+1}] -granularity 1 \ - -command "cb1 $i [expr {$t0+2}]" + $i limit time -seconds [expr {$t0 + 1}] -granularity 1 \ + -command "cb1 $i [expr {$t0 + 2}]" set ::result {} lappend ::result [catch { $i eval { @@ -3265,8 +3265,8 @@ test interp-34.12 {time limit extension in callbacks} -setup { } -body { set i [interp create] set t0 [clock seconds] - set ::times "[expr {$t0+2}] [expr {$t0+100}]" - $i limit time -seconds [expr {$t0+1}] -granularity 1 -command "cb1 $i" + set ::times "[expr {$t0 + 2}] [expr {$t0 + 100}]" + $i limit time -seconds [expr {$t0 + 1}] -granularity 1 -command "cb1 $i" set ::result {} lappend ::result [catch { $i eval { @@ -3485,7 +3485,7 @@ test interp-36.7 {SlaveBgerror sets error handler of slave [1999035]} -setup { slave eval { variable done {} after 0 error foo - after 10 [list ::set [namespace which -variable done] {}] + after 20 [list ::set [namespace which -variable done] {}] vwait [namespace which -variable done] } set result diff --git a/tests/main.test b/tests/main.test index 2ea3119..beafca9 100644 --- a/tests/main.test +++ b/tests/main.test @@ -101,7 +101,7 @@ namespace eval ::tcl::test::main { Tcl_Main: encoding of script name: system encoding loss Note the shortcoming explained in Tcl Feature Request 491789 } -constraints { - stdio + stdio tempNotWin } -setup { makeFile {puts [list $argv0 $argv $tcl_interactive]} \u00c0 catch {set f [open "|[list [interpreter] \u00c0]" r]} -- cgit v0.12 From ef7a8aec00a2a78b52cf7d706f7e0d89b9f0b7e1 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Fri, 20 Nov 2020 08:24:53 +0000 Subject: Use '&' in stead of 'and' in copyright statements consistantly --- doc/DumpActiveMemory.3 | 2 +- doc/TCL_MEM_DEBUG.3 | 2 +- doc/memory.n | 2 +- generic/tclClock.c | 2 +- generic/tclDate.c | 2 +- generic/tclGetDate.y | 4 ++-- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/doc/DumpActiveMemory.3 b/doc/DumpActiveMemory.3 index 43333da..972c985 100644 --- a/doc/DumpActiveMemory.3 +++ b/doc/DumpActiveMemory.3 @@ -1,5 +1,5 @@ '\" -'\" Copyright (c) 1992-1999 Karl Lehenbauer and Mark Diekhans. +'\" Copyright (c) 1992-1999 Karl Lehenbauer & Mark Diekhans. '\" Copyright (c) 2000 by Scriptics Corporation. '\" All rights reserved. '\" diff --git a/doc/TCL_MEM_DEBUG.3 b/doc/TCL_MEM_DEBUG.3 index 3a014d4..79fd0a4 100644 --- a/doc/TCL_MEM_DEBUG.3 +++ b/doc/TCL_MEM_DEBUG.3 @@ -1,5 +1,5 @@ '\" -'\" Copyright (c) 1992-1999 Karl Lehenbauer and Mark Diekhans. +'\" Copyright (c) 1992-1999 Karl Lehenbauer & Mark Diekhans. '\" Copyright (c) 2000 by Scriptics Corporation. '\" All rights reserved. '\" diff --git a/doc/memory.n b/doc/memory.n index c8cdb21..18666ce 100644 --- a/doc/memory.n +++ b/doc/memory.n @@ -1,5 +1,5 @@ '\" -'\" Copyright (c) 1992-1999 by Karl Lehenbauer and Mark Diekhans +'\" Copyright (c) 1992-1999 by Karl Lehenbauer & Mark Diekhans '\" Copyright (c) 2000 by Scriptics Corporation. '\" All rights reserved. '\" diff --git a/generic/tclClock.c b/generic/tclClock.c index f02e219..bab9fa5 100644 --- a/generic/tclClock.c +++ b/generic/tclClock.c @@ -5,7 +5,7 @@ * the time and date facilities of TclX, by Mark Diekhans and Karl * Lehenbauer. * - * Copyright 1991-1995 Karl Lehenbauer and Mark Diekhans. + * Copyright (c) 1991-1995 Karl Lehenbauer & Mark Diekhans. * Copyright (c) 1995 Sun Microsystems, Inc. * Copyright (c) 2004 by Kevin B. Kenny. All rights reserved. * diff --git a/generic/tclDate.c b/generic/tclDate.c index 90650ef..aa199c3 100644 --- a/generic/tclDate.c +++ b/generic/tclDate.c @@ -76,7 +76,7 @@ * This file is generated from a yacc grammar defined in the file * tclGetDate.y. It should not be edited directly. * - * Copyright (c) 1992-1995 Karl Lehenbauer and Mark Diekhans. + * Copyright (c) 1992-1995 Karl Lehenbauer & Mark Diekhans. * Copyright (c) 1995-1997 Sun Microsystems, Inc. * * See the file "license.terms" for information on usage and redistribution of diff --git a/generic/tclGetDate.y b/generic/tclGetDate.y index 65a3f86..e6748a4 100644 --- a/generic/tclGetDate.y +++ b/generic/tclGetDate.y @@ -7,7 +7,7 @@ * only used when doing free-form date parsing, an ill-defined process * anyway. * - * Copyright (c) 1992-1995 Karl Lehenbauer and Mark Diekhans. + * Copyright (c) 1992-1995 Karl Lehenbauer & Mark Diekhans. * Copyright (c) 1995-1997 Sun Microsystems, Inc. * * See the file "license.terms" for information on usage and redistribution of @@ -27,7 +27,7 @@ * This file is generated from a yacc grammar defined in the file * tclGetDate.y. It should not be edited directly. * - * Copyright (c) 1992-1995 Karl Lehenbauer and Mark Diekhans. + * Copyright (c) 1992-1995 Karl Lehenbauer & Mark Diekhans. * Copyright (c) 1995-1997 Sun Microsystems, Inc. * * See the file "license.terms" for information on usage and redistribution of -- cgit v0.12 From edcb5e1d91ec243b0f1f462f43b5324c472a9565 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Fri, 20 Nov 2020 08:58:39 +0000 Subject: shorten github actions build name --- .github/workflows/linux-build.yml | 2 +- .github/workflows/mac-build.yml | 2 +- .github/workflows/win-build.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/linux-build.yml b/.github/workflows/linux-build.yml index a4fd7b3..ea5af2b 100644 --- a/.github/workflows/linux-build.yml +++ b/.github/workflows/linux-build.yml @@ -1,4 +1,4 @@ -name: Linux Build and Test +name: Linux on: [push] jobs: gcc: diff --git a/.github/workflows/mac-build.yml b/.github/workflows/mac-build.yml index c78f882..2c95399 100644 --- a/.github/workflows/mac-build.yml +++ b/.github/workflows/mac-build.yml @@ -1,4 +1,4 @@ -name: macOS Build and Test +name: macOS on: [push] jobs: with-Xcode: diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml index e938609..b64a95c 100644 --- a/.github/workflows/win-build.yml +++ b/.github/workflows/win-build.yml @@ -1,4 +1,4 @@ -name: Windows Build and Test +name: Windows on: [push] jobs: MSVC: -- cgit v0.12 From 467e0d60b255f9e2081d7821b3b728032e5f4f70 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Fri, 20 Nov 2020 13:59:36 +0000 Subject: Add a --disable-shared build to github actions --- .github/workflows/linux-build.yml | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/.github/workflows/linux-build.yml b/.github/workflows/linux-build.yml index 44a6332..a8693c5 100644 --- a/.github/workflows/linux-build.yml +++ b/.github/workflows/linux-build.yml @@ -2,13 +2,14 @@ name: Linux on: [push] jobs: gcc: - runs-on: ubuntu-latest + runs-on: ubuntu-20.04 strategy: matrix: - symbols: - - "no" - - "mem" - - "all" + cfgopt: + - "" + - "--disable-shared" + - "--enable-symbols" + - "--enable-symbols=mem" defaults: run: shell: bash @@ -16,15 +17,15 @@ jobs: steps: - name: Checkout uses: actions/checkout@v2 - - name: Configure (symbols=${{ matrix.symbols }}) + - name: Prepare + run: touch tclStubInit.c + working-directory: generic + - name: Configure ${{ matrix.cfgopt }} run: | mkdir "${HOME}/install" ./configure ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1) env: - CFGOPT: --enable-symbols=${{ matrix.symbols }} - - name: Prepare - run: touch tclStubInit.c - working-directory: generic + CFGOPT: ${{ matrix.cfgopt }} - name: Build run: | make all -- cgit v0.12 From ee4dcff50ff6a4f59fec5e4a7dbfe9ca51ac73a1 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Fri, 20 Nov 2020 14:48:57 +0000 Subject: Don't use "Copyright <year> _by_" any more. This results in more consistant copyright statements in the (html) documentation --- doc/CrtTrace.3 | 2 +- doc/DumpActiveMemory.3 | 2 +- doc/GetHostName.3 | 2 +- doc/GetStdChan.3 | 2 +- doc/GetTime.3 | 2 +- doc/Init.3 | 2 +- doc/NRE.3 | 8 ++++---- doc/SaveResult.3 | 2 +- doc/SourceRCFile.3 | 2 +- doc/StdChannels.3 | 2 +- doc/TCL_MEM_DEBUG.3 | 2 +- doc/ToUpper.3 | 2 +- doc/binary.n | 4 ++-- doc/clock.n | 2 +- doc/encoding.n | 2 +- doc/expr.n | 8 ++++---- doc/http.n | 2 +- doc/lindex.n | 2 +- doc/lrepeat.n | 2 +- doc/lreverse.n | 2 +- doc/lset.n | 2 +- doc/mathfunc.n | 8 ++++---- doc/memory.n | 4 ++-- doc/packagens.n | 2 +- doc/socket.n | 2 +- library/clock.tcl | 2 +- library/init.tcl | 2 +- library/msgcat/msgcat.tcl | 6 +++--- library/tcltest/tcltest.tcl | 4 ++-- library/word.tcl | 4 ++-- tools/checkLibraryDoc.tcl | 2 +- tools/encoding/big5.txt | 2 +- tools/encoding/gb2312.txt | 2 +- tools/fix_tommath_h.tcl | 2 +- tools/genStubs.tcl | 2 +- tools/index.tcl | 2 +- tools/installData.tcl | 2 +- tools/loadICU.tcl | 2 +- tools/man2help.tcl | 2 +- tools/man2help2.tcl | 2 +- tools/man2html.tcl | 2 +- tools/man2html1.tcl | 2 +- tools/man2html2.tcl | 2 +- tools/regexpTestLib.tcl | 2 +- tools/tclZIC.tcl | 2 +- tools/uniParse.tcl | 4 ++-- 46 files changed, 62 insertions(+), 62 deletions(-) diff --git a/doc/CrtTrace.3 b/doc/CrtTrace.3 index d5353ac..b1e6483 100644 --- a/doc/CrtTrace.3 +++ b/doc/CrtTrace.3 @@ -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 . All rights reserved. +'\" Copyright (c) 2002 Kevin B. Kenny . All rights reserved. '\" '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/doc/DumpActiveMemory.3 b/doc/DumpActiveMemory.3 index 972c985..226209a 100644 --- a/doc/DumpActiveMemory.3 +++ b/doc/DumpActiveMemory.3 @@ -1,6 +1,6 @@ '\" '\" Copyright (c) 1992-1999 Karl Lehenbauer & Mark Diekhans. -'\" Copyright (c) 2000 by Scriptics Corporation. +'\" Copyright (c) 2000 Scriptics Corporation. '\" All rights reserved. '\" .TH "Tcl_DumpActiveMemory" 3 8.1 Tcl "Tcl Library Procedures" diff --git a/doc/GetHostName.3 b/doc/GetHostName.3 index 73432d3..8e43f8e 100644 --- a/doc/GetHostName.3 +++ b/doc/GetHostName.3 @@ -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" diff --git a/doc/GetStdChan.3 b/doc/GetStdChan.3 index be0e79f..3472fee 100644 --- a/doc/GetStdChan.3 +++ b/doc/GetStdChan.3 @@ -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. diff --git a/doc/GetTime.3 b/doc/GetTime.3 index 9f96be5..9dc4056 100644 --- a/doc/GetTime.3 +++ b/doc/GetTime.3 @@ -1,5 +1,5 @@ '\" -'\" Copyright (c) 2001 by Kevin B. Kenny . +'\" Copyright (c) 2001 Kevin B. Kenny . '\" '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/doc/Init.3 b/doc/Init.3 index 0a6635e..d9fc2e1 100644 --- a/doc/Init.3 +++ b/doc/Init.3 @@ -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" diff --git a/doc/NRE.3 b/doc/NRE.3 index 6024b6a..20efe2f 100644 --- a/doc/NRE.3 +++ b/doc/NRE.3 @@ -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. @@ -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. diff --git a/doc/SaveResult.3 b/doc/SaveResult.3 index 6dd6cb6..918941e 100644 --- a/doc/SaveResult.3 +++ b/doc/SaveResult.3 @@ -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) '\" '\" See the file "license.terms" for information on usage and redistribution diff --git a/doc/SourceRCFile.3 b/doc/SourceRCFile.3 index 0afb66b..bf8c527 100644 --- a/doc/SourceRCFile.3 +++ b/doc/SourceRCFile.3 @@ -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" diff --git a/doc/StdChannels.3 b/doc/StdChannels.3 index 7cb75a0..d3ecff2 100644 --- a/doc/StdChannels.3 +++ b/doc/StdChannels.3 @@ -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. diff --git a/doc/TCL_MEM_DEBUG.3 b/doc/TCL_MEM_DEBUG.3 index 79fd0a4..59af6ba 100644 --- a/doc/TCL_MEM_DEBUG.3 +++ b/doc/TCL_MEM_DEBUG.3 @@ -1,6 +1,6 @@ '\" '\" Copyright (c) 1992-1999 Karl Lehenbauer & Mark Diekhans. -'\" Copyright (c) 2000 by Scriptics Corporation. +'\" Copyright (c) 2000 Scriptics Corporation. '\" All rights reserved. '\" .TH TCL_MEM_DEBUG 3 8.1 Tcl "Tcl Library Procedures" diff --git a/doc/ToUpper.3 b/doc/ToUpper.3 index 629a8e5..a281e2c 100644 --- a/doc/ToUpper.3 +++ b/doc/ToUpper.3 @@ -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. diff --git a/doc/binary.n b/doc/binary.n index 92a939a..fd6b356 100644 --- a/doc/binary.n +++ b/doc/binary.n @@ -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. diff --git a/doc/clock.n b/doc/clock.n index a8c6d29..b8f2a0c 100644 --- a/doc/clock.n +++ b/doc/clock.n @@ -946,7 +946,7 @@ msgcat(n) .SH KEYWORDS clock, date, time .SH "COPYRIGHT" -Copyright (c) 2004 Kevin B. Kenny . All rights reserved. +Copyright \(co 2004 Kevin B. Kenny . All rights reserved. '\" Local Variables: '\" mode: nroff '\" End: diff --git a/doc/encoding.n b/doc/encoding.n index 50ad083..5aac181 100644 --- a/doc/encoding.n +++ b/doc/encoding.n @@ -1,5 +1,5 @@ '\" -'\" Copyright (c) 1998 by Scriptics Corporation. +'\" Copyright (c) 1998 Scriptics Corporation. '\" '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/doc/expr.n b/doc/expr.n index 42da868..b2b1d66 100644 --- a/doc/expr.n +++ b/doc/expr.n @@ -1,7 +1,7 @@ '\" '\" Copyright (c) 1993 The Regents of the University of California. '\" Copyright (c) 1994-2000 Sun Microsystems, Inc. -'\" Copyright (c) 2005 by Kevin B. Kenny . All rights reserved +'\" Copyright (c) 2005 Kevin B. Kenny . All rights reserved '\" '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. @@ -490,9 +490,9 @@ string(n), Tcl(n), while(n) arithmetic, boolean, compare, expression, fuzzy comparison .SH COPYRIGHT .nf -Copyright (c) 1993 The Regents of the University of California. -Copyright (c) 1994-2000 Sun Microsystems Incorporated. -Copyright (c) 2005 by Kevin B. Kenny . All rights reserved. +Copyright \(co 1993 The Regents of the University of California. +Copyright \(co 1994-2000 Sun Microsystems Incorporated. +Copyright \(co 2005 Kevin B. Kenny . All rights reserved. .fi '\" Local Variables: '\" mode: nroff diff --git a/doc/http.n b/doc/http.n index ce07d30..181b48b 100644 --- a/doc/http.n +++ b/doc/http.n @@ -1,6 +1,6 @@ '\" '\" Copyright (c) 1995-1997 Sun Microsystems, Inc. -'\" Copyright (c) 1998-2000 by Ajuba Solutions. +'\" Copyright (c) 1998-2000 Ajuba Solutions. '\" Copyright (c) 2004 ActiveState Corporation. '\" '\" See the file "license.terms" for information on usage and redistribution diff --git a/doc/lindex.n b/doc/lindex.n index d5605bc..5b04b26 100644 --- a/doc/lindex.n +++ b/doc/lindex.n @@ -1,7 +1,7 @@ '\" '\" Copyright (c) 1993 The Regents of the University of California. '\" Copyright (c) 1994-1996 Sun Microsystems, Inc. -'\" Copyright (c) 2001 by Kevin B. Kenny . All rights reserved. +'\" Copyright (c) 2001 Kevin B. Kenny . All rights reserved. '\" '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/doc/lrepeat.n b/doc/lrepeat.n index f92792e..52a17f0 100644 --- a/doc/lrepeat.n +++ b/doc/lrepeat.n @@ -1,5 +1,5 @@ '\" -'\" Copyright (c) 2003 by Simon Geard. All rights reserved. +'\" Copyright (c) 2003 Simon Geard. All rights reserved. '\" '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/doc/lreverse.n b/doc/lreverse.n index 4c2f762..a2a02a5 100644 --- a/doc/lreverse.n +++ b/doc/lreverse.n @@ -1,5 +1,5 @@ '\" -'\" Copyright (c) 2006 by Donal K. Fellows. All rights reserved. +'\" Copyright (c) 2006 Donal K. Fellows. All rights reserved. '\" '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/doc/lset.n b/doc/lset.n index e425274..e509641 100644 --- a/doc/lset.n +++ b/doc/lset.n @@ -1,5 +1,5 @@ '\" -'\" Copyright (c) 2001 by Kevin B. Kenny . All rights reserved. +'\" Copyright (c) 2001 Kevin B. Kenny . All rights reserved. '\" '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/doc/mathfunc.n b/doc/mathfunc.n index 7233d46..7a16961 100644 --- a/doc/mathfunc.n +++ b/doc/mathfunc.n @@ -1,7 +1,7 @@ '\" '\" Copyright (c) 1993 The Regents of the University of California. '\" Copyright (c) 1994-2000 Sun Microsystems, Inc. -'\" Copyright (c) 2005 by Kevin B. Kenny . All rights reserved +'\" Copyright (c) 2005 Kevin B. Kenny . All rights reserved '\" '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. @@ -295,9 +295,9 @@ are returned as an integer value. expr(n), mathop(n), namespace(n) .SH "COPYRIGHT" .nf -Copyright (c) 1993 The Regents of the University of California. -Copyright (c) 1994-2000 Sun Microsystems Incorporated. -Copyright (c) 2005, 2006 by Kevin B. Kenny . +Copyright \(co 1993 The Regents of the University of California. +Copyright \(co 1994-2000 Sun Microsystems Incorporated. +Copyright \(co 2005, 2006 Kevin B. Kenny . .fi '\" Local Variables: '\" mode: nroff diff --git a/doc/memory.n b/doc/memory.n index 18666ce..4d6a7d1 100644 --- a/doc/memory.n +++ b/doc/memory.n @@ -1,6 +1,6 @@ '\" -'\" Copyright (c) 1992-1999 by Karl Lehenbauer & 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 memory n 8.1 Tcl "Tcl Built-In Commands" diff --git a/doc/packagens.n b/doc/packagens.n index 5bd2e67..bce22fe 100644 --- a/doc/packagens.n +++ b/doc/packagens.n @@ -1,5 +1,5 @@ '\" -'\" Copyright (c) 1998-2000 by Scriptics Corporation. +'\" Copyright (c) 1998-2000 Scriptics Corporation. '\" All rights reserved. '\" .TH pkg::create n 8.3 Tcl "Tcl Built-In Commands" diff --git a/doc/socket.n b/doc/socket.n index 3efdb37..aa25bd4 100644 --- a/doc/socket.n +++ b/doc/socket.n @@ -1,6 +1,6 @@ '\" '\" Copyright (c) 1996 Sun Microsystems, Inc. -'\" Copyright (c) 1998-1999 by Scriptics Corporation. +'\" Copyright (c) 1998-1999 Scriptics Corporation. '\" '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/library/clock.tcl b/library/clock.tcl index 2e42a98..273b534 100644 --- a/library/clock.tcl +++ b/library/clock.tcl @@ -9,7 +9,7 @@ # #---------------------------------------------------------------------- # -# Copyright (c) 2004,2005,2006,2007 by Kevin B. Kenny +# Copyright (c) 2004-2007 Kevin B. Kenny # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. # diff --git a/library/init.tcl b/library/init.tcl index 0713aa2..e58086d 100644 --- a/library/init.tcl +++ b/library/init.tcl @@ -6,7 +6,7 @@ # Copyright (c) 1991-1993 The Regents of the University of California. # Copyright (c) 1994-1996 Sun Microsystems, Inc. # Copyright (c) 1998-1999 Scriptics Corporation. -# Copyright (c) 2004 by Kevin B. Kenny. All rights reserved. +# Copyright (c) 2004 Kevin B. Kenny. All rights reserved. # # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/library/msgcat/msgcat.tcl b/library/msgcat/msgcat.tcl index 646bc17..fa91a37 100644 --- a/library/msgcat/msgcat.tcl +++ b/library/msgcat/msgcat.tcl @@ -4,9 +4,9 @@ # message catalog facility for Tcl programs. It should be # loaded with the command "package require msgcat". # -# Copyright (c) 2010-2015 by Harald Oehlmann. -# Copyright (c) 1998-2000 by Ajuba Solutions. -# Copyright (c) 1998 by Mark Harrison. +# Copyright (c) 2010-2015 Harald Oehlmann. +# Copyright (c) 1998-2000 Ajuba Solutions. +# Copyright (c) 1998 Mark Harrison. # # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/library/tcltest/tcltest.tcl b/library/tcltest/tcltest.tcl index 4df25e4..285a33d 100644 --- a/library/tcltest/tcltest.tcl +++ b/library/tcltest/tcltest.tcl @@ -11,8 +11,8 @@ # Microsystems. # # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. -# Copyright (c) 2000 by Ajuba Solutions +# Copyright (c) 1998-1999 Scriptics Corporation. +# Copyright (c) 2000 Ajuba Solutions # Contributions from Don Porter, NIST, 2002. (not subject to US copyright) # All rights reserved. diff --git a/library/word.tcl b/library/word.tcl index 4e57479..828f13a 100644 --- a/library/word.tcl +++ b/library/word.tcl @@ -4,8 +4,8 @@ # strings. This file is primarily needed so Tk text and entry widgets behave # properly for different platforms. # -# Copyright (c) 1996 by Sun Microsystems, Inc. -# Copyright (c) 1998 by Scritpics Corporation. +# Copyright (c) 1996 Sun Microsystems, Inc. +# Copyright (c) 1998 Scritpics Corporation. # # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/tools/checkLibraryDoc.tcl b/tools/checkLibraryDoc.tcl index 5674243..a3aa309 100644 --- a/tools/checkLibraryDoc.tcl +++ b/tools/checkLibraryDoc.tcl @@ -16,7 +16,7 @@ # non-standard code, this script will produce erroneous results. Each # list should be carefully checked for accuracy. # -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. diff --git a/tools/encoding/big5.txt b/tools/encoding/big5.txt index f21484a..dca0191 100644 --- a/tools/encoding/big5.txt +++ b/tools/encoding/big5.txt @@ -2,7 +2,7 @@ # # BIG5 to Unicode table (modified) # -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/tools/encoding/gb2312.txt b/tools/encoding/gb2312.txt index fc9f6f0..900e520 100644 --- a/tools/encoding/gb2312.txt +++ b/tools/encoding/gb2312.txt @@ -2,7 +2,7 @@ # # GB2312 to Unicode table (modified) # -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/tools/fix_tommath_h.tcl b/tools/fix_tommath_h.tcl index 04bf857..8e92400 100755 --- a/tools/fix_tommath_h.tcl +++ b/tools/fix_tommath_h.tcl @@ -3,7 +3,7 @@ # Changes to 'tommath.h' to make it conform with Tcl's linking # conventions. # -# Copyright (c) 2005 by Kevin B. Kenny. All rights reserved. +# Copyright (c) 2005 Kevin B. Kenny. All rights reserved. # # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. diff --git a/tools/genStubs.tcl b/tools/genStubs.tcl index a4a73ba..bc0d700 100644 --- a/tools/genStubs.tcl +++ b/tools/genStubs.tcl @@ -4,7 +4,7 @@ # interface. # # -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # Copyright (c) 2007 Daniel A. Steffen # # See the file "license.terms" for information on usage and redistribution diff --git a/tools/index.tcl b/tools/index.tcl index 71329c2..0e645c4 100644 --- a/tools/index.tcl +++ b/tools/index.tcl @@ -4,7 +4,7 @@ # the man page conversion. It is used to extract information used to # generate a table of contents and a keyword list. # -# 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. diff --git a/tools/installData.tcl b/tools/installData.tcl index 4b43f1e..dd7976b 100644 --- a/tools/installData.tcl +++ b/tools/installData.tcl @@ -12,7 +12,7 @@ exec tclsh "$0" ${1+"$@"} # #---------------------------------------------------------------------- # -# Copyright (c) 2004 by Kevin B. Kenny. All rights reserved. +# Copyright (c) 2004 Kevin B. Kenny. All rights reserved. # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. #---------------------------------------------------------------------- diff --git a/tools/loadICU.tcl b/tools/loadICU.tcl index 506b6e4..204783a 100755 --- a/tools/loadICU.tcl +++ b/tools/loadICU.tcl @@ -22,7 +22,7 @@ # #---------------------------------------------------------------------- # -# Copyright (c) 2004 by Kevin B. Kenny. All rights reserved. +# Copyright (c) 2004 Kevin B. Kenny. All rights reserved. # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. #---------------------------------------------------------------------- diff --git a/tools/man2help.tcl b/tools/man2help.tcl index ca29226..4a928d8 100644 --- a/tools/man2help.tcl +++ b/tools/man2help.tcl @@ -4,7 +4,7 @@ # man2tcl program to generate a Windows help file from Tcl manual # entries. # -# Copyright (c) 1996 by Sun Microsystems, Inc. +# Copyright (c) 1996 Sun Microsystems, Inc. # # PASS 1 diff --git a/tools/man2help2.tcl b/tools/man2help2.tcl index 91c81be..655e55b 100644 --- a/tools/man2help2.tcl +++ b/tools/man2help2.tcl @@ -4,7 +4,7 @@ # the man page conversion. It converts the man format input to rtf # form suitable for use by the Windows help compiler. # -# 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. diff --git a/tools/man2html.tcl b/tools/man2html.tcl index 2d03ab6..28a6751 100644 --- a/tools/man2html.tcl +++ b/tools/man2html.tcl @@ -7,7 +7,7 @@ exec tclsh "$0" ${1+"$@"} # This file contains procedures that work in conjunction with the # man2tcl program to generate a HTML files from Tcl manual entries. # -# Copyright (c) 1996 by Sun Microsystems, Inc. +# Copyright (c) 1996 Sun Microsystems, Inc. # sarray - diff --git a/tools/man2html1.tcl b/tools/man2html1.tcl index 64982ff..7a789f7 100644 --- a/tools/man2html1.tcl +++ b/tools/man2html1.tcl @@ -3,7 +3,7 @@ # This file defines procedures that are used during the first pass of the # man page to html conversion process. It is sourced by h.tcl. # -# Copyright (c) 1996 by Sun Microsystems, Inc. +# Copyright (c) 1996 Sun Microsystems, Inc. # Global variables used by these scripts: # diff --git a/tools/man2html2.tcl b/tools/man2html2.tcl index 8483204..19d6ce0 100644 --- a/tools/man2html2.tcl +++ b/tools/man2html2.tcl @@ -4,7 +4,7 @@ # This file defines procedures that are used during the second pass of the man # page to html conversion process. It is sourced by man2html.tcl. # -# Copyright (c) 1996 by Sun Microsystems, Inc. +# Copyright (c) 1996 Sun Microsystems, Inc. # Global variables used by these scripts: # diff --git a/tools/regexpTestLib.tcl b/tools/regexpTestLib.tcl index 8379159..a94d90f 100644 --- a/tools/regexpTestLib.tcl +++ b/tools/regexpTestLib.tcl @@ -4,7 +4,7 @@ # spencer2regexp.tcl, which are programs written to convert Henry # Spencer's test suite to tcl test files. # -# Copyright (c) 1996 by Sun Microsystems, Inc. +# Copyright (c) 1996 Sun Microsystems, Inc. proc readInputFile {} { global inFileName diff --git a/tools/tclZIC.tcl b/tools/tclZIC.tcl index 6282111..52b86ea 100755 --- a/tools/tclZIC.tcl +++ b/tools/tclZIC.tcl @@ -25,7 +25,7 @@ # #---------------------------------------------------------------------- # -# Copyright (c) 2004 by Kevin B. Kenny. All rights reserved. +# Copyright (c) 2004 Kevin B. Kenny. All rights reserved. # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. #---------------------------------------------------------------------- diff --git a/tools/uniParse.tcl b/tools/uniParse.tcl index 545afc4..90d249a 100644 --- a/tools/uniParse.tcl +++ b/tools/uniParse.tcl @@ -6,7 +6,7 @@ # UnicodeData file from: # ftp://ftp.unicode.org/Public/UNIDATA/UnicodeData.txt # -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # All rights reserved. @@ -185,7 +185,7 @@ proc uni::main {} { * automatically generated by the tools/uniParse.tcl script. Do not * modify this file by hand. * - * Copyright (c) 1998 by Scriptics Corporation. + * Copyright (c) 1998 Scriptics Corporation. * All rights reserved. */ -- cgit v0.12 From f33056b162c2a62e8094b431bddb877526816e23 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Wed, 25 Nov 2020 08:15:16 +0000 Subject: Slightly friendlier "jobs" labels. Fix exact OS (Linux/Mac/Windows) we want to build on, not just "latest" --- .github/workflows/linux-build.yml | 2 +- .github/workflows/mac-build.yml | 10 +++++----- .github/workflows/win-build.yml | 8 ++++---- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/linux-build.yml b/.github/workflows/linux-build.yml index a8693c5..a620aa9 100644 --- a/.github/workflows/linux-build.yml +++ b/.github/workflows/linux-build.yml @@ -2,7 +2,7 @@ name: Linux on: [push] jobs: gcc: - runs-on: ubuntu-20.04 + runs-on: ubuntu-18.04 strategy: matrix: cfgopt: diff --git a/.github/workflows/mac-build.yml b/.github/workflows/mac-build.yml index c3748c0..c9bec7e 100644 --- a/.github/workflows/mac-build.yml +++ b/.github/workflows/mac-build.yml @@ -1,8 +1,8 @@ name: macOS on: [push] jobs: - with-Xcode: - runs-on: macos-latest + xcode: + runs-on: macos-10.15 defaults: run: shell: bash @@ -20,8 +20,8 @@ jobs: env: ERROR_ON_FAILURES: 1 MAC_CI: 1 - Unix-like: - runs-on: macos-latest + clang: + runs-on: macos-10.15 strategy: matrix: symbols: @@ -44,7 +44,7 @@ jobs: working-directory: generic - name: Configure (symbols=${{ matrix.symbols }} dtrace=${{ matrix.dtrace }}) # Note that macOS is always a 64 bit platform - run: ./configure --enable-64bit ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1) + run: ./configure --enable-64bit --enable-framework ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1) env: CFGOPT: --enable-symbols=${{ matrix.symbols }} --enable-dtrace=${{ matrix.dtrace }} - name: Build diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml index 6232788..7e9c416 100644 --- a/.github/workflows/win-build.yml +++ b/.github/workflows/win-build.yml @@ -1,8 +1,8 @@ name: Windows on: [push] jobs: - MSVC: - runs-on: windows-latest + msvc: + runs-on: windows-2016 defaults: run: shell: powershell @@ -33,8 +33,8 @@ jobs: } env: ERROR_ON_FAILURES: 1 - MSYS-gcc: - runs-on: windows-latest + gcc: + runs-on: windows-2016 defaults: run: shell: bash -- cgit v0.12 From 6ad60f8b3b06f698cc20a5f8b6becb499ee9ecd7 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Thu, 26 Nov 2020 14:43:22 +0000 Subject: Get rid of "register" keyword, forbidden in c++20. Fix some more warnings, discovered in c20/c++20 mode --- generic/regcomp.c | 6 +++--- generic/tclAssembly.c | 2 +- generic/tclBinary.c | 8 ++++---- generic/tclCmdAH.c | 10 +++++----- generic/tclCmdIL.c | 26 +++++++++++++------------- generic/tclDisassemble.c | 6 +++--- generic/tclHash.c | 42 +++++++++++++++++++++--------------------- generic/tclHistory.c | 4 ++-- generic/tclIndexObj.c | 16 ++++++++-------- generic/tclInterp.c | 8 ++++---- generic/tclOO.c | 12 ++++++------ generic/tclOOBasic.c | 4 ++-- generic/tclOODefineCmds.c | 2 +- generic/tclOOMethod.c | 24 ++++++++++++------------ generic/tclParse.c | 44 ++++++++++++++++++++++---------------------- generic/tclPipe.c | 4 ++-- generic/tclStrToD.c | 4 ++-- generic/tclStubInit.c | 2 +- generic/tclThreadAlloc.c | 22 +++++++++++----------- unix/tclUnixCompat.c | 16 ++++++++-------- 20 files changed, 131 insertions(+), 131 deletions(-) diff --git a/generic/regcomp.c b/generic/regcomp.c index 219c16a..d828b44 100644 --- a/generic/regcomp.c +++ b/generic/regcomp.c @@ -341,13 +341,13 @@ compile( re->re_info = 0; /* bits get set during parse */ re->re_csize = sizeof(chr); re->re_guts = NULL; - re->re_fns = VS(&functions); + re->re_fns = (char *)&functions; /* * More complex setup, malloced things. */ - re->re_guts = VS(MALLOC(sizeof(struct guts))); + re->re_guts = (char *)(MALLOC(sizeof(struct guts))); if (re->re_guts == NULL) { return freev(v, REG_ESPACE); } @@ -512,7 +512,7 @@ freev( struct vars *v, int err) { - register int ret; + int ret; if (v->re != NULL) { rfree(v->re); diff --git a/generic/tclAssembly.c b/generic/tclAssembly.c index 2f8ab29..94cb53c 100644 --- a/generic/tclAssembly.c +++ b/generic/tclAssembly.c @@ -840,7 +840,7 @@ CompileAssembleObj( Interp *iPtr = (Interp *) interp; /* Internals of the interpreter */ CompileEnv compEnv; /* Compilation environment structure */ - register ByteCode *codePtr = NULL; + ByteCode *codePtr = NULL; /* Bytecode resulting from the assembly */ Namespace* namespacePtr; /* Namespace in which variable and command * names in the bytecode resolve */ diff --git a/generic/tclBinary.c b/generic/tclBinary.c index 78cdd42..8520ec7 100644 --- a/generic/tclBinary.c +++ b/generic/tclBinary.c @@ -2146,8 +2146,8 @@ ScanNumber( if (*numberCachePtrPtr == NULL) { return Tcl_NewLongObj(value); } else { - register Tcl_HashTable *tablePtr = *numberCachePtrPtr; - register Tcl_HashEntry *hPtr; + Tcl_HashTable *tablePtr = *numberCachePtrPtr; + Tcl_HashEntry *hPtr; int isNew; hPtr = Tcl_CreateHashEntry(tablePtr, INT2PTR(value), &isNew); @@ -2155,7 +2155,7 @@ ScanNumber( return Tcl_GetHashValue(hPtr); } if (tablePtr->numEntries <= BINARY_SCAN_MAX_CACHE) { - register Tcl_Obj *objPtr = Tcl_NewLongObj(value); + Tcl_Obj *objPtr = Tcl_NewLongObj(value); Tcl_IncrRefCount(objPtr); Tcl_SetHashValue(hPtr, objPtr); @@ -2274,7 +2274,7 @@ DeleteScanNumberCache( hEntry = Tcl_FirstHashEntry(numberCachePtr, &search); while (hEntry != NULL) { - register Tcl_Obj *value = Tcl_GetHashValue(hEntry); + Tcl_Obj *value = Tcl_GetHashValue(hEntry); if (value != NULL) { Tcl_DecrRefCount(value); diff --git a/generic/tclCmdAH.c b/generic/tclCmdAH.c index 46ee157..58749fc 100644 --- a/generic/tclCmdAH.c +++ b/generic/tclCmdAH.c @@ -173,7 +173,7 @@ Tcl_CaseObjCmd( int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ { - register int i; + int i; int body, result, caseObjc; const char *stringPtr, *arg; Tcl_Obj *const *caseObjv; @@ -982,7 +982,7 @@ TclNREvalObjCmd( int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ { - register Tcl_Obj *objPtr; + Tcl_Obj *objPtr; Interp *iPtr = (Interp *) interp; CmdFrame *invoker = NULL; int word = 0; @@ -2493,7 +2493,7 @@ StoreStatData( * store in varName. */ { Tcl_Obj *field, *value; - register unsigned short mode; + unsigned short mode; /* * Assume Tcl_ObjSetVar2() does not keep a copy of the field name! @@ -2870,7 +2870,7 @@ EachloopCmd( Tcl_Obj *const objv[]) { int numLists = (objc-2) / 2; - register struct ForeachState *statePtr; + struct ForeachState *statePtr; int i, j, result; if (objc < 4 || (objc%2 != 0)) { @@ -2995,7 +2995,7 @@ ForeachLoopStep( Tcl_Interp *interp, int result) { - register struct ForeachState *statePtr = data[0]; + struct ForeachState *statePtr = data[0]; /* * Process the result code from this run of the [foreach] body. Note that diff --git a/generic/tclCmdIL.c b/generic/tclCmdIL.c index c662c22..85416a1 100644 --- a/generic/tclCmdIL.c +++ b/generic/tclCmdIL.c @@ -472,7 +472,7 @@ InfoArgsCmd( int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ { - register Interp *iPtr = (Interp *) interp; + Interp *iPtr = (Interp *) interp; const char *name; Proc *procPtr; CompiledLocal *localPtr; @@ -535,7 +535,7 @@ InfoBodyCmd( int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ { - register Interp *iPtr = (Interp *) interp; + Interp *iPtr = (Interp *) interp; const char *name; Proc *procPtr; Tcl_Obj *bodyPtr, *resultPtr; @@ -650,7 +650,7 @@ InfoCommandsCmd( { const char *cmdName, *pattern; const char *simplePattern; - register Tcl_HashEntry *entryPtr; + Tcl_HashEntry *entryPtr; Tcl_HashSearch search; Namespace *nsPtr; Namespace *globalNsPtr = (Namespace *) Tcl_GetGlobalNamespace(interp); @@ -1846,7 +1846,7 @@ InfoProcsCmd( Namespace *currNsPtr = (Namespace *) Tcl_GetCurrentNamespace(interp); Tcl_Obj *listPtr, *elemObjPtr; int specificNsInPattern = 0;/* Init. to avoid compiler warning. */ - register Tcl_HashEntry *entryPtr; + Tcl_HashEntry *entryPtr; Tcl_HashSearch search; Command *cmdPtr, *realCmdPtr; @@ -2344,7 +2344,7 @@ int Tcl_LinsertObjCmd( ClientData dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ - register int objc, /* Number of arguments. */ + int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ { Tcl_Obj *listPtr; @@ -2426,8 +2426,8 @@ int Tcl_ListObjCmd( ClientData dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ - register int objc, /* Number of arguments. */ - register Tcl_Obj *const objv[]) + int objc, /* Number of arguments. */ + Tcl_Obj *const objv[]) /* The argument objects. */ { /* @@ -2463,7 +2463,7 @@ Tcl_LlengthObjCmd( ClientData dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ - register Tcl_Obj *const objv[]) + Tcl_Obj *const objv[]) /* Argument objects. */ { int listLen, result; @@ -2509,7 +2509,7 @@ Tcl_LrangeObjCmd( ClientData notUsed, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ - register Tcl_Obj *const objv[]) + Tcl_Obj *const objv[]) /* Argument objects. */ { Tcl_Obj **elemPtrs; @@ -2603,8 +2603,8 @@ int Tcl_LrepeatObjCmd( ClientData dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ - register int objc, /* Number of arguments. */ - register Tcl_Obj *const objv[]) + int objc, /* Number of arguments. */ + Tcl_Obj *const objv[]) /* The argument objects. */ { int elementCount, i, totalElems; @@ -2669,7 +2669,7 @@ Tcl_LrepeatObjCmd( CLANG_ASSERT(dataArray || totalElems == 0 ); if (objc == 1) { - register Tcl_Obj *tmpPtr = objv[0]; + Tcl_Obj *tmpPtr = objv[0]; tmpPtr->refCount += elementCount; for (i=0 ; iprocPtr; unsigned char opCode = *pc; - register const InstructionDesc *instDesc = &tclInstructionTable[opCode]; + const InstructionDesc *instDesc = &tclInstructionTable[opCode]; unsigned char *codeStart = codePtr->codeStart; unsigned pcOffset = pc - codeStart; int opnd = 0, i, j, numBytes = 1; @@ -853,8 +853,8 @@ PrintSourceToObj( const char *stringPtr, /* The string to print. */ int maxChars) /* Maximum number of chars to print. */ { - register const char *p; - register int i = 0, len; + const char *p; + int i = 0, len; if (stringPtr == NULL) { Tcl_AppendToObj(appendObj, "\"\"", -1); diff --git a/generic/tclHash.c b/generic/tclHash.c index 193664d..bcf6eee 100644 --- a/generic/tclHash.c +++ b/generic/tclHash.c @@ -126,7 +126,7 @@ const Tcl_HashKeyType tclStringHashKeyType = { void Tcl_InitHashTable( - register Tcl_HashTable *tablePtr, + Tcl_HashTable *tablePtr, /* Pointer to table record, which is supplied * by the caller. */ int keyType) /* Type of keys to use in table: @@ -164,7 +164,7 @@ Tcl_InitHashTable( void Tcl_InitCustomHashTable( - register Tcl_HashTable *tablePtr, + Tcl_HashTable *tablePtr, /* Pointer to table record, which is supplied * by the caller. */ int keyType, /* Type of keys to use in table: @@ -284,7 +284,7 @@ CreateHashEntry( int *newPtr) /* Store info here telling whether a new entry * was created. */ { - register Tcl_HashEntry *hPtr; + Tcl_HashEntry *hPtr; const Tcl_HashKeyType *typePtr; unsigned int hash; int index; @@ -415,7 +415,7 @@ void Tcl_DeleteHashEntry( Tcl_HashEntry *entryPtr) { - register Tcl_HashEntry *prevPtr; + Tcl_HashEntry *prevPtr; const Tcl_HashKeyType *typePtr; Tcl_HashTable *tablePtr; Tcl_HashEntry **bucketPtr; @@ -490,9 +490,9 @@ Tcl_DeleteHashEntry( void Tcl_DeleteHashTable( - register Tcl_HashTable *tablePtr) /* Table to delete. */ + Tcl_HashTable *tablePtr) /* Table to delete. */ { - register Tcl_HashEntry *hPtr, *nextPtr; + Tcl_HashEntry *hPtr, *nextPtr; const Tcl_HashKeyType *typePtr; int i; @@ -598,7 +598,7 @@ Tcl_FirstHashEntry( Tcl_HashEntry * Tcl_NextHashEntry( - register Tcl_HashSearch *searchPtr) + Tcl_HashSearch *searchPtr) /* Place to store information about progress * through the table. Must have been * initialized by calling @@ -645,7 +645,7 @@ Tcl_HashStats( #define NUM_COUNTERS 10 int count[NUM_COUNTERS], overflow, i, j; double average, tmp; - register Tcl_HashEntry *hPtr; + Tcl_HashEntry *hPtr; char *result, *p; /* @@ -715,7 +715,7 @@ AllocArrayEntry( void *keyPtr) /* Key to store in the hash table entry. */ { int *array = (int *) keyPtr; - register int *iPtr1, *iPtr2; + int *iPtr1, *iPtr2; Tcl_HashEntry *hPtr; int count; unsigned int size; @@ -759,8 +759,8 @@ CompareArrayKeys( void *keyPtr, /* New key to compare. */ Tcl_HashEntry *hPtr) /* Existing key to compare. */ { - register const int *iPtr1 = (const int *) keyPtr; - register const int *iPtr2 = (const int *) hPtr->key.words; + const int *iPtr1 = (const int *) keyPtr; + const int *iPtr2 = (const int *) hPtr->key.words; Tcl_HashTable *tablePtr = hPtr->tablePtr; int count; @@ -798,8 +798,8 @@ HashArrayKey( Tcl_HashTable *tablePtr, /* Hash table. */ void *keyPtr) /* Key from which to compute hash value. */ { - register const int *array = (const int *) keyPtr; - register unsigned int result; + const int *array = (const int *) keyPtr; + unsigned int result; int count; for (result = 0, count = tablePtr->keyType; count > 0; @@ -867,8 +867,8 @@ CompareStringKeys( void *keyPtr, /* New key to compare. */ Tcl_HashEntry *hPtr) /* Existing key to compare. */ { - register const char *p1 = (const char *) keyPtr; - register const char *p2 = (const char *) hPtr->key.string; + const char *p1 = (const char *) keyPtr; + const char *p2 = (const char *) hPtr->key.string; return !strcmp(p1, p2); } @@ -895,9 +895,9 @@ HashStringKey( Tcl_HashTable *tablePtr, /* Hash table. */ void *keyPtr) /* Key from which to compute hash value. */ { - register const char *string = keyPtr; - register unsigned int result; - register char c; + const char *string = keyPtr; + unsigned int result; + char c; /* * I tried a zillion different hash functions and asked many other people @@ -1016,12 +1016,12 @@ BogusCreate( static void RebuildTable( - register Tcl_HashTable *tablePtr) /* Table to enlarge. */ + Tcl_HashTable *tablePtr) /* Table to enlarge. */ { int count, index, oldSize = tablePtr->numBuckets; Tcl_HashEntry **oldBuckets = tablePtr->buckets; - register Tcl_HashEntry **oldChainPtr, **newChainPtr; - register Tcl_HashEntry *hPtr; + Tcl_HashEntry **oldChainPtr, **newChainPtr; + Tcl_HashEntry *hPtr; const Tcl_HashKeyType *typePtr; /* Avoid outgrowing capability of the memory allocators */ diff --git a/generic/tclHistory.c b/generic/tclHistory.c index b08e352..24f6d65 100644 --- a/generic/tclHistory.c +++ b/generic/tclHistory.c @@ -61,7 +61,7 @@ Tcl_RecordAndEval( * TCL_EVAL_GLOBAL means use Tcl_GlobalEval * instead of Tcl_Eval. */ { - register Tcl_Obj *cmdPtr; + Tcl_Obj *cmdPtr; int length = strlen(cmd); int result; @@ -214,7 +214,7 @@ DeleteHistoryObjs( ClientData clientData, Tcl_Interp *interp) { - register HistoryObjs *histObjsPtr = clientData; + HistoryObjs *histObjsPtr = clientData; TclDecrRefCount(histObjsPtr->historyObj); TclDecrRefCount(histObjsPtr->addObj); diff --git a/generic/tclIndexObj.c b/generic/tclIndexObj.c index b200f6f..7e23931 100644 --- a/generic/tclIndexObj.c +++ b/generic/tclIndexObj.c @@ -415,9 +415,9 @@ UpdateStringOfIndex( Tcl_Obj *objPtr) { IndexRep *indexRep = objPtr->internalRep.twoPtrValue.ptr1; - register char *buf; - register unsigned len; - register const char *indexStr = EXPAND_OF(indexRep); + char *buf; + unsigned len; + const char *indexStr = EXPAND_OF(indexRep); len = strlen(indexStr); buf = ckalloc(len + 1); @@ -927,7 +927,7 @@ Tcl_WrongNumArgs( */ if (origObjv[i]->typePtr == &indexType) { - register IndexRep *indexRep = + IndexRep *indexRep = origObjv[i]->internalRep.twoPtrValue.ptr1; elementStr = EXPAND_OF(indexRep); @@ -977,7 +977,7 @@ Tcl_WrongNumArgs( */ if (objv[i]->typePtr == &indexType) { - register IndexRep *indexRep = objv[i]->internalRep.twoPtrValue.ptr1; + IndexRep *indexRep = objv[i]->internalRep.twoPtrValue.ptr1; Tcl_AppendStringsToObj(objPtr, EXPAND_OF(indexRep), NULL); } else { @@ -1069,14 +1069,14 @@ Tcl_ParseArgsObjv( * successful exit. Will include the name of * the command. */ int nrem; /* Size of leftovers.*/ - register const Tcl_ArgvInfo *infoPtr; + const Tcl_ArgvInfo *infoPtr; /* Pointer to the current entry in the table * of argument descriptions. */ const Tcl_ArgvInfo *matchPtr; /* Descriptor that matches current argument */ Tcl_Obj *curArg; /* Current argument */ const char *str = NULL; - register char c; /* Second character of current arg (used for + char c; /* Second character of current arg (used for * quick check for matching; use 2nd char. * because first char. will almost always be * '-'). */ @@ -1324,7 +1324,7 @@ PrintUsage( /* Array of command-specific argument * descriptions. */ { - register const Tcl_ArgvInfo *infoPtr; + const Tcl_ArgvInfo *infoPtr; int width, numSpaces; #define NUM_SPACES 20 static const char spaces[] = " "; diff --git a/generic/tclInterp.c b/generic/tclInterp.c index e1a6d20..4f5b300 100644 --- a/generic/tclInterp.c +++ b/generic/tclInterp.c @@ -3283,7 +3283,7 @@ int Tcl_LimitExceeded( Tcl_Interp *interp) { - register Interp *iPtr = (Interp *) interp; + Interp *iPtr = (Interp *) interp; return iPtr->limit.exceeded != 0; } @@ -3314,10 +3314,10 @@ int Tcl_LimitReady( Tcl_Interp *interp) { - register Interp *iPtr = (Interp *) interp; + Interp *iPtr = (Interp *) interp; if (iPtr->limit.active != 0) { - register int ticker = ++iPtr->limit.granularityTicker; + int ticker = ++iPtr->limit.granularityTicker; if ((iPtr->limit.active & TCL_LIMIT_COMMANDS) && ((iPtr->limit.cmdGranularity == 1) || @@ -3361,7 +3361,7 @@ Tcl_LimitCheck( Tcl_Interp *interp) { Interp *iPtr = (Interp *) interp; - register int ticker = iPtr->limit.granularityTicker; + int ticker = iPtr->limit.granularityTicker; if (Tcl_InterpDeleted(interp)) { return TCL_OK; diff --git a/generic/tclOO.c b/generic/tclOO.c index f8a0f12..053abfe 100644 --- a/generic/tclOO.c +++ b/generic/tclOO.c @@ -797,7 +797,7 @@ MyDeleted( ClientData clientData) /* Reference to the object whose [my] has been * squelched. */ { - register Object *oPtr = clientData; + Object *oPtr = clientData; oPtr->myCommand = NULL; } @@ -1632,7 +1632,7 @@ Tcl_NewObjectInstance( int skip) /* Number of arguments to _not_ pass to the * constructor. */ { - register Class *classPtr = (Class *) cls; + Class *classPtr = (Class *) cls; Object *oPtr; ClientData clientData[4]; @@ -1700,7 +1700,7 @@ TclNRNewObjectInstance( Tcl_Object *objectPtr) /* Place to write the object reference upon * successful allocation. */ { - register Class *classPtr = (Class *) cls; + Class *classPtr = (Class *) cls; CallContext *contextPtr; Tcl_InterpState state; Object *oPtr; @@ -2558,7 +2558,7 @@ TclOOObjectCmdCore( methodNamePtr = objv[1]; if (oPtr->mapMethodNameProc != NULL) { - register Class **startClsPtr = &startCls; + Class **startClsPtr = &startCls; Tcl_Obj *mappedMethodName = Tcl_DuplicateObj(methodNamePtr); result = oPtr->mapMethodNameProc(interp, (Tcl_Object) oPtr, @@ -2615,7 +2615,7 @@ TclOOObjectCmdCore( if (startCls != NULL) { for (; contextPtr->index < contextPtr->callPtr->numChain; contextPtr->index++) { - register struct MInvoke *miPtr = + struct MInvoke *miPtr = &contextPtr->callPtr->chain[contextPtr->index]; if (miPtr->isFilter) { @@ -2753,7 +2753,7 @@ TclNRObjectContextInvokeNext( Tcl_Obj *const *objv, int skip) { - register CallContext *contextPtr = (CallContext *) context; + CallContext *contextPtr = (CallContext *) context; if (contextPtr->index + 1 >= contextPtr->callPtr->numChain) { /* diff --git a/generic/tclOOBasic.c b/generic/tclOOBasic.c index 0a1e1eb..b7f70e7 100644 --- a/generic/tclOOBasic.c +++ b/generic/tclOOBasic.c @@ -399,7 +399,7 @@ TclOO_Object_Eval( { CallContext *contextPtr = (CallContext *) context; Tcl_Object object = Tcl_ObjectContextObject(context); - register const int skip = Tcl_ObjectContextSkippedArgs(context); + const int skip = Tcl_ObjectContextSkippedArgs(context); CallFrame *framePtr, **framePtrPtr = &framePtr; Tcl_Obj *scriptPtr; CmdFrame *invoker; @@ -1028,7 +1028,7 @@ TclOOSelfObjCmd( Tcl_SetErrorCode(interp, "TCL", "OO", "UNMATCHED_CONTEXT", NULL); return TCL_ERROR; } else { - register struct MInvoke *miPtr = &CurrentlyInvoked(contextPtr); + struct MInvoke *miPtr = &CurrentlyInvoked(contextPtr); Object *oPtr; const char *type; diff --git a/generic/tclOODefineCmds.c b/generic/tclOODefineCmds.c index 2ace60c..aeee165 100644 --- a/generic/tclOODefineCmds.c +++ b/generic/tclOODefineCmds.c @@ -610,7 +610,7 @@ FindCommand( { int length; const char *nameStr, *string = Tcl_GetStringFromObj(stringObj, &length); - register Namespace *const nsPtr = (Namespace *) namespacePtr; + Namespace *const nsPtr = (Namespace *) namespacePtr; FOREACH_HASH_DECLS; Tcl_Command cmd, cmd2; diff --git a/generic/tclOOMethod.c b/generic/tclOOMethod.c index 493c936..cd3c2c2 100644 --- a/generic/tclOOMethod.c +++ b/generic/tclOOMethod.c @@ -149,8 +149,8 @@ Tcl_NewInstanceMethod( ClientData clientData) /* Some data associated with the particular * method to be created. */ { - register Object *oPtr = (Object *) object; - register Method *mPtr; + Object *oPtr = (Object *) object; + Method *mPtr; Tcl_HashEntry *hPtr; int isNew; @@ -217,8 +217,8 @@ Tcl_NewMethod( ClientData clientData) /* Some data associated with the particular * method to be created. */ { - register Class *clsPtr = (Class *) cls; - register Method *mPtr; + Class *clsPtr = (Class *) cls; + Method *mPtr; Tcl_HashEntry *hPtr; int isNew; @@ -336,7 +336,7 @@ TclOONewProcInstanceMethod( * interested. */ { int argsLen; - register ProcedureMethod *pmPtr; + ProcedureMethod *pmPtr; Tcl_Method method; if (Tcl_ListObjLength(interp, argsObj, &argsLen) != TCL_OK) { @@ -388,7 +388,7 @@ TclOONewProcMethod( * interested. */ { int argsLen; /* -1 => delete argsObj before exit */ - register ProcedureMethod *pmPtr; + ProcedureMethod *pmPtr; const char *procName; Tcl_Method method; @@ -790,7 +790,7 @@ PushMethodCallFrame( * frame. */ { Namespace *nsPtr = (Namespace *) contextPtr->oPtr->namespacePtr; - register int result; + int result; const char *namePtr; CallFrame **framePtrPtr = &fdPtr->framePtr; @@ -822,7 +822,7 @@ PushMethodCallFrame( */ if (pmPtr->flags & USE_DECLARER_NS) { - register Method *mPtr = + Method *mPtr = contextPtr->callPtr->chain[contextPtr->index].mPtr; if (mPtr->declaringClassPtr != NULL) { @@ -895,7 +895,7 @@ PushMethodCallFrame( fdPtr->efi.fields[1].proc = pmPtr->gfivProc; fdPtr->efi.fields[1].clientData = pmPtr; } else { - register Tcl_Method method = + Tcl_Method method = Tcl_ObjectContextMethod((Tcl_ObjectContext) contextPtr); if (Tcl_MethodDeclarerObject(method) != NULL) { @@ -1271,7 +1271,7 @@ static void DeleteProcedureMethod( ClientData clientData) { - register ProcedureMethod *pmPtr = clientData; + ProcedureMethod *pmPtr = clientData; if (pmPtr->refCount-- <= 1) { DeleteProcedureMethodRecord(pmPtr); @@ -1364,7 +1364,7 @@ TclOONewForwardInstanceMethod( * prefix to forward to. */ { int prefixLen; - register ForwardMethod *fmPtr; + ForwardMethod *fmPtr; if (Tcl_ListObjLength(interp, prefixObj, &prefixLen) != TCL_OK) { return NULL; @@ -1403,7 +1403,7 @@ TclOONewForwardMethod( * prefix to forward to. */ { int prefixLen; - register ForwardMethod *fmPtr; + ForwardMethod *fmPtr; if (Tcl_ListObjLength(interp, prefixObj, &prefixLen) != TCL_OK) { return NULL; diff --git a/generic/tclParse.c b/generic/tclParse.c index 57b2b35..5bbaf93 100644 --- a/generic/tclParse.c +++ b/generic/tclParse.c @@ -236,19 +236,19 @@ Tcl_ParseCommand( * NULL, then no error message is provided. */ const char *start, /* First character of string containing one or * more Tcl commands. */ - register int numBytes, /* Total number of bytes in string. If < 0, + int numBytes, /* Total number of bytes in string. If < 0, * the script consists of all bytes up to the * first null character. */ int nested, /* Non-zero means this is a nested command: * close bracket should be considered a * command terminator. If zero, then close * bracket has no special meaning. */ - register Tcl_Parse *parsePtr) + Tcl_Parse *parsePtr) /* Structure to fill in with information about * the parsed command; any previous * information in the structure is ignored. */ { - register const char *src; /* Points to current character in the + const char *src; /* Points to current character in the * command. */ char type; /* Result returned by CHAR_TYPE(*src). */ Tcl_Token *tokenPtr; /* Pointer to token being filled in. */ @@ -684,14 +684,14 @@ TclIsBareword( static int ParseWhiteSpace( const char *src, /* First character to parse. */ - register int numBytes, /* Max number of bytes to scan. */ + int numBytes, /* Max number of bytes to scan. */ int *incompletePtr, /* Set this boolean memory to true if parsing * indicates an incomplete command. */ char *typePtr) /* Points to location to store character type * of character that ends run of whitespace */ { - register char type = TYPE_NORMAL; - register const char *p = src; + char type = TYPE_NORMAL; + const char *p = src; while (1) { while (numBytes && ((type = CHAR_TYPE(*p)) & TYPE_SPACE)) { @@ -784,7 +784,7 @@ ParseHex( * conversion is to be written. */ { int result = 0; - register const char *p = src; + const char *p = src; while (numBytes--) { unsigned char digit = UCHAR(*p); @@ -842,7 +842,7 @@ TclParseBackslash( * written. At most TCL_UTF_MAX bytes will be * written there. */ { - register const char *p = src+1; + const char *p = src+1; int result; int count; char buf[TCL_UTF_MAX] = ""; @@ -1037,12 +1037,12 @@ TclParseBackslash( static int ParseComment( const char *src, /* First character to parse. */ - register int numBytes, /* Max number of bytes to scan. */ + int numBytes, /* Max number of bytes to scan. */ Tcl_Parse *parsePtr) /* Information about parse in progress. * Updated if parsing indicates an incomplete * command. */ { - register const char *p = src; + const char *p = src; while (numBytes) { char type; @@ -1121,8 +1121,8 @@ ParseComment( static int ParseTokens( - register const char *src, /* First character to parse. */ - register int numBytes, /* Max number of bytes to scan. */ + const char *src, /* First character to parse. */ + int numBytes, /* Max number of bytes to scan. */ int mask, /* Specifies when to stop parsing. The parse * stops at the first unquoted character whose * CHAR_TYPE contains any of the bits in @@ -1400,7 +1400,7 @@ Tcl_ParseVarName( * NULL, then no error message is provided. */ const char *start, /* Start of variable substitution string. * First character must be "$". */ - register int numBytes, /* Total number of bytes in string. If < 0, + int numBytes, /* Total number of bytes in string. If < 0, * the string consists of all bytes up to the * first null character. */ Tcl_Parse *parsePtr, /* Structure to fill in with information about @@ -1411,7 +1411,7 @@ Tcl_ParseVarName( * reinitialize it. */ { Tcl_Token *tokenPtr; - register const char *src; + const char *src; int varIndex; unsigned array; @@ -1592,13 +1592,13 @@ Tcl_ParseVarName( const char * Tcl_ParseVar( Tcl_Interp *interp, /* Context for looking up variable. */ - register const char *start, /* Start of variable substitution. First + const char *start, /* Start of variable substitution. First * character must be "$". */ const char **termPtr) /* If non-NULL, points to word to fill in with * character just after last one in the * variable specifier. */ { - register Tcl_Obj *objPtr; + Tcl_Obj *objPtr; int code; Tcl_Parse *parsePtr = TclStackAlloc(interp, sizeof(Tcl_Parse)); @@ -1677,10 +1677,10 @@ Tcl_ParseBraces( * NULL, then no error message is provided. */ const char *start, /* Start of string enclosed in braces. The * first character must be {'. */ - register int numBytes, /* Total number of bytes in string. If < 0, + int numBytes, /* Total number of bytes in string. If < 0, * the string consists of all bytes up to the * first null character. */ - register Tcl_Parse *parsePtr, + Tcl_Parse *parsePtr, /* Structure to fill in with information about * the string. */ int append, /* Non-zero means append tokens to existing @@ -1693,7 +1693,7 @@ Tcl_ParseBraces( * successful. */ { Tcl_Token *tokenPtr; - register const char *src; + const char *src; int startIndex, level, length; if (numBytes < 0 && start) { @@ -1818,7 +1818,7 @@ Tcl_ParseBraces( */ { - register int openBrace = 0; + int openBrace = 0; while (--src > start) { switch (*src) { @@ -1878,10 +1878,10 @@ Tcl_ParseQuotedString( * NULL, then no error message is provided. */ const char *start, /* Start of the quoted string. The first * character must be '"'. */ - register int numBytes, /* Total number of bytes in string. If < 0, + int numBytes, /* Total number of bytes in string. If < 0, * the string consists of all bytes up to the * first null character. */ - register Tcl_Parse *parsePtr, + Tcl_Parse *parsePtr, /* Structure to fill in with information about * the string. */ int append, /* Non-zero means append tokens to existing diff --git a/generic/tclPipe.c b/generic/tclPipe.c index bd49bec..7d5fab0 100644 --- a/generic/tclPipe.c +++ b/generic/tclPipe.c @@ -183,7 +183,7 @@ Tcl_DetachPids( * array pointed to by pidPtr. */ Tcl_Pid *pidPtr) /* Array of pids to detach. */ { - register Detached *detPtr; + Detached *detPtr; int i; Tcl_MutexLock(&pipeMutex); @@ -219,7 +219,7 @@ Tcl_DetachPids( void Tcl_ReapDetachedProcs(void) { - register Detached *detPtr; + Detached *detPtr; Detached *nextPtr, *prevPtr; int status; Tcl_Pid pid; diff --git a/generic/tclStrToD.c b/generic/tclStrToD.c index 749abcf..2e66864 100644 --- a/generic/tclStrToD.c +++ b/generic/tclStrToD.c @@ -2849,7 +2849,7 @@ QuickConversion( } ilim = ilim1; --k; - d *= 10.0; + d = d * 10.0; ++ieps; } @@ -2866,7 +2866,7 @@ QuickConversion( retval = ckalloc(len + 1); if (ilim == 0) { - d -= 5.; + d = d - 5.; if (d > eps.d) { *retval = '1'; *decpt = k; diff --git a/generic/tclStubInit.c b/generic/tclStubInit.c index bab9d5e..51e6a81 100644 --- a/generic/tclStubInit.c +++ b/generic/tclStubInit.c @@ -370,7 +370,7 @@ static Tcl_Obj *dbNewLongObj( int line ) { #ifdef TCL_MEM_DEBUG - register Tcl_Obj *objPtr; + Tcl_Obj *objPtr; TclDbNewObj(objPtr, file, line); objPtr->bytes = NULL; diff --git a/generic/tclThreadAlloc.c b/generic/tclThreadAlloc.c index 2ee758e..5a1e8ca 100644 --- a/generic/tclThreadAlloc.c +++ b/generic/tclThreadAlloc.c @@ -257,7 +257,7 @@ TclFreeAllocCache( { Cache *cachePtr = arg; Cache **nextPtrPtr; - register unsigned int bucket; + unsigned int bucket; /* * Flush blocks. @@ -314,7 +314,7 @@ TclpAlloc( { Cache *cachePtr; Block *blockPtr; - register int bucket; + int bucket; size_t size; #ifndef __LP64__ @@ -546,8 +546,8 @@ TclpRealloc( Tcl_Obj * TclThreadAllocObj(void) { - register Cache *cachePtr; - register Tcl_Obj *objPtr; + Cache *cachePtr; + Tcl_Obj *objPtr; GETCACHE(cachePtr); @@ -557,7 +557,7 @@ TclThreadAllocObj(void) */ if (cachePtr->numObjects == 0) { - register int numMove; + int numMove; Tcl_MutexLock(objLockPtr); numMove = sharedPtr->numObjects; @@ -718,7 +718,7 @@ MoveObjs( Cache *toPtr, int numMove) { - register Tcl_Obj *objPtr = fromPtr->firstObjPtr; + Tcl_Obj *objPtr = fromPtr->firstObjPtr; Tcl_Obj *fromFirstObjPtr = objPtr; toPtr->numObjects += numMove; @@ -819,7 +819,7 @@ Block2Ptr( int bucket, unsigned int reqSize) { - register void *ptr; + void *ptr; blockPtr->magicNum1 = blockPtr->magicNum2 = MAGIC; blockPtr->sourceBucket = bucket; @@ -835,7 +835,7 @@ static Block * Ptr2Block( char *ptr) { - register Block *blockPtr; + Block *blockPtr; blockPtr = (((Block *) ptr) - 1); if (blockPtr->magicNum1 != MAGIC || blockPtr->magicNum2 != MAGIC) { @@ -969,8 +969,8 @@ GetBlocks( Cache *cachePtr, int bucket) { - register Block *blockPtr; - register int n; + Block *blockPtr; + int n; /* * First, atttempt to move blocks from the shared cache. Note the @@ -1015,7 +1015,7 @@ GetBlocks( } if (cachePtr->buckets[bucket].numFree == 0) { - register size_t size; + size_t size; /* * If no blocks could be moved from shared, first look for a larger diff --git a/unix/tclUnixCompat.c b/unix/tclUnixCompat.c index 451a409..00e9737 100644 --- a/unix/tclUnixCompat.c +++ b/unix/tclUnixCompat.c @@ -556,17 +556,17 @@ TclpGetHostByName( ThreadSpecificData *tsdPtr = TCL_TSD_INIT(&dataKey); #if defined(HAVE_GETHOSTBYNAME_R_5) - int h_errno; + int local_errno; return gethostbyname_r(name, &tsdPtr->hent, tsdPtr->hbuf, - sizeof(tsdPtr->hbuf), &h_errno); + sizeof(tsdPtr->hbuf), &local_errno); #elif defined(HAVE_GETHOSTBYNAME_R_6) struct hostent *hePtr = NULL; - int h_errno, result; + int local_errno, result; result = gethostbyname_r(name, &tsdPtr->hent, tsdPtr->hbuf, - sizeof(tsdPtr->hbuf), &hePtr, &h_errno); + sizeof(tsdPtr->hbuf), &hePtr, &local_errno); return (result == 0) ? hePtr : NULL; #elif defined(HAVE_GETHOSTBYNAME_R_3) @@ -626,17 +626,17 @@ TclpGetHostByAddr( ThreadSpecificData *tsdPtr = TCL_TSD_INIT(&dataKey); #if defined(HAVE_GETHOSTBYADDR_R_7) - int h_errno; + int local_errno; return gethostbyaddr_r(addr, length, type, &tsdPtr->hent, tsdPtr->hbuf, - sizeof(tsdPtr->hbuf), &h_errno); + sizeof(tsdPtr->hbuf), &local_errno); #elif defined(HAVE_GETHOSTBYADDR_R_8) struct hostent *hePtr; - int h_errno; + int local_errno; return (gethostbyaddr_r(addr, length, type, &tsdPtr->hent, tsdPtr->hbuf, - sizeof(tsdPtr->hbuf), &hePtr, &h_errno) == 0) + sizeof(tsdPtr->hbuf), &hePtr, &local_errno) == 0) ? &tsdPtr->hent : NULL; #else #define NEED_COPYHOSTENT 1 -- cgit v0.12 From 2ed258bb674b5894ae0d21fe8405234b97731dbe Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Fri, 27 Nov 2020 07:41:58 +0000 Subject: Fix winFCmd testcase. Add --disable-shared and TCL_UTF_MAX=4 builds to github actions --- .github/workflows/linux-build.yml | 1 + .github/workflows/mac-build.yml | 22 +++++++++------------- .github/workflows/win-build.yml | 13 +++++++------ tests/winFCmd.test | 34 +++++----------------------------- 4 files changed, 22 insertions(+), 48 deletions(-) diff --git a/.github/workflows/linux-build.yml b/.github/workflows/linux-build.yml index a620aa9..e8fab61 100644 --- a/.github/workflows/linux-build.yml +++ b/.github/workflows/linux-build.yml @@ -10,6 +10,7 @@ jobs: - "--disable-shared" - "--enable-symbols" - "--enable-symbols=mem" + - "CFLAGS=-DTCL_UTF_MAX=4" defaults: run: shell: bash diff --git a/.github/workflows/mac-build.yml b/.github/workflows/mac-build.yml index c9bec7e..5029794 100644 --- a/.github/workflows/mac-build.yml +++ b/.github/workflows/mac-build.yml @@ -24,12 +24,11 @@ jobs: runs-on: macos-10.15 strategy: matrix: - symbols: - - "no" - - "mem" - dtrace: - - "no" - - "yes" + cfgopt: + - "" + - "--disable-shared" + - "--enable-symbols" + - "--enable-symbols=mem" defaults: run: shell: bash @@ -39,14 +38,14 @@ jobs: uses: actions/checkout@v2 - name: Prepare run: | - touch tclStubInit.c tclOOStubInit.c + touch tclStubInit.c mkdir "$HOME/install" working-directory: generic - - name: Configure (symbols=${{ matrix.symbols }} dtrace=${{ matrix.dtrace }}) + - name: Configure ${{ matrix.cfgopt }} # Note that macOS is always a 64 bit platform - run: ./configure --enable-64bit --enable-framework ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1) + run: ./configure --enable-64bit --enable-dtrace --enable-framework ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1) env: - CFGOPT: --enable-symbols=${{ matrix.symbols }} --enable-dtrace=${{ matrix.dtrace }} + CFGOPT: ${{ matrix.cfgopt }} - name: Build run: | make all tcltest @@ -56,6 +55,3 @@ jobs: env: ERROR_ON_FAILURES: 1 MAC_CI: 1 - - name: Trial Installation - run: | - make install diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml index 7e9c416..5e6b6ba 100644 --- a/.github/workflows/win-build.yml +++ b/.github/workflows/win-build.yml @@ -41,10 +41,11 @@ jobs: working-directory: win strategy: matrix: - symbols: - - "no" - - "mem" - - "all" + cfgopt: + - "" + - "--disable-shared" + - "--enable-symbols" + - "--enable-symbols=mem" # Using powershell means we need to explicitly stop on failure steps: - name: Checkout @@ -56,11 +57,11 @@ jobs: touch tclStubInit.c mkdir "${HOME}/install" working-directory: generic - - name: Configure (symbols=${{ matrix.symbols }}) + - name: Configure (symbols=${{ matrix.cfgopt }}) run: | ./configure ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1) env: - CFGOPT: --enable-64bit --enable-symbols=${{ matrix.symbols }} + CFGOPT: --enable-64bit ${{ matrix.cfgopt }} - name: Build run: make all - name: Build Test Harness diff --git a/tests/winFCmd.test b/tests/winFCmd.test index f93f225..6256fda 100644 --- a/tests/winFCmd.test +++ b/tests/winFCmd.test @@ -1033,18 +1033,16 @@ if {$d eq "C"} { set dd "D" } else { set dd "C" } test winFCmd-16.10 {Windows file normalization} {win} { file norm ${dd}:foo } "${dd}:/foo" -test winFCmd-16.11 {Windows file normalization} -constraints {win cdrom} \ --body { +test winFCmd-16.11 {Windows file normalization} -body { cd ${d}: cd $cdrom cd ${d}: cd $cdrom # Must not crash set result "no crash" -} -cleanup { +} -constraints {win cdrom} -cleanup { cd $pwd } -result {no crash} - test winFCmd-16.12 {Windows file normalization - no crash} \ -constraints win -setup { set oldhome "" @@ -1060,7 +1058,6 @@ test winFCmd-16.12 {Windows file normalization - no crash} \ set ::env(HOME) $oldhome cd $pwd } -result {no crash} - test winFCmd-16.13 {Windows file normalization} -constraints win -setup { set oldhome "" catch {set oldhome $::env(HOME)} @@ -1104,7 +1101,7 @@ test winFCmd-17.1 {Windows bad permissions cd} -constraints win -body { eval lappend d [glob -nocomplain \ -types hidden -dir $dd "System Volume Information"] } - # Old versions of Tcl gave a misleading error that the + # Old versions of Tcl gave a misleading error that the # directory in question didn't exist. if {[llength $d] && [catch {cd [lindex $d 0]} err]} { regsub ".*: " $err "" err @@ -1122,68 +1119,52 @@ unset d dd pwd test winFCmd-18.1 {Windows reserved path names} -constraints win -body { file pathtype com1 } -result "absolute" - test winFCmd-18.1.2 {Windows reserved path names} -constraints win -body { file pathtype com4 } -result "absolute" - test winFCmd-18.1.3 {Windows reserved path names} -constraints win -body { file pathtype com9 } -result "absolute" - test winFCmd-18.1.4 {Windows reserved path names} -constraints win -body { file pathtype lpt3 } -result "absolute" - test winFCmd-18.1.5 {Windows reserved path names} -constraints win -body { file pathtype lpt9 } -result "absolute" - test winFCmd-18.1.6 {Windows reserved path names} -constraints win -body { file pathtype nul } -result "absolute" - test winFCmd-18.1.7 {Windows reserved path names} -constraints win -body { file pathtype null } -result "relative" - test winFCmd-18.2 {Windows reserved path names} -constraints win -body { file pathtype com1: } -result "absolute" - test winFCmd-18.3 {Windows reserved path names} -constraints win -body { file pathtype COM1 } -result "absolute" - test winFCmd-18.4 {Windows reserved path names} -constraints win -body { file pathtype CoM1: } -result "absolute" - test winFCmd-18.5 {Windows reserved path names} -constraints win -body { file normalize com1: } -result COM1 - test winFCmd-18.6 {Windows reserved path names} -constraints win -body { file normalize COM1: } -result COM1 - test winFCmd-18.7 {Windows reserved path names} -constraints win -body { file normalize cOm1 } -result COM1 - test winFCmd-18.8 {Windows reserved path names} -constraints win -body { file normalize cOm1: } -result COM1 - test winFCmd-19.1 {Windows extended path names} -constraints nt -body { file normalize //?/c:/windows/win.ini } -result //?/c:/windows/win.ini - test winFCmd-19.2 {Windows extended path names} -constraints nt -body { file normalize //?/c:/windows/../windows/win.ini } -result //?/c:/windows/win.ini - test winFCmd-19.3 {Windows extended path names} -constraints nt -setup { set tmpfile [file join $::env(TEMP) tcl[string repeat x 20].tmp] set tmpfile [file normalize $tmpfile] @@ -1195,7 +1176,6 @@ test winFCmd-19.3 {Windows extended path names} -constraints nt -setup { } -cleanup { catch {file delete $tmpfile} } -result [list 0 {}] - test winFCmd-19.4 {Windows extended path names} -constraints nt -setup { set tmpfile [file join $::env(TEMP) tcl[string repeat x 20].tmp] set tmpfile //?/[file normalize $tmpfile] @@ -1207,7 +1187,6 @@ test winFCmd-19.4 {Windows extended path names} -constraints nt -setup { } -cleanup { catch {file delete $tmpfile} } -result [list 0 {}] - test winFCmd-19.5 {Windows extended path names} -constraints nt -setup { set tmpfile [file join $::env(TEMP) tcl[string repeat x 248].tmp] set tmpfile [file normalize $tmpfile] @@ -1215,11 +1194,10 @@ test winFCmd-19.5 {Windows extended path names} -constraints nt -setup { list [catch { set f [open $tmpfile [list WRONLY CREAT]] close $f - } res] errormsg ;#$res + } res] $res } -cleanup { catch {file delete $tmpfile} -} -result [list 1 errormsg] - +} -result [list 0 {}] test winFCmd-19.6 {Windows extended path names} -constraints nt -setup { set tmpfile [file join $::env(TEMP) tcl[string repeat x 248].tmp] set tmpfile //?/[file normalize $tmpfile] @@ -1231,7 +1209,6 @@ test winFCmd-19.6 {Windows extended path names} -constraints nt -setup { } -cleanup { catch {file delete $tmpfile} } -result [list 0 {}] - test winFCmd-19.7 {Windows extended path names} -constraints nt -setup { set tmpfile [file join $::env(TEMP) "tcl[pid].tmp "] set tmpfile [file normalize $tmpfile] @@ -1243,7 +1220,6 @@ test winFCmd-19.7 {Windows extended path names} -constraints nt -setup { } -cleanup { catch {file delete $tmpfile} } -result [list 0 {} [list tcl[pid].tmp]] - test winFCmd-19.8 {Windows extended path names} -constraints nt -setup { set tmpfile [file join $::env(TEMP) "tcl[pid].tmp "] set tmpfile //?/[file normalize $tmpfile] -- cgit v0.12 From 5bf4c011e1e583ad9be1bae5a6e38cae7cbb81e7 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Fri, 27 Nov 2020 14:28:18 +0000 Subject: label change in win-build.yml --- .github/workflows/win-build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml index 5e6b6ba..2aeccaf 100644 --- a/.github/workflows/win-build.yml +++ b/.github/workflows/win-build.yml @@ -57,7 +57,7 @@ jobs: touch tclStubInit.c mkdir "${HOME}/install" working-directory: generic - - name: Configure (symbols=${{ matrix.cfgopt }}) + - name: Configure ${{ matrix.cfgopt }} run: | ./configure ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1) env: -- cgit v0.12 From 15194461b1ae5479887c7348dfcba4c11a01fe30 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Mon, 30 Nov 2020 08:21:20 +0000 Subject: Cherry-pick part of "msys2-fixes_v001" branch: build/test fixes for msys2 --- tests/env.test | 4 ++-- unix/configure | 4 ++-- unix/tcl.m4 | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/env.test b/tests/env.test index a7aa162..1824ebc 100644 --- a/tests/env.test +++ b/tests/env.test @@ -84,7 +84,7 @@ set printenvScript [makeFile { foreach name { TCL_LIBRARY PATH LD_LIBRARY_PATH LIBPATH PURE_PROG_NAME DISPLAY SHLIB_PATH SYSTEMDRIVE SYSTEMROOT DYLD_LIBRARY_PATH DYLD_FRAMEWORK_PATH - DYLD_NEW_LOCAL_SHARED_REGIONS DYLD_NO_FIX_PREBINDING + DYLD_NEW_LOCAL_SHARED_REGIONS DYLD_NO_FIX_PREBINDING MSYSTEM __CF_USER_TEXT_ENCODING SECURITYSESSIONID LANG WINDIR TERM CommonProgramFiles ProgramFiles CommonProgramW6432 ProgramW6432 } { @@ -116,7 +116,7 @@ foreach name [array names env] { if {[string toupper $name] ni { TCL_LIBRARY PATH LD_LIBRARY_PATH LIBPATH DISPLAY SHLIB_PATH SYSTEMDRIVE SYSTEMROOT DYLD_LIBRARY_PATH DYLD_FRAMEWORK_PATH - DYLD_NEW_LOCAL_SHARED_REGIONS DYLD_NO_FIX_PREBINDING + DYLD_NEW_LOCAL_SHARED_REGIONS DYLD_NO_FIX_PREBINDING MSYSTEM SECURITYSESSIONID LANG WINDIR TERM CONNOMPROGRAMFILES PROGRAMFILES COMMONPROGRAMW6432 PROGRAMW6432 }} { diff --git a/unix/configure b/unix/configure index 1c0c2be..1e48efa 100755 --- a/unix/configure +++ b/unix/configure @@ -6931,7 +6931,7 @@ fi CC_SEARCH_FLAGS="" LD_SEARCH_FLAGS="" ;; - CYGWIN_*|MINGW32*) + CYGWIN_*|MINGW32*|MSYS_*) SHLIB_CFLAGS="" SHLIB_LD='${CC} -shared' SHLIB_SUFFIX=".dll" @@ -8853,7 +8853,7 @@ fi case $system in AIX-*) ;; BSD/OS*) ;; - CYGWIN_*|MINGW32_*) ;; + CYGWIN_*|MINGW32*|MSYS_*) ;; IRIX*) ;; NetBSD-*|DragonFly-*|FreeBSD-*|OpenBSD-*) ;; Darwin-*) ;; diff --git a/unix/tcl.m4 b/unix/tcl.m4 index 4c96316..449d7af 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 @@ -1247,7 +1247,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ CC_SEARCH_FLAGS="" LD_SEARCH_FLAGS="" ;; - CYGWIN_*|MINGW32*) + CYGWIN_*|MINGW32*|MSYS_*) SHLIB_CFLAGS="" SHLIB_LD='${CC} -shared' SHLIB_SUFFIX=".dll" @@ -2060,7 +2060,7 @@ dnl # preprocessing tests use only CPPFLAGS. case $system in AIX-*) ;; BSD/OS*) ;; - CYGWIN_*|MINGW32_*) ;; + CYGWIN_*|MINGW32_*|MSYS_*) ;; IRIX*) ;; NetBSD-*|DragonFly-*|FreeBSD-*|OpenBSD-*) ;; Darwin-*) ;; -- cgit v0.12 From eb342fb1e00f5aa398c9e889ac6a7e47d1ab5e5b Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Mon, 30 Nov 2020 08:52:04 +0000 Subject: Update README.md --- README.md | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/README.md b/README.md index fd4ef2a..ce7298e 100644 --- a/README.md +++ b/README.md @@ -5,20 +5,9 @@ This is the **Tcl 8.6.10** source distribution. You can get any source release of Tcl from [our distribution site](https://sourceforge.net/projects/tcl/files/Tcl/). -8.6.10 -[![Build Status](https://github.com/tcltk/tcl/workflows/Linux%20Build%20and%20Test/badge.svg?branch=core-8-6-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Linux+Build+and+Test%22+branch%3Acore-8-6-branch) -[![Build Status](https://github.com/tcltk/tcl/workflows/Windows%20Build%20and%20Test/badge.svg?branch=core-8-6-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Windows+Build+and+Test%22+branch%3Acore-8-6-branch) -[![Build Status](https://github.com/tcltk/tcl/workflows/macOS%20Build%20and%20Test/badge.svg?branch=core-8-6-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22macOS+Build+and+Test%22+branch%3Acore-8-6-branch) -
-8.7a4 -[![Build Status](https://github.com/tcltk/tcl/workflows/Linux%20Build%20and%20Test/badge.svg?branch=core-8-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Linux+Build+and+Test%22+branch%3Acore-8-branch) -[![Build Status](https://github.com/tcltk/tcl/workflows/Windows%20Build%20and%20Test/badge.svg?branch=core-8-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Windows+Build+and+Test%22+branch%3Acore-8-branch) -[![Build Status](https://github.com/tcltk/tcl/workflows/macOS%20Build%20and%20Test/badge.svg?branch=core-8-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22macOS+Build+and+Test%22+branch%3Acore-8-branch) -
-9.0a2 -[![Build Status](https://github.com/tcltk/tcl/workflows/Linux%20Build%20and%20Test/badge.svg?branch=main)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Linux+Build+and+Test%22+branch%3Amain) -[![Build Status](https://github.com/tcltk/tcl/workflows/Windows%20Build%20and%20Test/badge.svg?branch=main)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Windows+Build+and+Test%22+branch%3Amain) -[![Build Status](https://github.com/tcltk/tcl/workflows/macOS%20Build%20and%20Test/badge.svg?branch=main)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22macOS+Build+and+Test%22+branch%3Amain) +[![Build Status](https://github.com/tcltk/tcl/workflows/Linux/badge.svg?branch=core-8-6-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Linux%22+branch%3Acore-8-6-branch) +[![Build Status](https://github.com/tcltk/tcl/workflows/Windows/badge.svg?branch=core-8-6-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22Windows%22+branch%3Acore-8-6-branch) +[![Build Status](https://github.com/tcltk/tcl/workflows/macOS/badge.svg?branch=core-8-6-branch)](https://github.com/tcltk/tcl/actions?query=workflow%3A%22macOS%22+branch%3Acore-8-6-branch) ## Contents 1. [Introduction](#intro) -- cgit v0.12 From 87439e7d28331cfc8c620fe77d2e696b7e3bb223 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Mon, 30 Nov 2020 13:32:00 +0000 Subject: Fix [b6a7fc9243]. Also add (back) \*(qo, which might be used in older man-pages --- tools/tcltk-man2html-utils.tcl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/tcltk-man2html-utils.tcl b/tools/tcltk-man2html-utils.tcl index 5b2a831..5f8431b 100644 --- a/tools/tcltk-man2html-utils.tcl +++ b/tools/tcltk-man2html-utils.tcl @@ -185,7 +185,6 @@ proc process-text {text} { {\(Tp} "þ" \ {\(em} "—" \ {\(en} "–" \ - {\(bu} "•" \ {\(fm} "′" \ {\(mi} "−" \ {\(.i} "ı" \ @@ -200,6 +199,8 @@ proc process-text {text} { {\(eu} "€" \ {\fP} {\fR} \ {\.} . \ + {\(bu} "•" \ + {\*(qo} "ô" \ ] # This might make a few invalid mappings, but we don't use them foreach c {a c e g i l n o s t u y z A C E G I L N O S T U Y Z} { -- cgit v0.12 From 17de94982b2d1f3b93a9237eb2371fbdd53695cb Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Mon, 30 Nov 2020 14:16:23 +0000 Subject: doc update: 16-bit DOS appllications are not supported any more. Use &bull; in stead of &#8226; representing bullets in html --- doc/exec.n | 15 ++------------- tools/tcltk-man2html-utils.tcl | 8 ++++---- 2 files changed, 6 insertions(+), 17 deletions(-) diff --git a/doc/exec.n b/doc/exec.n index 99dfdc5..04b5269 100644 --- a/doc/exec.n +++ b/doc/exec.n @@ -246,15 +246,6 @@ the backslash character. If an argument contains forward slashes as the path separator, it may or may not be recognized as a path name, depending on the program. .PP -Additionally, when calling a 16-bit DOS or Windows 3.X application, all path -names must use the short, cryptic, path format (e.g., using -.QW applba~1.def -instead of -.QW applbakery.default ), -which can be obtained with the -.QW "\fBfile attributes\fI fileName \fB\-shortname\fR" -command. -.PP Two or more forward or backward slashes in a row in a path refer to a network path. For example, a simple concatenation of the root directory \fBc:/\fR with a subdirectory \fB/windows/system\fR will yield @@ -295,11 +286,9 @@ The directory from which the Tcl executable was loaded. .IP \(bu 3 The current directory. .IP \(bu 3 -The Windows NT 32-bit system directory. -.IP \(bu 3 -The Windows NT 16-bit system directory. +The Windows 32-bit system directory. .IP \(bu 3 -The Windows NT home directory. +The Windows home directory. .IP \(bu 3 The directories listed in the path. .PP diff --git a/tools/tcltk-man2html-utils.tcl b/tools/tcltk-man2html-utils.tcl index 5f8431b..34222e3 100644 --- a/tools/tcltk-man2html-utils.tcl +++ b/tools/tcltk-man2html-utils.tcl @@ -50,7 +50,7 @@ proc indexfile {} { proc copyright {copyright {level {}}} { # We don't actually generate a separate copyright page anymore #set page "${level}copyright.htm" - #return "Copyright © [htmlize-text [lrange $copyright 2 end]]" + #return "Copyright © [htmlize-text [lrange $copyright 2 end]]" # obfuscate any email addresses that may appear in name set who [string map {@ (at)} [lrange $copyright 2 end]] return "Copyright © [htmlize-text $who]" @@ -199,7 +199,7 @@ proc process-text {text} { {\(eu} "€" \ {\fP} {\fR} \ {\.} . \ - {\(bu} "•" \ + {\(bu} "•" \ {\*(qo} "ô" \ ] # This might make a few invalid mappings, but we don't use them @@ -573,7 +573,7 @@ proc output-IP-list {context code rest} { if {[regexp {^\[[\da-f]+\]|\(?[\da-f]+\)$} $rest]} { set dl "
    " set enddl "
" - } elseif {"•" eq $rest} { + } elseif {"•" eq $rest} { set dl "
    " set enddl "
" } @@ -599,7 +599,7 @@ proc output-IP-list {context code rest} { man-puts "$para
  • " } elseif {[regexp {^\(?([\da-f]+)\)$} $rest -> value]} { man-puts "$para
  • " - } elseif {"•" eq $rest} { + } elseif {"•" eq $rest} { man-puts "$para
  • " } else { man-puts "$para
    [long-toc $rest]
    " -- cgit v0.12 From fa960af76021db9b505bcf86ebb894073b6db99d Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Mon, 30 Nov 2020 16:52:50 +0000 Subject: Minor fixes + copy editing :). See [https://github.com/tcltk/tcl/pull/8] --- README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index ce7298e..742a3e6 100644 --- a/README.md +++ b/README.md @@ -31,19 +31,19 @@ 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. ## 2. 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/8.6.html). Detailed release notes can be found at the @@ -90,16 +90,16 @@ about building Tcl from sources [online](https://www.tcl-lang.org/doc/howto/compile.html). ## 4. 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 ## 5. 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. -- cgit v0.12 From 53a9a5dc8fdd7aac66544c1c0db83f8943ed8ba6 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Tue, 1 Dec 2020 08:49:30 +0000 Subject: Missing '_' in unix/tcl.m4 (Only relevant for mingw) --- unix/configure | 4 ++-- unix/tcl.m4 | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/unix/configure b/unix/configure index 1e48efa..c0f6d5b 100755 --- a/unix/configure +++ b/unix/configure @@ -6931,7 +6931,7 @@ fi CC_SEARCH_FLAGS="" LD_SEARCH_FLAGS="" ;; - CYGWIN_*|MINGW32*|MSYS_*) + CYGWIN_*|MINGW32_*|MSYS_*) SHLIB_CFLAGS="" SHLIB_LD='${CC} -shared' SHLIB_SUFFIX=".dll" @@ -8853,7 +8853,7 @@ fi case $system in AIX-*) ;; BSD/OS*) ;; - CYGWIN_*|MINGW32*|MSYS_*) ;; + CYGWIN_*|MINGW32_*|MSYS_*) ;; IRIX*) ;; NetBSD-*|DragonFly-*|FreeBSD-*|OpenBSD-*) ;; Darwin-*) ;; diff --git a/unix/tcl.m4 b/unix/tcl.m4 index 449d7af..0a76b0d 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 @@ -1247,7 +1247,7 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ CC_SEARCH_FLAGS="" LD_SEARCH_FLAGS="" ;; - CYGWIN_*|MINGW32*|MSYS_*) + CYGWIN_*|MINGW32_*|MSYS_*) SHLIB_CFLAGS="" SHLIB_LD='${CC} -shared' SHLIB_SUFFIX=".dll" -- cgit v0.12 From d9fa72d22a6c7c823f0267fdabce5a9f307a7743 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Tue, 1 Dec 2020 11:54:35 +0000 Subject: Handle 5 test-failures on Cygwin/Msys --- tests/winFCmd.test | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/winFCmd.test b/tests/winFCmd.test index 04c4fd9..500b114 100644 --- a/tests/winFCmd.test +++ b/tests/winFCmd.test @@ -5,7 +5,7 @@ # generates output for errors. No output means no errors were found. # # Copyright (c) 1996-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. +# Copyright (c) 1998-1999 Scriptics Corporation. # # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. @@ -1383,7 +1383,7 @@ test winFCmd-19.3 {Windows extended path names} -constraints nt -setup { } -cleanup { catch {file delete $tmpfile} } -result [list 0 {}] -test winFCmd-19.4 {Windows extended path names} -constraints nt -setup { +test winFCmd-19.4 {Windows extended path names} -constraints {win nt} -setup { set tmpfile [file join $::env(TEMP) tcl[string repeat x 20].tmp] set tmpfile //?/[file normalize $tmpfile] } -body { @@ -1405,7 +1405,7 @@ test winFCmd-19.5 {Windows extended path names} -constraints nt -setup { } -cleanup { catch {file delete $tmpfile} } -result [list 0 {}] -test winFCmd-19.6 {Windows extended path names} -constraints nt -setup { +test winFCmd-19.6 {Windows extended path names} -constraints {win nt} -setup { set tmpfile [file join $::env(TEMP) tcl[string repeat x 248].tmp] set tmpfile //?/[file normalize $tmpfile] } -body { @@ -1416,7 +1416,7 @@ test winFCmd-19.6 {Windows extended path names} -constraints nt -setup { } -cleanup { catch {file delete $tmpfile} } -result [list 0 {}] -test winFCmd-19.7 {Windows extended path names} -constraints nt -setup { +test winFCmd-19.7 {Windows extended path names} -constraints {win nt} -setup { set tmpfile [file join $::env(TEMP) "tcl[pid].tmp "] set tmpfile [file normalize $tmpfile] } -body { @@ -1427,7 +1427,7 @@ test winFCmd-19.7 {Windows extended path names} -constraints nt -setup { } -cleanup { catch {file delete $tmpfile} } -result [list 0 {} [list tcl[pid].tmp]] -test winFCmd-19.8 {Windows extended path names} -constraints nt -setup { +test winFCmd-19.8 {Windows extended path names} -constraints {win nt} -setup { set tmpfile [file join $::env(TEMP) "tcl[pid].tmp "] set tmpfile //?/[file normalize $tmpfile] } -body { @@ -1439,7 +1439,7 @@ test winFCmd-19.8 {Windows extended path names} -constraints nt -setup { catch {file delete $tmpfile} } -result [list 0 {} [list "tcl[pid].tmp "]] -test winFCmd-19.9 {Windows devices path names} -constraints nt -body { +test winFCmd-19.9 {Windows devices path names} -constraints {win nt} -body { file normalize //./com1 } -result //./com1 -- cgit v0.12 From fc7a2d97e0d4c2c2bfc5c978843c1126cdc441b1 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Tue, 1 Dec 2020 16:25:30 +0000 Subject: Remove redunant piece of SC_ENABLE_SHARED: The AC_ARG_ENABLE already generates this part, resulting in duplicate code in the "configure" script --- unix/configure | 8 -------- unix/tcl.m4 | 8 -------- win/configure | 8 -------- win/tcl.m4 | 8 -------- 4 files changed, 32 deletions(-) diff --git a/unix/configure b/unix/configure index c0f6d5b..b8c95f4 100755 --- a/unix/configure +++ b/unix/configure @@ -6277,14 +6277,6 @@ if test "${enable_shared+set}" = set; then else tcl_ok=yes fi; - - if test "${enable_shared+set}" = set; then - enableval="$enable_shared" - tcl_ok=$enableval - else - tcl_ok=yes - fi - if test "$tcl_ok" = "yes" ; then echo "$as_me:$LINENO: result: shared" >&5 echo "${ECHO_T}shared" >&6 diff --git a/unix/tcl.m4 b/unix/tcl.m4 index 0a76b0d..57df84d 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 @@ -534,14 +534,6 @@ AC_DEFUN([SC_ENABLE_SHARED], [ AC_HELP_STRING([--enable-shared], [build and link with shared libraries (default: on)]), [tcl_ok=$enableval], [tcl_ok=yes]) - - if test "${enable_shared+set}" = set; then - enableval="$enable_shared" - tcl_ok=$enableval - else - tcl_ok=yes - fi - if test "$tcl_ok" = "yes" ; then AC_MSG_RESULT([shared]) SHARED_BUILD=1 diff --git a/win/configure b/win/configure index 019fa72..1ad2225 100755 --- a/win/configure +++ b/win/configure @@ -3126,14 +3126,6 @@ if test "${enable_shared+set}" = set; then else tcl_ok=yes fi; - - if test "${enable_shared+set}" = set; then - enableval="$enable_shared" - tcl_ok=$enableval - else - tcl_ok=yes - fi - if test "$tcl_ok" = "yes" ; then echo "$as_me:$LINENO: result: shared" >&5 echo "${ECHO_T}shared" >&6 diff --git a/win/tcl.m4 b/win/tcl.m4 index 4932788..8704378 100644 --- a/win/tcl.m4 +++ b/win/tcl.m4 @@ -364,14 +364,6 @@ AC_DEFUN([SC_ENABLE_SHARED], [ AC_ARG_ENABLE(shared, [ --enable-shared build and link with shared libraries (default: on)], [tcl_ok=$enableval], [tcl_ok=yes]) - - if test "${enable_shared+set}" = set; then - enableval="$enable_shared" - tcl_ok=$enableval - else - tcl_ok=yes - fi - if test "$tcl_ok" = "yes" ; then AC_MSG_RESULT([shared]) SHARED_BUILD=1 -- cgit v0.12 From 2f8611013d1b61ea5656aacaf27909eaee6e528f Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Tue, 1 Dec 2020 16:35:59 +0000 Subject: Do 4 types of windows builds (just as we did on Travis) --- .github/workflows/win-build.yml | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml index 2aeccaf..f59b2d7 100644 --- a/.github/workflows/win-build.yml +++ b/.github/workflows/win-build.yml @@ -7,6 +7,13 @@ jobs: run: shell: powershell working-directory: win + strategy: + matrix: + cfgopt: + - "OPTS=threads" + - "OPTS=static,msvcrt,threads" + - "OPTS=symbols,threads" + - "OPTS=memdbg,threads" # Using powershell means we need to explicitly stop on failure steps: - name: Checkout @@ -15,19 +22,19 @@ jobs: uses: ilammy/msvc-dev-cmd@v1 - name: Build run: | - &nmake -f makefile.vc all + &nmake -f makefile.vc ${{ matrix.cfgopt }} all if ($lastexitcode -ne 0) { throw "nmake exit code: $lastexitcode" } - name: Build Test Harness run: | - &nmake -f makefile.vc tcltest + &nmake -f makefile.vc ${{ matrix.cfgopt }} tcltest if ($lastexitcode -ne 0) { throw "nmake exit code: $lastexitcode" } - name: Run Tests run: | - &nmake -f makefile.vc test + &nmake -f makefile.vc ${{ matrix.cfgopt }} test if ($lastexitcode -ne 0) { throw "nmake exit code: $lastexitcode" } @@ -61,7 +68,7 @@ jobs: run: | ./configure ${CFGOPT} "--prefix=$HOME/install" || (cat config.log && exit 1) env: - CFGOPT: --enable-64bit ${{ matrix.cfgopt }} + CFGOPT: --enable-64bit --enable-threads ${{ matrix.cfgopt }} - name: Build run: make all - name: Build Test Harness -- cgit v0.12 From 9727e58e7d335ffd3a43602fbcab4a99e5dc7758 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Tue, 1 Dec 2020 16:41:10 +0000 Subject: Add options to workflow step titles --- .github/workflows/win-build.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/win-build.yml b/.github/workflows/win-build.yml index f59b2d7..637ca7e 100644 --- a/.github/workflows/win-build.yml +++ b/.github/workflows/win-build.yml @@ -20,19 +20,19 @@ jobs: uses: actions/checkout@v2 - name: Init MSVC uses: ilammy/msvc-dev-cmd@v1 - - name: Build + - 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 + - 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 + - name: Run Tests ${{ matrix.cfgopt }} run: | &nmake -f makefile.vc ${{ matrix.cfgopt }} test if ($lastexitcode -ne 0) { -- cgit v0.12 From 02c730b29850204b02de5c9c1e70c52fd0fd9a65 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Wed, 2 Dec 2020 11:19:57 +0000 Subject: 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 --- win/makefile.vc | 3 --- win/rules.vc | 13 ------------- 2 files changed, 16 deletions(-) diff --git a/win/makefile.vc b/win/makefile.vc index f8ac7e2..eaf6888 100644 --- a/win/makefile.vc +++ b/win/makefile.vc @@ -489,9 +489,6 @@ lflags = $(lflags) -nodefaultlib:libucrt.lib !if $(ALIGN98_HACK) && !$(STATIC_BUILD) ### Align sections for PE size savings. lflags = $(lflags) -opt:nowin98 -!else if !$(ALIGN98_HACK) && $(STATIC_BUILD) -### Align sections for speed in loading by choosing the virtual page size. -lflags = $(lflags) -align:4096 !endif !if $(LOIMPACT) diff --git a/win/rules.vc b/win/rules.vc index a4c94ff..753df14 100644 --- a/win/rules.vc +++ b/win/rules.vc @@ -193,19 +193,6 @@ COMPILERFLAGS = $(COMPILERFLAGS) -QIA64_Bx LINKER_TESTFLAGS = /DLL /NOENTRY /OUT:nmhlp-out.txt !endif -!if "$(MACHINE)" == "IX86" -### test for -align:4096, when align:512 will do. -!if [nmakehlp -l -opt:nowin98 $(LINKER_TESTFLAGS)] -!message *** Linker has 'Win98 alignment problem' -ALIGN98_HACK = 1 -!else -!message *** Linker does not have 'Win98 alignment problem' -ALIGN98_HACK = 0 -!endif -!else -ALIGN98_HACK = 0 -!endif - LINKERFLAGS = !if [nmakehlp -l -ltcg $(LINKER_TESTFLAGS)] -- cgit v0.12 From c387e380dea36d13e5809aeea05acb5fa1663830 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Wed, 2 Dec 2020 11:57:04 +0000 Subject: Don't use -opt:nowin98 linker option any more. See: [https://bugzilla.mozilla.org/show_bug.cgi?id=130372] --- win/rules.vc | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/win/rules.vc b/win/rules.vc index f3e5439..ab43909 100644 --- a/win/rules.vc +++ b/win/rules.vc @@ -1481,18 +1481,6 @@ lflags = -nologo -machine:$(MACHINE) $(LINKERFLAGS) $(ldebug) lflags = $(lflags) -nodefaultlib:libucrt.lib !endif -# Old linkers (Visual C++ 6 in particular) will link for fast loading -# on Win98. Since we do not support Win98 any more, we specify nowin98 -# as recommended for NT and later. However, this is only required by -# IX86 on older compilers and only needed if we are not doing a static build. - -!if "$(MACHINE)" == "IX86" && !$(STATIC_BUILD) -!if [nmakehlp -l -opt:nowin98 $(LINKER_TESTFLAGS)] -# Align sections for PE size savings. -lflags = $(lflags) -opt:nowin98 -!endif -!endif - dlllflags = $(lflags) -dll conlflags = $(lflags) -subsystem:console guilflags = $(lflags) -subsystem:windows -- cgit v0.12 From 482091f871d7accfad3e007ec7672a3cb2cc39f1 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Thu, 3 Dec 2020 09:31:00 +0000 Subject: Extend "platform" package for msys2 -> platform 1.0.15 --- library/platform/pkgIndex.tcl | 2 +- library/platform/platform.tcl | 5 ++++- unix/Makefile.in | 4 ++-- win/Makefile.in | 4 ++-- 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/library/platform/pkgIndex.tcl b/library/platform/pkgIndex.tcl index 5970a3f..46a0ed4 100644 --- a/library/platform/pkgIndex.tcl +++ b/library/platform/pkgIndex.tcl @@ -1,3 +1,3 @@ -package ifneeded platform 1.0.14 [list source [file join $dir platform.tcl]] +package ifneeded platform 1.0.15 [list source [file join $dir platform.tcl]] package ifneeded platform::shell 1.1.4 [list source [file join $dir shell.tcl]] diff --git a/library/platform/platform.tcl b/library/platform/platform.tcl index 35a22a3..87d720b 100644 --- a/library/platform/platform.tcl +++ b/library/platform/platform.tcl @@ -97,6 +97,9 @@ proc ::platform::generic {} { cygwin* { set plat cygwin } + msys* { + set plat msystem + } windows { if {$tcl_platform(platform) == "unix"} { set plat cygwin @@ -378,7 +381,7 @@ proc ::platform::patterns {id} { # ### ### ### ######### ######### ######### ## Ready -package provide platform 1.0.14 +package provide platform 1.0.15 # ### ### ### ######### ######### ######### ## Demo application diff --git a/unix/Makefile.in b/unix/Makefile.in index fd44f4e..e29f422 100644 --- a/unix/Makefile.in +++ b/unix/Makefile.in @@ -791,8 +791,8 @@ install-libraries: libraries $(INSTALL_TZDATA) install-msgs @echo "Installing package tcltest 2.5.3 as a Tcl Module"; @$(INSTALL_DATA) $(TOP_DIR)/library/tcltest/tcltest.tcl "$(SCRIPT_INSTALL_DIR)"/../tcl8/8.5/tcltest-2.5.3.tm; - @echo "Installing package platform 1.0.14 as a Tcl Module"; - @$(INSTALL_DATA) $(TOP_DIR)/library/platform/platform.tcl "$(SCRIPT_INSTALL_DIR)"/../tcl8/8.4/platform-1.0.14.tm; + @echo "Installing package platform 1.0.15 as a Tcl Module"; + @$(INSTALL_DATA) $(TOP_DIR)/library/platform/platform.tcl "$(SCRIPT_INSTALL_DIR)"/../tcl8/8.4/platform-1.0.15.tm; @echo "Installing package platform::shell 1.1.4 as a Tcl Module"; @$(INSTALL_DATA) $(TOP_DIR)/library/platform/shell.tcl "$(SCRIPT_INSTALL_DIR)"/../tcl8/8.4/platform/shell-1.1.4.tm; diff --git a/win/Makefile.in b/win/Makefile.in index 8835232..89af617 100644 --- a/win/Makefile.in +++ b/win/Makefile.in @@ -673,8 +673,8 @@ install-libraries: libraries install-tzdata install-msgs @$(COPY) $(ROOT_DIR)/library/msgcat/msgcat.tcl $(SCRIPT_INSTALL_DIR)/../tcl8/8.5/msgcat-1.5.2.tm; @echo "Installing package tcltest 2.5.3 as a Tcl Module"; @$(COPY) $(ROOT_DIR)/library/tcltest/tcltest.tcl $(SCRIPT_INSTALL_DIR)/../tcl8/8.5/tcltest-2.5.3.tm; - @echo "Installing package platform 1.0.14 as a Tcl Module"; - @$(COPY) $(ROOT_DIR)/library/platform/platform.tcl $(SCRIPT_INSTALL_DIR)/../tcl8/8.4/platform-1.0.14.tm; + @echo "Installing package platform 1.0.15 as a Tcl Module"; + @$(COPY) $(ROOT_DIR)/library/platform/platform.tcl $(SCRIPT_INSTALL_DIR)/../tcl8/8.4/platform-1.0.15.tm; @echo "Installing package platform::shell 1.1.4 as a Tcl Module"; @$(COPY) $(ROOT_DIR)/library/platform/shell.tcl $(SCRIPT_INSTALL_DIR)/../tcl8/8.4/platform/shell-1.1.4.tm; @echo "Installing encodings"; -- cgit v0.12 From a3322b06acaf0cf6fef649e67625c47bceb77305 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Thu, 3 Dec 2020 09:37:28 +0000 Subject: Fix syntax error in win/makefile.vc --- win/makefile.vc | 5 ----- 1 file changed, 5 deletions(-) diff --git a/win/makefile.vc b/win/makefile.vc index eaf6888..692d209 100644 --- a/win/makefile.vc +++ b/win/makefile.vc @@ -486,11 +486,6 @@ lflags = $(lflags) -profile lflags = $(lflags) -nodefaultlib:libucrt.lib !endif -!if $(ALIGN98_HACK) && !$(STATIC_BUILD) -### Align sections for PE size savings. -lflags = $(lflags) -opt:nowin98 -!endif - !if $(LOIMPACT) lflags = $(lflags) -ws:aggressive !endif -- cgit v0.12 From defc33228dae46280943ff6cc62d3a4a3284e056 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Thu, 3 Dec 2020 13:51:18 +0000 Subject: 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. --- tests/chanio.test | 4 ++-- tests/cmdAH.test | 14 +++++++------- tests/cmdMZ.test | 2 +- tests/fCmd.test | 48 ++++++++++++++++++++++++------------------------ tests/fileName.test | 4 ++-- tests/fileSystem.test | 2 +- tests/tcltest.test | 4 ++-- tests/unixFCmd.test | 34 +++++++++++++++++----------------- tools/installData.tcl | 4 ++-- 9 files changed, 58 insertions(+), 58 deletions(-) diff --git a/tests/chanio.test b/tests/chanio.test index 1f9e19b..ffb4e91 100644 --- a/tests/chanio.test +++ b/tests/chanio.test @@ -5336,14 +5336,14 @@ test chan-io-40.2 {POSIX open access modes: CREAT} -setup { } -constraints {unix} -body { set f [open $path(test3) {WRONLY CREAT} 0600] file stat $path(test3) stats - set x [format "%#o" [expr {$stats(mode) & 0o777}]] + set x [format 0o%03o [expr {$stats(mode) & 0o777}]] chan puts $f "line 1" chan close $f set f [open $path(test3) r] lappend x [chan gets $f] } -cleanup { chan close $f -} -result {0600 {line 1}} +} -result {0o600 {line 1}} test chan-io-40.3 {POSIX open access modes: CREAT} -setup { file delete $path(test3) } -constraints {unix umask} -body { diff --git a/tests/cmdAH.test b/tests/cmdAH.test index d64ebbb..bb3ad98 100644 --- a/tests/cmdAH.test +++ b/tests/cmdAH.test @@ -965,10 +965,10 @@ test cmdAH-19.11 {Tcl_FileObjCmd: exists} -constraints {unix notRoot} -setup { } -body { makeDirectory /tmp/tcl.foo.dir makeFile 12345 /tmp/tcl.foo.dir/file - file attributes /tmp/tcl.foo.dir -permissions 0000 + file attributes /tmp/tcl.foo.dir -permissions 0o000 file exists /tmp/tcl.foo.dir/file } -cleanup { - file attributes /tmp/tcl.foo.dir -permissions 0775 + file attributes /tmp/tcl.foo.dir -permissions 0o775 removeFile /tmp/tcl.foo.dir/file removeDirectory /tmp/tcl.foo.dir } -result 0 @@ -991,7 +991,7 @@ test cmdAH-19.12 {Bug 3608360: [file exists] mustn't do globbing} -setup { catch {testsetplatform $platform} removeFile $gorpfile set gorpfile [makeFile "Test string" gorp.file] -catch {file attributes $gorpfile -permissions 0765} +catch {file attributes $gorpfile -permissions 0o765} # avoid problems with non-local filesystems if {[testConstraint unix] && [file exists /tmp]} { @@ -1407,7 +1407,7 @@ test cmdAH-27.4.1 { catch {testsetplatform $platform} removeFile $gorpfile set gorpfile [makeFile "Test string" gorp.file] -catch {file attributes $gorpfile -permissions 0765} +catch {file attributes $gorpfile -permissions 0o765} # stat test cmdAH-28.1 {Tcl_FileObjCmd: stat} -returnCodes error -body { @@ -1434,8 +1434,8 @@ test cmdAH-28.5 {Tcl_FileObjCmd: stat} -constraints {unix} -setup { unset -nocomplain stat } -body { file stat $gorpfile stat - expr {$stat(mode) & 0o777} -} -result {501} + format 0o%03o [expr {$stat(mode) & 0o777}] +} -result 0o765 test cmdAH-28.6 {Tcl_FileObjCmd: stat} { list [catch {file stat _bogus_ stat} msg] [string tolower $msg] $errorCode } {1 {could not read "_bogus_": no such file or directory} {POSIX ENOENT {no such file or directory}}} @@ -1715,7 +1715,7 @@ unset -nocomplain platform # Tcl_ForObjCmd is tested in for.test -catch {file attributes $dirfile -permissions 0777} +catch {file attributes $dirfile -permissions 0o777} removeDirectory $dirfile removeFile $gorpfile # No idea how well [removeFile] copes with links... diff --git a/tests/cmdMZ.test b/tests/cmdMZ.test index 0f42f2f..fb2ca4a 100644 --- a/tests/cmdMZ.test +++ b/tests/cmdMZ.test @@ -63,7 +63,7 @@ test cmdMZ-1.4 {Tcl_PwdObjCmd: failure} -setup { # This test fails on various unix platforms (eg Linux) where permissions # caching causes this to fail. The caching is strictly incorrect, but we # have no control over that. - file attr . -permissions 000 + file attr . -permissions 0o000 pwd } -returnCodes error -cleanup { cd $cwd diff --git a/tests/fCmd.test b/tests/fCmd.test index 09f91f7..efffe99 100644 --- a/tests/fCmd.test +++ b/tests/fCmd.test @@ -624,10 +624,10 @@ test fCmd-6.23 {CopyRenameOneFile: TclpCopyDirectory failed} -setup { cleanup $tmpspace } -constraints {xdev notRoot} -body { file mkdir td1/td2/td3 - file attributes td1 -permissions 0000 + file attributes td1 -permissions 0o000 file rename td1 $tmpspace } -returnCodes error -cleanup { - file attributes td1 -permissions 0755 + file attributes td1 -permissions 0o755 cleanup } -match regexp -result {^error renaming "td1"( to "/tmp/tcl\d+/td1")?: permission denied$} test fCmd-6.24 {CopyRenameOneFile: error uses original name} -setup { @@ -635,10 +635,10 @@ test fCmd-6.24 {CopyRenameOneFile: error uses original name} -setup { } -constraints {unix notRoot} -body { file mkdir ~/td1/td2 set td1name [file join [file dirname ~] [file tail ~] td1] - file attributes $td1name -permissions 0000 + file attributes $td1name -permissions 0o000 file copy ~/td1 td1 } -returnCodes error -cleanup { - file attributes $td1name -permissions 0755 + file attributes $td1name -permissions 0o755 file delete -force ~/td1 } -result {error copying "~/td1": permission denied} test fCmd-6.25 {CopyRenameOneFile: error uses original name} -setup { @@ -647,10 +647,10 @@ test fCmd-6.25 {CopyRenameOneFile: error uses original name} -setup { file mkdir td2 file mkdir ~/td1 set td1name [file join [file dirname ~] [file tail ~] td1] - file attributes $td1name -permissions 0000 + file attributes $td1name -permissions 0o000 file copy td2 ~/td1 } -returnCodes error -cleanup { - file attributes $td1name -permissions 0755 + file attributes $td1name -permissions 0o755 file delete -force ~/td1 } -result {error copying "td2" to "~/td1/td2": permission denied} test fCmd-6.26 {CopyRenameOneFile: doesn't use original name} -setup { @@ -658,10 +658,10 @@ test fCmd-6.26 {CopyRenameOneFile: doesn't use original name} -setup { } -constraints {unix notRoot} -body { file mkdir ~/td1/td2 set td2name [file join [file dirname ~] [file tail ~] td1 td2] - file attributes $td2name -permissions 0000 + file attributes $td2name -permissions 0o000 file copy ~/td1 td1 } -returnCodes error -cleanup { - file attributes $td2name -permissions 0755 + file attributes $td2name -permissions 0o755 file delete -force ~/td1 } -result "error copying \"~/td1\" to \"td1\": \"[file join $::env(HOME) td1 td2]\": permission denied" test fCmd-6.27 {CopyRenameOneFile: TclpCopyDirectory failed} -setup { @@ -676,10 +676,10 @@ test fCmd-6.28 {CopyRenameOneFile: TclpCopyDirectory failed} -setup { cleanup $tmpspace } -constraints {notRoot xdev} -body { file mkdir td1/td2/td3 - file attributes td1/td2/td3 -permissions 0000 + file attributes td1/td2/td3 -permissions 0o000 file rename td1 $tmpspace } -returnCodes error -cleanup { - file attributes td1/td2/td3 -permissions 0755 + file attributes td1/td2/td3 -permissions 0o755 cleanup $tmpspace } -match glob -result {error renaming "td1" to "/tmp/tcl*/td1": "td1/td2/td3": permission denied} test fCmd-6.29 {CopyRenameOneFile: TclpCopyDirectory passed} -setup { @@ -1343,10 +1343,10 @@ test fCmd-12.8 {renamefile: generic error} -setup { } -constraints {unix notRoot} -body { file mkdir tfa file mkdir tfa/dir - file attributes tfa -permissions 0555 + file attributes tfa -permissions 0o555 catch {file rename tfa/dir tfa2} } -cleanup { - catch {file attributes tfa -permissions 0777} + catch {file attributes tfa -permissions 0o777} file delete -force tfa } -result {1} test fCmd-12.9 {renamefile: moving a file across volumes} -setup { @@ -1529,10 +1529,10 @@ test fCmd-14.8 {copyfile: copy directory failing} -setup { catch {file delete -force -- tfa} } -constraints {unix notRoot} -body { file mkdir tfa/dir/a/b/c - file attributes tfa/dir -permissions 0000 + file attributes tfa/dir -permissions 0o000 catch {file copy tfa tfa2} } -cleanup { - file attributes tfa/dir -permissions 0777 + file attributes tfa/dir -permissions 0o777 file delete -force tfa tfa2 } -result {1} @@ -1572,10 +1572,10 @@ test fCmd-15.4 {TclMakeDirsCmd - stat failing} -setup { } -constraints {unix notRoot} -body { file mkdir tfa createfile tfa/file - file attributes tfa -permissions 0000 + file attributes tfa -permissions 0o000 catch {file mkdir tfa/file} } -cleanup { - file attributes tfa -permissions 0777 + file attributes tfa -permissions 0o777 file delete -force tfa } -result {1} test fCmd-15.5 {TclMakeDirsCmd: - making a directory several levels deep} -setup { @@ -1672,7 +1672,7 @@ test fCmd-16.9 {error while deleting file} -setup { } -constraints {unix notRoot} -body { file mkdir tfa createfile tfa/a - file attributes tfa -permissions 0555 + file attributes tfa -permissions 0o555 catch {file delete tfa/a} ####### ####### If any directory in a tree that is being removed does not have @@ -1680,7 +1680,7 @@ test fCmd-16.9 {error while deleting file} -setup { ####### with "rm -rf" ####### } -cleanup { - file attributes tfa -permissions 0777 + file attributes tfa -permissions 0o777 file delete -force tfa } -result {1} test fCmd-16.10 {deleting multiple files} -constraints {notRoot} -setup { @@ -1702,10 +1702,10 @@ test fCmd-17.1 {mkdir stat failing on target but not ENOENT} -setup { catch {file delete -force -- tfa1} } -constraints {unix notRoot} -body { file mkdir tfa1 - file attributes tfa1 -permissions 0555 + file attributes tfa1 -permissions 0o555 catch {file mkdir tfa1/tfa2} } -cleanup { - file attributes tfa1 -permissions 0777 + file attributes tfa1 -permissions 0o777 file delete -force tfa1 } -result {1} test fCmd-17.2 {mkdir several levels deep - relative} -setup { @@ -1913,10 +1913,10 @@ test fCmd-19.2 {rmdir error besides EEXIST} -setup { } -constraints {unix notRoot} -body { file mkdir tfa file mkdir tfa/a - file attributes tfa -permissions 0555 + file attributes tfa -permissions 0o555 catch {file delete tfa/a} } -cleanup { - file attributes tfa -permissions 0777 + file attributes tfa -permissions 0o777 file delete -force tfa } -result {1} test fCmd-19.3 {recursive remove} -constraints {notRoot} -setup { @@ -1941,10 +1941,10 @@ test fCmd-20.1 {TraverseUnixTree : failure opening a subdirectory directory} -se } -constraints {unix notRoot} -body { file mkdir tfa file mkdir tfa/a - file attributes tfa/a -permissions 0000 + file attributes tfa/a -permissions 0o000 catch {file delete -force tfa} } -cleanup { - file attributes tfa/a -permissions 0777 + file attributes tfa/a -permissions 0o777 file delete -force tfa } -result {1} test fCmd-20.2 {TraverseUnixTree : recursive delete of large directory: Bug 1034337} -setup { diff --git a/tests/fileName.test b/tests/fileName.test index 0411ea8..2648049 100644 --- a/tests/fileName.test +++ b/tests/fileName.test @@ -1327,7 +1327,7 @@ unset globname # AFS, "000" protection doesn't prevent access by owner, so the following test # is not portable. -catch {file attributes globTest/a1 -permissions 0000} +catch {file attributes globTest/a1 -permissions 0o000} test filename-15.1 {unix specific globbing} {unix nonPortable} { string tolower [list [catch {glob globTest/a1/*} msg] $msg $errorCode] } {1 {couldn't read directory "globtest/a1": permission denied} {posix eacces {permission denied}}} @@ -1339,7 +1339,7 @@ test filename-15.3 {unix specific no complain: no errors, good result} \ # test fails because if an error occurs, the interp's result is reset... glob -nocomplain globTest/a2 globTest/a1/* globTest/a3 } {globTest/a2 globTest/a3} -catch {file attributes globTest/a1 -permissions 0755} +catch {file attributes globTest/a1 -permissions 0o755} test filename-15.4 {unix specific no complain: no errors, good result} \ {unix nonPortable} { # test fails because if an error occurs, the interp's result is reset... diff --git a/tests/fileSystem.test b/tests/fileSystem.test index 7e06a23..8af4f53 100644 --- a/tests/fileSystem.test +++ b/tests/fileSystem.test @@ -695,7 +695,7 @@ test filesystem-7.5 {cross-filesystem file copy with -force} -setup { # First copy should succeed set res [catch {file copy simplefs:/simplefile file2} err] lappend res $err - file attributes file2 -permissions 0000 + file attributes file2 -permissions 0o000 # Second copy should fail (no -force) lappend res [catch {file copy simplefs:/simplefile file2} err] lappend res $err diff --git a/tests/tcltest.test b/tests/tcltest.test index 5e2485b..9b1bb4b 100644 --- a/tests/tcltest.test +++ b/tests/tcltest.test @@ -546,8 +546,8 @@ makeDirectory notreadable makeDirectory notwriteable switch -- $::tcl_platform(platform) { unix { - file attributes $notReadableDir -permissions 00333 - file attributes $notWriteableDir -permissions 00555 + file attributes $notReadableDir -permissions 0o333 + file attributes $notWriteableDir -permissions 0o555 } default { # note in FAT/NTFS we won't be able to protect directory with read-only attribute... diff --git a/tests/unixFCmd.test b/tests/unixFCmd.test index c98e3f0..991e489 100644 --- a/tests/unixFCmd.test +++ b/tests/unixFCmd.test @@ -96,10 +96,10 @@ test unixFCmd-1.1 {TclpRenameFile: EACCES} -setup { cleanup } -constraints {unix notRoot} -body { file mkdir td1/td2/td3 - file attributes td1/td2 -permissions 0000 + file attributes td1/td2 -permissions 0o000 file rename td1/td2/td3 td2 } -returnCodes error -cleanup { - file attributes td1/td2 -permissions 0755 + file attributes td1/td2 -permissions 0o755 cleanup } -result {error renaming "td1/td2/td3": permission denied} test unixFCmd-1.2 {TclpRenameFile: EEXIST} -setup { @@ -221,12 +221,12 @@ test unixFCmd-2.5 {TclpCopyFile: copy attributes} -setup { cleanup } -constraints {unix notRoot} -body { close [open tf1 a] - file attributes tf1 -permissions 0472 + file attributes tf1 -permissions 0o472 file copy tf1 tf2 - file attributes tf2 -permissions + format 0o%03o [file attributes tf2 -permissions] } -cleanup { cleanup -} -result 00472 ;# i.e. perms field of [exec ls -l tf2] is -r--rwx-w- +} -result 0o472 ;# i.e. perms field of [exec ls -l tf2] is -r--rwx-w- test unixFCmd-3.1 {CopyFile not done} {emptyTest unix notRoot} { } {} @@ -336,15 +336,15 @@ test unixFCmd-17.1 {SetPermissionsAttribute} -setup { catch {file delete -force -- foo.test} } -constraints {unix notRoot} -body { close [open foo.test w] - list [file attributes foo.test -permissions 0000] \ - [file attributes foo.test -permissions] + list [file attributes foo.test -permissions 0o000] \ + [format 0o%03o [file attributes foo.test -permissions]] } -cleanup { file delete -force -- foo.test -} -result {{} 00000} +} -result {{} 0o000} test unixFCmd-17.2 {SetPermissionsAttribute} -setup { catch {file delete -force -- foo.test} } -constraints {unix notRoot} -returnCodes error -body { - file attributes foo.test -permissions 0000 + file attributes foo.test -permissions 0o000 } -result {could not set permissions for file "foo.test": no such file or directory} test unixFCmd-17.3 {SetPermissionsAttribute} -setup { catch {file delete -force -- foo.test} @@ -370,16 +370,16 @@ proc permcheck {testnum permList expected} { set result {} foreach permstr $permList { file attributes foo.test -permissions $permstr - lappend result [file attributes foo.test -permissions] + lappend result [format 0o%03o [file attributes foo.test -permissions]] } set result } $expected } -permcheck unixFCmd-17.5 rwxrwxrwx 00777 -permcheck unixFCmd-17.6 r--r---w- 00442 -permcheck unixFCmd-17.7 {0 u+rwx,g+r u-w o+rwx} {00000 00740 00540 00547} -permcheck unixFCmd-17.11 --x--x--x 00111 -permcheck unixFCmd-17.12 {0 a+rwx} {00000 00777} +permcheck unixFCmd-17.5 rwxrwxrwx 0o777 +permcheck unixFCmd-17.6 r--r---w- 0o442 +permcheck unixFCmd-17.7 {0 u+rwx,g+r u-w o+rwx} {0o000 0o740 0o540 0o547} +permcheck unixFCmd-17.11 --x--x--x 0o111 +permcheck unixFCmd-17.12 {0 a+rwx} {0o000 0o777} file delete -force -- foo.test test unixFCmd-18.1 {Unix pwd} -constraints {unix notRoot nonPortable} -setup { @@ -390,11 +390,11 @@ test unixFCmd-18.1 {Unix pwd} -constraints {unix notRoot nonPortable} -setup { set nd $cd/tstdir file mkdir $nd cd $nd - file attributes $nd -permissions 0000 + file attributes $nd -permissions 0o000 pwd } -returnCodes error -cleanup { cd $cd - file attributes $nd -permissions 0755 + file attributes $nd -permissions 0o755 file delete $nd } -match glob -result {error getting working directory name:*} diff --git a/tools/installData.tcl b/tools/installData.tcl index dd7976b..4a3b1ee 100644 --- a/tools/installData.tcl +++ b/tools/installData.tcl @@ -32,7 +32,7 @@ proc copyDir {d1 d2} { } elseif {[file isfile $f]} { file copy -force $f [file join $d2 $ftail] if {$::tcl_platform(platform) eq {unix}} { - file attributes [file join $d2 $ftail] -permissions 0644 + file attributes [file join $d2 $ftail] -permissions 0o644 } else { file attributes [file join $d2 $ftail] -readonly 1 } @@ -40,7 +40,7 @@ proc copyDir {d1 d2} { } if {$::tcl_platform(platform) eq {unix}} { - file attributes $d2 -permissions 0755 + file attributes $d2 -permissions 0o755 } else { file attributes $d2 -readonly 1 } -- cgit v0.12 From c99f35416608c70d8e277b38405429a50b64bd84 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Thu, 3 Dec 2020 13:57:56 +0000 Subject: two more 0o??? notations --- tests/chanio.test | 4 ++-- tests/io.test | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/chanio.test b/tests/chanio.test index ffb4e91..5586015 100644 --- a/tests/chanio.test +++ b/tests/chanio.test @@ -5350,8 +5350,8 @@ test chan-io-40.3 {POSIX open access modes: CREAT} -setup { # This test only works if your umask is 2, like ouster's. chan close [open $path(test3) {WRONLY CREAT}] file stat $path(test3) stats - format "%#o" [expr {$stats(mode) & 0o777}] -} -result [format %#4o [expr {0o666 & ~ $umaskValue}]] + format "0o%03o" [expr {$stats(mode) & 0o777}] +} -result [format 0o%03o [expr {0o666 & ~ $umaskValue}]] test chan-io-40.4 {POSIX open access modes: CREAT} -setup { file delete $path(test3) } -body { diff --git a/tests/io.test b/tests/io.test index e45b5ef..71f6e50 100644 --- a/tests/io.test +++ b/tests/io.test @@ -5655,8 +5655,8 @@ test io-40.3 {POSIX open access modes: CREAT} {unix umask} { set f [open $path(test3) {WRONLY CREAT}] close $f file stat $path(test3) stats - format "%#o" [expr $stats(mode)&0o777] -} [format %#4o [expr {0o666 & ~ $umaskValue}]] + format "0o%03o" [expr $stats(mode)&0o777] +} [format "0o%03o" [expr {0o666 & ~ $umaskValue}]] test io-40.4 {POSIX open access modes: CREAT} { file delete $path(test3) set f [open $path(test3) w] -- cgit v0.12 From ebd7b1edb756eea5aa2bdb46d4634ba80de8fccc Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Fri, 4 Dec 2020 09:58:37 +0000 Subject: Fix 4 socket testcases on Msys (those fail on Cygwin too) --- tests/socket.test | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/socket.test b/tests/socket.test index d5f9c94..b590fc7 100644 --- a/tests/socket.test +++ b/tests/socket.test @@ -285,6 +285,8 @@ proc getPort sock { # Some tests in this file are known to hang *occasionally* on OSX; stop the # worst offenders. testConstraint notOSX [expr {$::tcl_platform(os) ne "Darwin"}] +# Here "Windows" means derived platforms as Cygwin or Msys2 too. +testConstraint notWindows [expr {![regexp {^(Windows|MSYS|CYGWIN)} $::tcl_platform(os)]}] # ---------------------------------------------------------------------- @@ -909,7 +911,7 @@ test socket_$af-5.1 {byte order problems, socket numbers, htons} -body { return {htons problem, should be disallowed, are you running as SU?} } return {couldn't open socket: not owner} -} -constraints [list socket supported_$af unix notRoot notOSX] -result {couldn't open socket: not owner} +} -constraints [list socket supported_$af unix notRoot notOSX notWindows] -result {couldn't open socket: not owner} test socket_$af-5.2 {byte order problems, socket numbers, htons} -body { if {![catch {socket -server dodo 0x10000} msg]} { close $msg @@ -923,7 +925,7 @@ test socket_$af-5.3 {byte order problems, socket numbers, htons} -body { return {htons problem, should be disallowed, are you running as SU?} } return {couldn't open socket: not owner} -} -constraints [list socket supported_$af unix notRoot notOSX] -result {couldn't open socket: not owner} +} -constraints [list socket supported_$af unix notRoot notOSX notWindows] -result {couldn't open socket: not owner} test socket_$af-6.1 {accept callback error} -constraints [list socket supported_$af stdio] -setup { proc myHandler {msg options} { -- cgit v0.12 From 9a3e53bd90302b78155f1fd7a561b3274d54316e Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Fri, 4 Dec 2020 10:00:56 +0000 Subject: TclWordEnd was removed in 8.1, so those testcases cannot be run anymore --- tests/parseOld.test | 66 ----------------------------------------------------- 1 file changed, 66 deletions(-) diff --git a/tests/parseOld.test b/tests/parseOld.test index c8f82cf..4e441d1 100644 --- a/tests/parseOld.test +++ b/tests/parseOld.test @@ -451,72 +451,6 @@ expr 1+1 ]" } {2} -test parseOld-14.1 {TclWordEnd procedure} {testwordend} { - testwordend " \n abc" -} {c} -test parseOld-14.2 {TclWordEnd procedure} {testwordend} { - testwordend " \\\n" -} {} -test parseOld-14.3 {TclWordEnd procedure} {testwordend} { - testwordend " \\\n " -} { } -test parseOld-14.4 {TclWordEnd procedure} {testwordend} { - testwordend {"abc"} -} {"} -#" Emacs formatting :^( -test parseOld-14.5 {TclWordEnd procedure} {testwordend} { - testwordend {{xyz}} -} \} -test parseOld-14.6 {TclWordEnd procedure} {testwordend} { - testwordend {{a{}b{}\}} xyz} -} "\} xyz" -test parseOld-14.7 {TclWordEnd procedure} {testwordend} { - testwordend {abc[this is a]def ghi} -} {f ghi} -test parseOld-14.8 {TclWordEnd procedure} {testwordend} { - testwordend "puts\\\n\n " -} "s\\\n\n " -test parseOld-14.9 {TclWordEnd procedure} {testwordend} { - testwordend "puts\\\n " -} "s\\\n " -test parseOld-14.10 {TclWordEnd procedure} {testwordend} { - testwordend "puts\\\n xyz" -} "s\\\n xyz" -test parseOld-14.11 {TclWordEnd procedure} {testwordend} { - testwordend {a$x.$y(a long index) foo} -} ") foo" -test parseOld-14.12 {TclWordEnd procedure} {testwordend} { - testwordend {abc; def} -} {; def} -test parseOld-14.13 {TclWordEnd procedure} {testwordend} { - testwordend {abc def} -} {c def} -test parseOld-14.14 {TclWordEnd procedure} {testwordend} { - testwordend {abc def} -} {c def} -test parseOld-14.15 {TclWordEnd procedure} {testwordend} { - testwordend "abc\ndef" -} "c\ndef" -test parseOld-14.16 {TclWordEnd procedure} {testwordend} { - testwordend "abc" -} {c} -test parseOld-14.17 {TclWordEnd procedure} {testwordend} { - testwordend "a\000bc" -} {c} -test parseOld-14.18 {TclWordEnd procedure} {testwordend} { - testwordend \[a\000\] -} {]} -test parseOld-14.19 {TclWordEnd procedure} {testwordend} { - testwordend \"a\000\" -} {"} -#" Emacs formatting :^( -test parseOld-14.20 {TclWordEnd procedure} {testwordend} { - testwordend a{\000}b -} {b} -test parseOld-14.21 {TclWordEnd procedure} {testwordend} { - testwordend " \000b" -} {b} - test parseOld-15.1 {TclScriptEnd procedure} { info complete {puts [ expr 1+1 -- cgit v0.12 From cd48044e1b95257568e26686e58e9c293a81a82d Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Fri, 4 Dec 2020 10:19:51 +0000 Subject: Backport "tcltest" package from 8.7. No changes when running on 8.5 or 8.6 --- library/tcltest/tcltest.tcl | 27 ++++++++++++++++++++------- 1 file changed, 20 insertions(+), 7 deletions(-) diff --git a/library/tcltest/tcltest.tcl b/library/tcltest/tcltest.tcl index 4df25e4..7dc75d7 100644 --- a/library/tcltest/tcltest.tcl +++ b/library/tcltest/tcltest.tcl @@ -11,8 +11,8 @@ # Microsystems. # # Copyright (c) 1994-1997 Sun Microsystems, Inc. -# Copyright (c) 1998-1999 by Scriptics Corporation. -# Copyright (c) 2000 by Ajuba Solutions +# Copyright (c) 1998-1999 Scriptics Corporation. +# Copyright (c) 2000 Ajuba Solutions # Contributions from Don Porter, NIST, 2002. (not subject to US copyright) # All rights reserved. @@ -41,7 +41,9 @@ namespace eval tcltest { outputChannel testConstraint # Export commands that are duplication (candidates for deprecation) - namespace export bytestring ;# dups [encoding convertfrom identity] + if {![package vsatisfies [package provide Tcl] 8.7-]} { + namespace export bytestring ;# dups [encoding convertfrom identity] + } namespace export debug ;# [configure -debug] namespace export errorFile ;# [configure -errfile] namespace export limitConstraints ;# [configure -limitconstraints] @@ -1269,7 +1271,7 @@ proc tcltest::DefineConstraintInitializers {} { ConstraintInitializer nonBlockFiles { set code [expr {[catch {set f [open defs r]}] - || [catch {chan configure $f -blocking off}]}] + || [catch {fconfigure $f -blocking off}]}] catch {close $f} set code } @@ -3079,7 +3081,10 @@ proc tcltest::makeFile {contents name {directory ""}} { putting ``$contents'' into $fullName" set fd [open $fullName w] - chan configure $fd -translation lf + fconfigure $fd -translation lf + if {[package vsatisfies [package provide Tcl] 8.7-]} { + fconfigure $fd -encoding utf-8 + } if {[string index $contents end] eq "\n"} { puts -nonewline $fd $contents } else { @@ -3228,6 +3233,9 @@ proc tcltest::viewFile {name {directory ""}} { } set fullName [file join $directory $name] set f [open $fullName] + if {[package vsatisfies [package provide Tcl] 8.7-]} { + fconfigure $f -encoding utf-8 + } set data [read -nonewline $f] close $f return $data @@ -3249,6 +3257,9 @@ proc tcltest::viewFile {name {directory ""}} { # construct improperly formed strings in this manner, because it involves # exposing that Tcl uses UTF-8 internally. # +# This function doesn't work any more in Tcl 8.7, since the 'identity' +# is gone (TIP #345) +# # Arguments: # string being converted # @@ -3258,8 +3269,10 @@ proc tcltest::viewFile {name {directory ""}} { # Side effects: # None -proc tcltest::bytestring {string} { - return [encoding convertfrom identity $string] +if {![package vsatisfies [package provide Tcl] 8.7-]} { + proc tcltest::bytestring {string} { + return [encoding convertfrom identity $string] + } } # tcltest::OpenFiles -- -- cgit v0.12 From fc71c7c2fce04d50b5c1baa8306a02510bc30f73 Mon Sep 17 00:00:00 2001 From: apnadkarni Date: Sun, 6 Dec 2020 08:06:03 +0000 Subject: nmake builds: extract {TCL,TK}_RELEASE_SERIAL and patch letters from {tcl,tk}.h --- win/rules.vc | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/win/rules.vc b/win/rules.vc index ab43909..c70effb 100644 --- a/win/rules.vc +++ b/win/rules.vc @@ -24,7 +24,7 @@ _RULES_VC = 1 # For modifications that are not backward-compatible, you *must* change # the major version. RULES_VERSION_MAJOR = 1 -RULES_VERSION_MINOR = 6 +RULES_VERSION_MINOR = 7 # The PROJECT macro must be defined by parent makefile. !if "$(PROJECT)" == "" @@ -907,10 +907,14 @@ WARNINGS = $(WARNINGS) -Wp64 # Sets the following macros: # TCL_MAJOR_VERSION # TCL_MINOR_VERSION +# TCL_RELEASE_SERIAL # TCL_PATCH_LEVEL +# TCL_PATCH_LETTER # TCL_VERSION # TK_MAJOR_VERSION # TK_MINOR_VERSION +# TK_RELEASE_SERIAL +# TK_PATCH_LEVEL # TK_PATCH_LEVEL # TK_VERSION # DOTVERSION - set as (for example) 2.5 @@ -925,6 +929,9 @@ WARNINGS = $(WARNINGS) -Wp64 !if [echo TCL_MINOR_VERSION = \>> versions.vc] \ && [nmakehlp -V "$(_TCL_H)" TCL_MINOR_VERSION >> versions.vc] !endif +!if [echo TCL_RELEASE_SERIAL = \>> versions.vc] \ + && [nmakehlp -V "$(_TCL_H)" TCL_RELEASE_SERIAL >> versions.vc] +!endif !if [echo TCL_PATCH_LEVEL = \>> versions.vc] \ && [nmakehlp -V "$(_TCL_H)" TCL_PATCH_LEVEL >> versions.vc] !endif @@ -936,6 +943,9 @@ WARNINGS = $(WARNINGS) -Wp64 !if [echo TK_MINOR_VERSION = \>> versions.vc] \ && [nmakehlp -V $(_TK_H) TK_MINOR_VERSION >> versions.vc] !endif +!if [echo TK_RELEASE_SERIAL = \>> versions.vc] \ + && [nmakehlp -V "$(_TK_H)" TK_RELEASE_SERIAL >> versions.vc] +!endif !if [echo TK_PATCH_LEVEL = \>> versions.vc] \ && [nmakehlp -V $(_TK_H) TK_PATCH_LEVEL >> versions.vc] !endif @@ -945,9 +955,26 @@ WARNINGS = $(WARNINGS) -Wp64 TCL_VERSION = $(TCL_MAJOR_VERSION)$(TCL_MINOR_VERSION) TCL_DOTVERSION = $(TCL_MAJOR_VERSION).$(TCL_MINOR_VERSION) +!if [nmakehlp -f $(TCL_PATCH_LEVEL) "a"] +TCL_PATCH_LETTER = a +!elseif [nmakehlp -f $(TCL_PATCH_LEVEL) "b"] +TCL_PATCH_LETTER = b +!else +TCL_PATCH_LETTER = . +!endif + !if defined(_TK_H) + TK_VERSION = $(TK_MAJOR_VERSION)$(TK_MINOR_VERSION) TK_DOTVERSION = $(TK_MAJOR_VERSION).$(TK_MINOR_VERSION) +!if [nmakehlp -f $(TK_PATCH_LEVEL) "a"] +TK_PATCH_LETTER = a +!elseif [nmakehlp -f $(TK_PATCH_LEVEL) "b"] +TK_PATCH_LETTER = b +!else +TK_PATCH_LETTER = . +!endif + !endif # Set DOTVERSION and VERSION -- cgit v0.12 From cf333de0987ad12a325909be7ae372f50d2d28a1 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Mon, 7 Dec 2020 13:53:21 +0000 Subject: rules.vc: Make sure that 3th "load" argument is titlecased in pkgIndex.tcl --- win/makefile.vc | 2 +- win/rules.vc | 6 +++--- win/targets.vc | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/win/makefile.vc b/win/makefile.vc index 3c6b86e..60b6bf0 100644 --- a/win/makefile.vc +++ b/win/makefile.vc @@ -16,7 +16,7 @@ # General usage: # nmake [-nologo] -f makefile.vc [TARGET|MACRODEF [TARGET|MACRODEF] [...]] # -# For MACRODEF, see TIP 477 (https://core.tcl-lang.org/tips/doc/trunk/tip/477.md) +# For MACRODEF, see TIP 477 (https://core.tcl-lang.org/tips/doc/main/tip/477.md) # or examine Sections 6-8 in rules.vc. # # Possible values of TARGET are: diff --git a/win/rules.vc b/win/rules.vc index c70effb..a0084a4 100644 --- a/win/rules.vc +++ b/win/rules.vc @@ -6,7 +6,7 @@ # compiler switches, defining common targets and macros. The Tcl makefile # directly includes this. Extensions include it via "rules-ext.vc". # -# See TIP 477 (https://core.tcl-lang.org/tips/doc/trunk/tip/477.md) for +# See TIP 477 (https://core.tcl-lang.org/tips/doc/main/tip/477.md) for # detailed documentation. # # See the file "license.terms" for information on usage and redistribution @@ -1565,11 +1565,11 @@ default-target: $(DEFAULT_BUILD_TARGET) !if $(MULTIPLATFORM_INSTALL) default-pkgindex: @echo package ifneeded $(PRJ_PACKAGE_TCLNAME) $(DOTVERSION) \ - [list load [file join $$dir $(PLATFORM_IDENTIFY) $(PRJLIBNAME)]] > $(OUT_DIR)\pkgIndex.tcl + [list load [file join $$dir $(PLATFORM_IDENTIFY) $(PRJLIBNAME)] [string totitle $(PRJ_PACKAGE_TCLNAME)]] > $(OUT_DIR)\pkgIndex.tcl !else default-pkgindex: @echo package ifneeded $(PRJ_PACKAGE_TCLNAME) $(DOTVERSION) \ - [list load [file join $$dir $(PRJLIBNAME)]] > $(OUT_DIR)\pkgIndex.tcl + [list load [file join $$dir $(PRJLIBNAME)] [string totitle $(PRJ_PACKAGE_TCLNAME)]] > $(OUT_DIR)\pkgIndex.tcl !endif default-pkgindex-tea: diff --git a/win/targets.vc b/win/targets.vc index 6bfebc7..077e8f7 100644 --- a/win/targets.vc +++ b/win/targets.vc @@ -4,7 +4,7 @@ # Part of the nmake based build system for Tcl and its extensions. # This file defines some standard targets for the convenience of extensions # and can be optionally included by the extension makefile. -# See TIP 477 (https://core.tcl-lang.org/tips/doc/trunk/tip/477.md) for docs. +# See TIP 477 (https://core.tcl-lang.org/tips/doc/main/tip/477.md) for docs. $(PROJECT): setup pkgindex $(PRJLIB) -- cgit v0.12