TIPs 22, 33, and 45
Closed / Fixed471874ffffffffffffffffffffffffffffffffffCreated 25 years agoUpdated 25 years ago
Descriptionplain2001-10-16 21:19:22
The attached patch, plus the three new files, doc/lset.n, tests/lset.test and tests/lsetComp.test, comprise the reference implementation for the functionality described in TIPs #22, #33, and #45. It is posted here for review by the affected maintainers.
kennykbplain2001-10-17 04:19:22
File Added - 12058: tip-22-33-45.patch
kennykbplain2001-10-17 04:20:58
File Added - 12059: lset.n
kennykbplain2001-10-17 04:22:05
File Added - 12060: lset.test
kennykbplain2001-10-17 04:23:17
File Added - 12061: lsetComp.test
dgpplain2001-10-17 08:50:38
Logged In: YES user_id=80530 generic/tclListObj.c does not compile because TRUE and FALSE are not defined.
kennykbplain2001-10-17 20:58:55
File Deleted - 12058:
kennykbplain2001-10-17 21:01:53
File Added - 12098: tip-22-33-45.patch2 Logged In: YES user_id=99768 tip-22-33-45.patch2 is a revised set of patches for the modified files. It contains two changes from the original: (1) a memory leak in tclCmdIL.c (TclLsetList) has been plugged (2) the symbols TRUE and FALSE (defined on Windows, not elsewhere) used in tclListObj.c have been replaced with 1 and 0 respectively.
kennykbplain2001-10-17 21:21:03
File Deleted - 12061:
kennykbplain2001-10-17 21:22:17
Logged In: YES user_id=99768 Also removed a stray 'exit' from lsetComp.test -- how'd THAT get in there??? 8^)
kennykbplain2001-10-17 21:22:18
File Added - 12099: lsetComp.test
kennykbplain2001-10-18 05:33:18
File Deleted - 12098: Logged In: YES user_id=99768 On the chat, dgp objected to the fact that tclEndOffsetType wasn't a registered type and lacked an "update string" procedure. The third version of the patch adds the missing features. It also adds an "invalidateStringRep" option to the [testobj] command, so that the "update string" procedure can be tested: otherwise, the string rep of an "end-offset" object is never spoilt intentionally, nor is such an object ever built except from a string.
kennykbplain2001-10-18 05:34:16
File Added - 12135: tip-22-33-45.patch3
dgpplain2001-10-18 07:56:21
Logged In: YES
user_id=80530
'make test' with the latest revision:
==== obj-31.5 regenerate string rep of "end--bigInteger"
FAILED
==== Contents of test case:
testobj freeallvars
teststringobj set 1 end--0x80000000
testobj convert 1 end-offset
testobj invalidateStringRep 1
---- Result was:
integer value too large to represent
---- Result should have been (exact matching):
end--2147483648
---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
==== obj-31.5 FAILED
kennykbplain2001-10-22 22:14:36
File Deleted - 12059:
kennykbplain2001-10-22 22:17:48
Logged In: YES user_id=99768 At dkf's suggestion, added to lset.n a paragraph describing the behaviour when a list index is out of range.
kennykbplain2001-10-22 22:17:49
File Added - 12322: lset.n
kennykbplain2001-11-06 23:46:59
Logged In: YES user_id=99768 Fourth version of the patches. Fixes a bug that DKF discovered where it was possible to assign to ptr2 in an object's internal representation without first ascertaining that the object was a list.
kennykbplain2001-11-06 23:47:58
Logged In: YES user_id=99768 Fourth version of the patches. Fixes a bug that DKF discovered where it was possible to assign to ptr2 in an object's internal representation without first ascertaining that the object was a list.
kennykbplain2001-11-06 23:47:59
File Deleted - 12135: File Added - 12923: tip-22-33-45.patch4
dgpplain2001-11-07 04:54:05
Logged In: YES user_id=80530 Latest patch applies clean to HEAD and 'make test' reveals no new failures. I'm trusting the developers to have come up with a complete test set. One change I would make to the docs in lindex.n and lset.n. They have syntax like: \fBlindex \fIlist ?index...?\fR but then the description that follows refers to the "\fIindices\fR" . I think that would be better phrased the "\fIindex\fR arguments" Note I think there are also several instances of \fP in the man pages where \fR is intended.
hobbsplain2001-11-15 06:17:54
Logged In: YES user_id=72656 This was tested and commited to 8.4a4cvs on Nov14.
Log in (anonymous is fine) to add a comment.
Attachments:
- tip-22-33-45.patch4 [download] added by kennykb on 2001-11-06 23:47:58. [details]
- lset.n [download] added by kennykb on 2001-10-22 22:17:48. [details]
- lsetComp.test [download] added by kennykb on 2001-10-17 21:22:17. [details]
- lset.test [download] added by kennykb on 2001-10-17 04:22:05. [details]