mercurial/dagparser.py
changeset 26587 56b2bcea2529
parent 25941 a75cda2dfc19
child 33716 c91013452b33
--- a/mercurial/dagparser.py	Mon Oct 05 22:49:24 2015 -0700
+++ b/mercurial/dagparser.py	Thu Oct 08 12:55:45 2015 -0700
@@ -11,7 +11,7 @@
 import string
 
 from .i18n import _
-from . import util
+from . import error
 
 def parsedag(desc):
     '''parses a DAG from a concise textual description; generates events
@@ -269,7 +269,7 @@
                 s += c
                 i += 1
                 c = nextch()
-            raise util.Abort(_('invalid character in dag description: '
+            raise error.Abort(_('invalid character in dag description: '
                                '%s...') % s)
 
 def dagtextlines(events,
@@ -298,13 +298,13 @@
 
                 # sanity check
                 if r != wantr:
-                    raise util.Abort(_("expected id %i, got %i") % (wantr, r))
+                    raise error.Abort(_("expected id %i, got %i") % (wantr, r))
                 if not ps:
                     ps = [-1]
                 else:
                     for p in ps:
                         if p >= r:
-                            raise util.Abort(_("parent id %i is larger than "
+                            raise error.Abort(_("parent id %i is larger than "
                                                "current id %i") % (p, r))
                 wantr += 1
 
@@ -366,7 +366,7 @@
                     yield '#' + data
                     yield '\n'
                 else:
-                    raise util.Abort(_("invalid event type in dag: %s")
+                    raise error.Abort(_("invalid event type in dag: %s")
                                      % str((type, data)))
         if run:
             yield '+' + str(run)