Tcl Source Code

Hex Artifact Content
Login

Artifact 390b2e89e49d51bc842ef177685b6deccaa7cc5767116622aeeccb652649e153:

Attachment "tclCmdIL.patch" to ticket [5a1aaa201d] added by juliannoble2 2024-11-18 03:12:37.
0000: 2d 2d 2d 20 74 63 6c 43 6d 64 49 4c 5f 6f 72 69  --- tclCmdIL_ori
0010: 67 2e 63 09 53 61 74 20 4f 63 74 20 30 35 20 30  g.c.Sat Oct 05 0
0020: 36 3a 30 39 3a 35 32 20 32 30 32 34 0d 0a 2b 2b  6:09:52 2024..++
0030: 2b 20 74 63 6c 43 6d 64 49 4c 2e 63 09 4d 6f 6e  + tclCmdIL.c.Mon
0040: 20 4e 6f 76 20 31 38 20 31 33 3a 35 39 3a 30 31   Nov 18 13:59:01
0050: 20 32 30 32 34 0d 0a 40 40 20 2d 33 39 32 36 2c   2024..@@ -3926,
0060: 36 20 2b 33 39 32 36 2c 31 30 20 40 40 0d 0a 20  6 +3926,10 @@.. 
0070: 09 09 20 20 20 20 69 74 65 6d 50 74 72 20 3d 20  ..    itemPtr = 
0080: 53 65 6c 65 63 74 4f 62 6a 46 72 6f 6d 53 75 62  SelectObjFromSub
0090: 6c 69 73 74 28 6c 69 73 74 76 5b 69 2b 67 72 6f  list(listv[i+gro
00a0: 75 70 4f 66 66 73 65 74 5d 2c 0d 0a 20 09 09 09  upOffset],.. ...
00b0: 20 20 20 20 26 73 6f 72 74 49 6e 66 6f 29 3b 0d      &sortInfo);.
00c0: 0a 20 09 09 20 20 20 20 54 63 6c 5f 4c 69 73 74  . ..    Tcl_List
00d0: 4f 62 6a 41 70 70 65 6e 64 45 6c 65 6d 65 6e 74  ObjAppendElement
00e0: 28 69 6e 74 65 72 70 2c 20 6c 69 73 74 50 74 72  (interp, listPtr
00f0: 2c 20 69 74 65 6d 50 74 72 29 3b 0d 0a 2b 09 09  , itemPtr);..+..
0100: 7d 20 65 6c 73 65 20 69 66 20 28 72 65 74 75 72  } else if (retur
0110: 6e 53 75 62 69 6e 64 69 63 65 73 20 26 26 20 28  nSubindices && (
0120: 73 6f 72 74 49 6e 66 6f 2e 69 6e 64 65 78 63 20  sortInfo.indexc 
0130: 3d 3d 20 30 29 20 26 26 20 28 67 72 6f 75 70 53  == 0) && (groupS
0140: 69 7a 65 20 3e 20 31 29 29 20 7b 0d 0a 2b 09 09  ize > 1)) {..+..
0150: 20 20 20 20 54 63 6c 5f 42 6f 75 6e 63 65 52 65      Tcl_BounceRe
0160: 66 43 6f 75 6e 74 28 69 74 65 6d 50 74 72 29 3b  fCount(itemPtr);
0170: 20 0d 0a 2b 09 09 20 20 20 20 69 74 65 6d 50 74   ..+..    itemPt
0180: 72 20 3d 20 6c 69 73 74 76 5b 69 20 2b 20 67 72  r = listv[i + gr
0190: 6f 75 70 4f 66 66 73 65 74 5d 3b 0d 0a 2b 09 09  oupOffset];..+..
01a0: 09 54 63 6c 5f 4c 69 73 74 4f 62 6a 41 70 70 65  .Tcl_ListObjAppe
01b0: 6e 64 45 6c 65 6d 65 6e 74 28 69 6e 74 65 72 70  ndElement(interp
01c0: 2c 20 6c 69 73 74 50 74 72 2c 20 69 74 65 6d 50  , listPtr, itemP
01d0: 74 72 29 3b 0d 0a 20 09 09 7d 20 65 6c 73 65 20  tr);.. ..} else 
01e0: 69 66 20 28 67 72 6f 75 70 53 69 7a 65 20 3e 20  if (groupSize > 
01f0: 31 29 20 7b 0d 0a 20 09 09 20 20 20 20 54 63 6c  1) {.. ..    Tcl
0200: 5f 4c 69 73 74 4f 62 6a 52 65 70 6c 61 63 65 28  _ListObjReplace(
0210: 69 6e 74 65 72 70 2c 20 6c 69 73 74 50 74 72 2c  interp, listPtr,
0220: 20 4c 49 53 54 5f 4d 41 58 2c 20 30 2c 0d 0a 20   LIST_MAX, 0,.. 
0230: 09 09 09 20 20 20 20 67 72 6f 75 70 53 69 7a 65  ...    groupSize
0240: 2c 20 26 6c 69 73 74 76 5b 69 5d 29 3b 0d 0a     , &listv[i]);..