summaryrefslogtreecommitdiff
path: root/sphinx/util/texescape.py
diff options
context:
space:
mode:
Diffstat (limited to 'sphinx/util/texescape.py')
-rw-r--r--sphinx/util/texescape.py20
1 files changed, 5 insertions, 15 deletions
diff --git a/sphinx/util/texescape.py b/sphinx/util/texescape.py
index b67dcfe82..417a963a7 100644
--- a/sphinx/util/texescape.py
+++ b/sphinx/util/texescape.py
@@ -11,8 +11,6 @@
import re
from typing import Dict
-from sphinx.deprecation import RemovedInSphinx40Warning, deprecated_alias
-
tex_replacements = [
# map TeX special chars
('$', r'\$'),
@@ -100,20 +98,12 @@ unicode_tex_replacements = [
# %, {, }, \, #, and ~ are the only ones which must be replaced by _ character
# It would be simpler to define it entirely here rather than in init().
# Unicode replacements are superfluous, as idescape() uses backslashreplace
-tex_replace_map = {} # type: Dict[int, str]
-
-_tex_escape_map = {} # type: Dict[int, str]
-_tex_escape_map_without_unicode = {} # type: Dict[int, str]
-_tex_hlescape_map = {} # type: Dict[int, str]
-_tex_hlescape_map_without_unicode = {} # type: Dict[int, str]
-
+tex_replace_map: Dict[int, str] = {}
-deprecated_alias('sphinx.util.texescape',
- {
- 'tex_escape_map': _tex_escape_map,
- 'tex_hl_escape_map_new': _tex_hlescape_map,
- },
- RemovedInSphinx40Warning)
+_tex_escape_map: Dict[int, str] = {}
+_tex_escape_map_without_unicode: Dict[int, str] = {}
+_tex_hlescape_map: Dict[int, str] = {}
+_tex_hlescape_map_without_unicode: Dict[int, str] = {}
def escape(s: str, latex_engine: str = None) -> str: