remove xfileref_role() and directive_dwim() which were deprecated in 1.0

This commit is contained in:
Georg Brandl
2013-03-29 12:28:38 +01:00
parent 1d192dbe6e
commit 3d0b924e70
3 changed files with 5 additions and 19 deletions

View File

@@ -1,7 +1,11 @@
Release 1.2 (in development)
============================
There should be no backwards-incompatible changes in this version.
Incompatible changes
--------------------
* Removed ``sphinx.util.compat.directive_dwim()`` and
``sphinx.roles.xfileref_role()`` which were deprecated since version 1.0.
Features added
--------------

View File

@@ -10,7 +10,6 @@
"""
import re
import warnings
from docutils import nodes, utils
from docutils.parsers.rst import roles
@@ -316,10 +315,3 @@ specific_docroles = {
for rolename, func in specific_docroles.iteritems():
roles.register_local_role(rolename, func)
# backwards compatibility alias
def xfileref_role(*args, **kwds):
warnings.warn('xfileref_role is deprecated, use XRefRole',
DeprecationWarning, stacklevel=2)
return XRefRole()(*args, **kwds)

View File

@@ -33,14 +33,4 @@ def make_admonition(node_class, name, arguments, options, content, lineno,
state.nested_parse(content, content_offset, admonition_node)
return [admonition_node]
# backwards-compatibility aliases for helpers in older Sphinx versions that
# supported the docutils 0.4 directive function interface
from docutils.parsers.rst import Directive
def directive_dwim(obj):
import warnings
warnings.warn('directive_dwim is deprecated and no longer needed',
DeprecationWarning, stacklevel=2)
return obj