diff -r 5023027240a1 -r ec892050f3c7 mercurial/dirstate.py --- a/mercurial/dirstate.py Wed Oct 17 17:23:39 2012 -0500 +++ b/mercurial/dirstate.py Wed Oct 17 21:32:19 2012 -0500 @@ -260,8 +260,8 @@ return copies def setbranch(self, branch): - if branch in ['tip', '.', 'null']: - raise util.Abort(_('the name \'%s\' is reserved') % branch) + # no repo object here, just check for reserved names + scmutil.checknewlabel(None, branch) self._branch = encoding.fromlocal(branch) f = self._opener('branch', 'w', atomictemp=True) try: