diff --git a/sphinx/writers/html.py b/sphinx/writers/html.py
index 07746f6a7..487ca8b42 100644
--- a/sphinx/writers/html.py
+++ b/sphinx/writers/html.py
@@ -595,6 +595,10 @@ class HTMLTranslator(BaseTranslator):
def depart_hlistcol(self, node):
self.body.append('')
+ def visit_option_group(self, node):
+ BaseTranslator.visit_option_group(self, node)
+ self.context[-2] = self.context[-2].replace(' ', ' ')
+
def bulk_text_processor(self, text):
return text
@@ -832,10 +836,6 @@ class SmartyPantsHTMLTranslator(HTMLTranslator):
self.no_smarty -= 1
HTMLTranslator.depart_option(self, node)
- def visit_option_group(self, node):
- HTMLTranslator.visit_option_group(self, node)
- self.context[-2] = self.context[-2].replace(' ', ' ')
-
def bulk_text_processor(self, text):
if self.no_smarty <= 0:
return sphinx_smarty_pants(text)
diff --git a/tests/roots/test-html_entity/conf.py b/tests/roots/test-html_entity/conf.py
new file mode 100644
index 000000000..c46e40773
--- /dev/null
+++ b/tests/roots/test-html_entity/conf.py
@@ -0,0 +1,5 @@
+# -*- coding: utf-8 -*-
+
+master_doc = 'index'
+html_theme = 'classic'
+exclude_patterns = ['_build']
diff --git a/tests/roots/test-html_entity/index.rst b/tests/roots/test-html_entity/index.rst
new file mode 100644
index 000000000..e4cbd99c3
--- /dev/null
+++ b/tests/roots/test-html_entity/index.rst
@@ -0,0 +1,31 @@
+.. _index:
+
+test-html_entity (#3450)
+=========================
+
+Empty cell
+----------
+
+.. list-table::
+ :header-rows: 1
+ - * un
+ *
+ * trois
+
+Return description in function signature
+----------------------------------------
+
+.. py:function:: test() -> string
+
+ rarr
+
+Field list that has long name (over 14 characters)
+--------------------------------------------------
+
+:abcdefghijklmnopqrstuvwxyz: fieldlist
+
+Option list that has long name (over 14 characters)
+---------------------------------------------------
+
+-a all
+-b long_long_file use file
diff --git a/tests/test_build_html.py b/tests/test_build_html.py
index 8938d901b..a2756ce2c 100644
--- a/tests/test_build_html.py
+++ b/tests/test_build_html.py
@@ -1139,3 +1139,12 @@ def test_html_sourcelink_suffix(app):
assert '