stablesort: remove some dead code
This closure is no longer in use.
testofthesplitcommand-----------------------$.$TESTDIR/testlib/common.sh$cat>>$HGRCPATH<<EOF>[defaults]>amend=-d"0 0">fold=-d"0 0">split=-d"0 0">amend=-d"0 0">[web]>push_ssl=false>allow_push=*>[phases]>publish=False>[diff]>git=1>unified=0>[ui]>interactive=true>[extensions]>evolve=>EOF$mkcommit(){>echo"$1">"$1">hgadd"$1">hgci-m"add $1"$2$3>}Basiccase,splitahead$hginittestsplit$cdtestsplit$mkcommit_a$mkcommit_b$mkcommit_c--userother-test-user$mkcommit_d$echo"change to a">>_a$hgamend$hgdebugobsolete1334a80b33c3f9873edab728fbbcf500eab61d2ed2fe56e71366c2c5376c89960c281395062c06190(ThuJan0100:00:001970+0000){'ef1':'8','operation':'amend','user':'test'}Tocreatecommitswiththenumberofsplit$echo0>num$cat>editor.sh<<'__EOF__'>NUM=$(catnum)>NUM=`expr"$NUM"+1`>echo"$NUM">num>echo"split$NUM">"$1">__EOF__$exportHGEDITOR="\"sh\"\"editor.sh\""$hgsplit<<EOF>y>y>y>n>N>y>y>EOF1filesupdated,0filesmerged,1filesremoved,0filesunresolvedreverting_aadding_ddiff--gita/_ab/_a1hunks,1lineschangedexaminechangesto'_a'?[Ynesfdaq?]y@@-1,0+2,1@@+changetoarecordchange1/2to'_a'?[Ynesfdaq?]ydiff--gita/_db/_dnewfilemode100644examinechangesto'_d'?[Ynesfdaq?]y@@-0,0+1,1@@+_drecordchange2/2to'_d'?[Ynesfdaq?]ncreatednewheadDonesplitting?[yN]Ndiff--gita/_db/_dnewfilemode100644examinechangesto'_d'?[Ynesfdaq?]y@@-0,0+1,1@@+_drecordthischangeto'_d'?[Ynesfdaq?]ynomorechangetosplit$hgdebugobsolete1334a80b33c3f9873edab728fbbcf500eab61d2ed2fe56e71366c2c5376c89960c281395062c06190(ThuJan0100:00:001970+0000){'ef1':'8','operation':'amend','user':'test'}d2fe56e71366c2c5376c89960c281395062c06192d8abdb827cdf71ca477ef6985d7ceb257c53c1b033b3f5ae73db67c10de938fb6f26b949aaef1720(*){'ef1':'13','user':'test'}(glob)$hglog-G@changeset:6:033b3f5ae73d|tag:tip|user:test|date:ThuJan0100:00:001970+0000|summary:split2|ochangeset:5:2d8abdb827cd|parent:2:52149352b372|user:test|date:ThuJan0100:00:001970+0000|summary:split1|ochangeset:2:52149352b372|user:other-test-user|date:ThuJan0100:00:001970+0000|summary:add_c|ochangeset:1:37445b16603b|user:test|date:ThuJan0100:00:001970+0000|summary:add_b|ochangeset:0:135f39f4bd78user:testdate:ThuJan0100:00:001970+0000summary:add_aCannotsplitacommitwithuncommittedchanges$hgup"desc(_c)"1filesupdated,0filesmerged,1filesremoved,0filesunresolved$echo"_cd">_c$hgsplitabort:uncommittedchanges[255]$hgup"desc(_c)"-C1filesupdated,0filesmerged,0filesremoved,0filesunresolvedCannotsplitpublicchangeset$hgphase--rev'desc("_a")'0:draft$hgphase--rev'desc("_a")'--public$hgsplit--rev'desc("_a")'abort:cannotsplitpublicchangesets:135f39f4bd78(see'hg help phases'fordetails)[255]$hgphase--rev'desc("_a")'--draft--forceSplitarevisionspecifiedwith-r$echo"change to b">>_b$hgamend-m"_cprim"2neworphanchangesets$hgevolve--allmove:[5]split1atop:[7]_cprimmove:[6]split2atop:[8]split1workingdirectoryisnowat*(glob)$hglog-r"desc(_cprim)"-v-pchangeset:7:b434287e665cparent:1:37445b16603buser:other-test-userdate:ThuJan0100:00:001970+0000files:_b_cdescription:_cprimdiff--gita/_bb/_b---a/_b+++b/_b@@-1,0+2,1@@+changetobdiff--gita/_cb/_cnewfilemode100644---/dev/null+++b/_c@@-0,0+1,1@@+_c$hgsplit-r"desc(_cprim)"<<EOF>y>y>y>n>y>EOF2filesupdated,0filesmerged,2filesremoved,0filesunresolvedreverting_badding_cdiff--gita/_bb/_b1hunks,1lineschangedexaminechangesto'_b'?[Ynesfdaq?]y@@-1,0+2,1@@+changetobrecordchange1/2to'_b'?[Ynesfdaq?]ydiff--gita/_cb/_cnewfilemode100644examinechangesto'_c'?[Ynesfdaq?]y@@-0,0+1,1@@+_crecordchange2/2to'_c'?[Ynesfdaq?]ncreatednewheadDonesplitting?[yN]yStopbeforesplittingthecommitcompletelycreatesacommitwithalltheremainingchanges$hgdebugobsolete1334a80b33c3f9873edab728fbbcf500eab61d2ed2fe56e71366c2c5376c89960c281395062c06190(ThuJan0100:00:001970+0000){'ef1':'8','operation':'amend','user':'test'}d2fe56e71366c2c5376c89960c281395062c06192d8abdb827cdf71ca477ef6985d7ceb257c53c1b033b3f5ae73db67c10de938fb6f26b949aaef1720(*){'ef1':'13','user':'test'}(glob)52149352b372d39b19127d5bd2d488b1b63f9f85b434287e665ce757ee5463a965cb3d119ca9e8930(ThuJan0100:00:001970+0000){'ef1':'9','operation':'amend','user':'test'}2d8abdb827cdf71ca477ef6985d7ceb257c53c1be2b4afde39803bd42bb1374b230fca1b1e8cc8680(*){'ef1':'4','user':'test'}(glob)033b3f5ae73db67c10de938fb6f26b949aaef172bb5e4f6020c74e7961a51fda635ea9df9b04dda80(*){'ef1':'4','user':'test'}(glob)b434287e665ce757ee5463a965cb3d119ca9e893ead2066d1dbf14833fe1069df1b735e4e9468c401188c4216eba37f18a1de6558564601d00ff21430(*){'ef1':'13','user':'test'}(glob)$hgevolve--allmove:[8]split1atop:[11]split4move:[9]split2atop:[12]split1workingdirectoryisnowatd74c6715e706$hglog-G@changeset:13:d74c6715e706|tag:tip|user:test|date:ThuJan0100:00:001970+0000|summary:split2|ochangeset:12:3f134f739075|user:test|date:ThuJan0100:00:001970+0000|summary:split1|ochangeset:11:1188c4216eba|user:other-test-user|date:ThuJan0100:00:001970+0000|summary:split4|ochangeset:10:ead2066d1dbf|parent:1:37445b16603b|user:other-test-user|date:ThuJan0100:00:001970+0000|summary:split3|ochangeset:1:37445b16603b|user:test|date:ThuJan0100:00:001970+0000|summary:add_b|ochangeset:0:135f39f4bd78user:testdate:ThuJan0100:00:001970+0000summary:add_aSplitshouldmovebookmarksonthelastsplitsuccessorandpreservetheactivebookmarkasactive$hgbookbookA$hgbookbookB$echo"changetofilea">_a$hgamend$hgbookbookA14:7a6b35779b85*bookB14:7a6b35779b85$hglog-G-r"3f134f739075::"@changeset:14:7a6b35779b85|bookmark:bookA|bookmark:bookB|tag:tip|parent:12:3f134f739075|user:test|date:ThuJan0100:00:001970+0000|summary:split2|ochangeset:12:3f134f739075|user:test~date:ThuJan0100:00:001970+0000summary:split1$hgsplit--uservictor<<EOF>y>y>n>y>EOF(leavingbookmarkbookB)1filesupdated,0filesmerged,1filesremoved,0filesunresolvedreverting_aadding_ddiff--gita/_ab/_a1hunks,2lineschangedexaminechangesto'_a'?[Ynesfdaq?]y@@-1,2+1,1@@-_a-changetoa+changetofilearecordchange1/2to'_a'?[Ynesfdaq?]ydiff--gita/_db/_dnewfilemode100644examinechangesto'_d'?[Ynesfdaq?]ncreatednewheadDonesplitting?[yN]y$hglog-G-r"3f134f739075::"@changeset:16:452a26648478|bookmark:bookA|bookmark:bookB|tag:tip|user:victor|date:ThuJan0100:00:001970+0000|summary:split6|ochangeset:15:1315679b77dc|parent:12:3f134f739075|user:victor|date:ThuJan0100:00:001970+0000|summary:split5|ochangeset:12:3f134f739075|user:test~date:ThuJan0100:00:001970+0000summary:split1$hgbookbookA16:452a26648478*bookB16:452a26648478Lastestrevisionisselectedifmultiplearegivento-r$hgsplit-r"desc(_a)::"(leavingbookmarkbookB)0filesupdated,0filesmerged,1filesremoved,0filesunresolvedadding_ddiff--gita/_db/_dnewfilemode100644examinechangesto'_d'?[Ynesfdaq?]abort:responseexpected[255]Cannotsplitacommitthatisnotaheadifinstabilityisnotallowed$cat>>$HGRCPATH<<EOF>[experimental]>evolution=createmarkers>evolutioncommands=split>EOF$hgsplit-r"desc(split3)"abort:splitwillorphan4descendants(see'hg help evolution.instability')[255]Changingevolutionleveltocreatemarkers$echo"[experimental]">>$HGRCPATH$echo"evolution=createmarkers">>$HGRCPATHRunningsplitwithoutanyrevisionoperatesontheparentoftheworkingcopy$hgsplit<<EOF>q>EOF0filesupdated,0filesmerged,1filesremoved,0filesunresolvedadding_ddiff--gita/_db/_dnewfilemode100644examinechangesto'_d'?[Ynesfdaq?]qabort:userquit[255]Runningsplitwithtiprevision,specifiedasunnamedargument$hgsplit.<<EOF>q>EOF0filesupdated,0filesmerged,1filesremoved,0filesunresolvedadding_ddiff--gita/_db/_dnewfilemode100644examinechangesto'_d'?[Ynesfdaq?]qabort:userquit[255]Runningsplitwithbothunnamedandnamedrevisionargumentsshowsanerrormsg$hgsplit.--rev.^<<EOF>q>EOFabort:morethanonerevsetisgiven(useeither`hgsplit<rs>`or`hgsplit--rev<rs>`,notboth)[255]Splitemptycommit(issue5191)$hgbranchnew-branchmarkedworkingdirectoryasbranchnew-branch(branchesarepermanentandglobal,didyouwantabookmark?)$hgcommit-m"empty"$hgsplit0filesupdated,0filesmerged,0filesremoved,0filesunresolvedCheckthatsplitkeepstherighttopic$hgup-rtip0filesupdated,0filesmerged,0filesremoved,0filesunresolvedAddtopictothehgrc$echo"[extensions]">>$HGRCPATH$echo"topic=$(echo $(dirname $TESTDIR))/hgext3rd/topic/">>$HGRCPATH$hgtopicmytopicmarkedworkingdirectoryastopic:mytopic$echobabar>babar$echoceleste>celeste$hgaddbabarceleste$hgcommit-m"Works on mytopic"babarceleste--uservictoractivetopic'mytopic'grewitsfirstchangeset$hglog-r.changeset:18:26f72cfaf036branch:new-branchtag:tiptopic:mytopicuser:victordate:ThuJan0100:00:001970+0000summary:Worksonmytopic$hgsummaryparent:18:26f72cfaf036tipWorksonmytopicbranch:new-branchcommit:2unknown(clean)update:(current)phases:9drafttopic:mytopicSplitit$hgsplit-U<<EOF>Y>Y>N>Y>Y>Y>EOF0filesupdated,0filesmerged,2filesremoved,0filesunresolvedaddingbabaraddingcelestediff--gita/babarb/babarnewfilemode100644examinechangesto'babar'?[Ynesfdaq?]Y@@-0,0+1,1@@+babarrecordchange1/2to'babar'?[Ynesfdaq?]Ydiff--gita/celesteb/celestenewfilemode100644examinechangesto'celeste'?[Ynesfdaq?]NDonesplitting?[yN]Ydiff--gita/celesteb/celestenewfilemode100644examinechangesto'celeste'?[Ynesfdaq?]Y@@-0,0+1,1@@+celesterecordthischangeto'celeste'?[Ynesfdaq?]YnomorechangetosplitCheckthatthetopicisstillhere$hglog-r"tip~1::"changeset:19:addcf498f19ebranch:new-branchtopic:mytopicparent:17:fdb403258632user:testdate:ThuJan0100:00:001970+0000summary:split7changeset:20:2532b288af61branch:new-branchtag:tiptopic:mytopicuser:testdate:ThuJan0100:00:001970+0000summary:split8$hgtopic*mytopic(2changesets)Testsplitthefirstcommitonabranch$touchSPLIT1SPLIT2$hgaddSPLIT1SPLIT2$hgbranchanother-branchmarkedworkingdirectoryasbranchanother-branch$hgcommit-m"To be splitted"$hglog-G-l3@changeset:21:8dad923bdb9b|branch:another-branch|tag:tip|topic:mytopic|user:test|date:ThuJan0100:00:001970+0000|summary:Tobesplitted|ochangeset:20:2532b288af61|branch:new-branch|topic:mytopic|user:test|date:ThuJan0100:00:001970+0000|summary:split8|ochangeset:19:addcf498f19e|branch:new-branch~topic:mytopicparent:17:fdb403258632user:testdate:ThuJan0100:00:001970+0000summary:split7$hgexport. # HG changeset patch # User test # Date 0 0 # Thu Jan 01 00:00:00 1970 +0000 # Branch another-branch # Node ID 8dad923bdb9bb3b99291caa5baeb03bbc30dfd33 # Parent 2532b288af61bd19239a95ae2a3ecb9b0ad4b8e1 # EXP-Topic mytopicTobesplitteddiff--gita/SPLIT1b/SPLIT1newfilemode100644diff--gita/SPLIT2b/SPLIT2newfilemode100644$hgsplit-r.<<EOF>Y>N>N>Y>EOF0filesupdated,0filesmerged,2filesremoved,0filesunresolvedaddingSPLIT1addingSPLIT2diff--gita/SPLIT1b/SPLIT1newfilemode100644examinechangesto'SPLIT1'?[Ynesfdaq?]Ydiff--gita/SPLIT2b/SPLIT2newfilemode100644examinechangesto'SPLIT2'?[Ynesfdaq?]NDonesplitting?[yN]Ndiff--gita/SPLIT2b/SPLIT2newfilemode100644examinechangesto'SPLIT2'?[Ynesfdaq?]YnomorechangetosplitThesplittedchangesetsshouldbeonthe'another-branch'$hglog-G-l3@changeset:23:56a59faa8af7|branch:another-branch|tag:tip|topic:mytopic|user:test|date:ThuJan0100:00:001970+0000|summary:split10|ochangeset:22:75695e3e2300|branch:another-branch|topic:mytopic|parent:20:2532b288af61|user:test|date:ThuJan0100:00:001970+0000|summary:split9|ochangeset:20:2532b288af61|branch:new-branch~topic:mytopicuser:testdate:ThuJan0100:00:001970+0000summary:split8Trysplittingthefirstchangesetofabranchthencancel$hgbranchyet-another-branchmarkedworkingdirectoryasbranchyet-another-branch$touchSPLIT3SPLIT4$hgaddSPLIT3SPLIT4$hgcommit-m"To be splitted again"$hgup"tip~1"0filesupdated,0filesmerged,2filesremoved,0filesunresolved$hglog-G-l2ochangeset:24:b1020d17c364|branch:yet-another-branch|tag:tip|topic:mytopic|user:test|date:ThuJan0100:00:001970+0000|summary:Tobesplittedagain|@changeset:23:56a59faa8af7|branch:another-branch~topic:mytopicuser:testdate:ThuJan0100:00:001970+0000summary:split10$hgbranchanother-branch$hgsplit-rtip<<EOF>Y>q>EOF0filesupdated,0filesmerged,0filesremoved,0filesunresolvedaddingSPLIT3addingSPLIT4diff--gita/SPLIT3b/SPLIT3newfilemode100644examinechangesto'SPLIT3'?[Ynesfdaq?]Ydiff--gita/SPLIT4b/SPLIT4newfilemode100644examinechangesto'SPLIT4'?[Ynesfdaq?]qabort:userquit[255]$hgbranchanother-branch$hglog-G-l2ochangeset:24:b1020d17c364|branch:yet-another-branch|tag:tip|topic:mytopic|user:test|date:ThuJan0100:00:001970+0000|summary:Tobesplittedagain|@changeset:23:56a59faa8af7|branch:another-branch~topic:mytopicuser:testdate:ThuJan0100:00:001970+0000summary:split10