diff --git a/mercurial/obsolete.py b/mercurial/obsolete.py
index a1d2d0420e22f68a7802961291f1f4b2db62c5e8_bWVyY3VyaWFsL29ic29sZXRlLnB5..d30810d09d6fe9d33cb3fecab785975fa7d8934f_bWVyY3VyaWFsL29ic29sZXRlLnB5 100644
--- a/mercurial/obsolete.py
+++ b/mercurial/obsolete.py
@@ -133,7 +133,25 @@
 
         return option in result
 
+def getoptions(repo):
+    """Returns dicts showing state of obsolescence features."""
+
+    createmarkersvalue = _getoptionvalue(repo, createmarkersopt)
+    unstablevalue = _getoptionvalue(repo, allowunstableopt)
+    exchangevalue = _getoptionvalue(repo, exchangeopt)
+
+    # createmarkers must be enabled if other options are enabled
+    if ((unstablevalue or exchangevalue) and not createmarkersvalue):
+        raise error.Abort(_("'createmarkers' obsolete option must be enabled "
+                            "if other obsolete options are enabled"))
+
+    return {
+        createmarkersopt: createmarkersvalue,
+        allowunstableopt: unstablevalue,
+        exchangeopt: exchangevalue,
+    }
+
 def isenabled(repo, option):
     """Returns True if the given repository has the given obsolete option
     enabled.
     """
@@ -136,17 +154,8 @@
 def isenabled(repo, option):
     """Returns True if the given repository has the given obsolete option
     enabled.
     """
-    createmarkersvalue = _getoptionvalue(repo, createmarkersopt)
-    unstabluevalue = _getoptionvalue(repo, allowunstableopt)
-    exchangevalue = _getoptionvalue(repo, exchangeopt)
-
-    # createmarkers must be enabled if other options are enabled
-    if ((unstabluevalue or exchangevalue) and not createmarkersvalue):
-        raise error.Abort(_("'createmarkers' obsolete option must be enabled "
-                            "if other obsolete options are enabled"))
-
-    return _getoptionvalue(repo, option)
+    return getoptions(repo)[option]
 
 # Creating aliases for marker flags because evolve extension looks for
 # bumpedfix in obsolete.py